Hex Artifact Content

Artifact 0647275ef3cf329e82f44470400c81582acab873:


0000: 49 6e 64 65 78 3a 20 74 63 6c 72 65 61 64 6c 69  Index: tclreadli
0010: 6e 65 2f 74 63 6c 72 65 61 64 6c 69 6e 65 43 6f  ne/tclreadlineCo
0020: 6d 70 6c 65 74 65 72 2e 74 63 6c 0a 3d 3d 3d 3d  mpleter.tcl.====
0030: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0040: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0050: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0060: 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d 3d  ================
0070: 3d 0a 2d 2d 2d 20 74 63 6c 72 65 61 64 6c 69 6e  =.--- tclreadlin
0080: 65 2e 6f 72 69 67 2f 74 63 6c 72 65 61 64 6c 69  e.orig/tclreadli
0090: 6e 65 43 6f 6d 70 6c 65 74 65 72 2e 74 63 6c 0a  neCompleter.tcl.
00a0: 2b 2b 2b 20 74 63 6c 72 65 61 64 6c 69 6e 65 2f  +++ tclreadline/
00b0: 74 63 6c 72 65 61 64 6c 69 6e 65 43 6f 6d 70 6c  tclreadlineCompl
00c0: 65 74 65 72 2e 74 63 6c 0a 40 40 20 2d 36 32 35  eter.tcl.@@ -625
00d0: 2c 37 20 2b 36 32 35 2c 37 20 40 40 0a 20 09 09  ,7 +625,7 @@. ..
00e0: 09 7d 0a 20 09 09 7d 0a 20 09 7d 0a 2d 09 69 66  .}. ..}. .}.-.if
00f0: 20 7b 21 5b 63 61 74 63 68 20 5b 6c 69 73 74 20   {![catch [list 
0100: 73 65 74 20 74 79 70 65 20 5b 69 6d 61 67 65 20  set type [image 
0110: 74 79 70 65 20 24 7b 63 6d 64 7d 5d 5d 5d 7d 20  type ${cmd}]]]} 
0120: 7b 0a 2b 09 69 66 20 7b 21 5b 63 61 74 63 68 20  {.+.if {![catch 
0130: 7b 6c 69 73 74 20 73 65 74 20 74 79 70 65 20 5b  {list set type [
0140: 69 6d 61 67 65 20 74 79 70 65 20 24 7b 63 6d 64  image type ${cmd
0150: 7d 5d 7d 5d 7d 20 7b 0a 20 09 09 73 77 69 74 63  }]}]} {. ..switc
0160: 68 20 2d 2d 20 24 7b 74 79 70 65 7d 20 7b 0a 20  h -- ${type} {. 
0170: 09 09 09 70 68 6f 74 6f 20 7b 0a 20 09 09 09 09  ...photo {. ....
0180: 73 65 74 20 72 65 73 75 6c 74 20 5b 50 68 6f 74  set result [Phot
0190: 6f 4f 62 6a 20 24 7b 74 65 78 74 7d 20 24 7b 73  oObj ${text} ${s
01a0: 74 61 72 74 7d 20 24 7b 65 6e 64 7d 20 24 7b 6c  tart} ${end} ${l
01b0: 69 6e 65 7d 20 24 7b 70 6f 73 7d 5d 0a 40 40 20  ine} ${pos}].@@ 
01c0: 2d 31 34 36 30 2c 37 20 2b 31 34 36 30 2c 37 20  -1460,7 +1460,7 
01d0: 40 40 0a 20 09 09 09 23 20 74 68 69 73 20 63 61  @@. ...# this ca
01e0: 6e 20 72 61 69 73 65 20 61 6e 20 65 72 72 6f 72  n raise an error
01f0: 2c 20 69 66 20 61 6c 69 61 73 20 69 73 0a 20 09  , if alias is. .
0200: 09 09 23 20 6e 6f 20 76 61 6c 69 64 20 63 6f 6d  ..# no valid com
0210: 6d 61 6e 64 2e 0a 20 09 09 09 23 0a 2d 09 09 09  mand.. ...#.-...
0220: 69 66 20 7b 5b 63 61 74 63 68 20 5b 6c 69 73 74  if {[catch [list
0230: 20 73 65 74 20 61 6c 69 61 73 20 5b 6e 61 6d 65   set alias [name
0240: 73 70 61 63 65 20 6f 72 69 67 69 6e 20 24 61 6c  space origin $al
0250: 69 61 73 5d 5d 5d 7d 20 7b 0a 2b 09 09 09 69 66  ias]]]} {.+...if
0260: 20 7b 5b 63 61 74 63 68 20 7b 73 65 74 20 61 6c   {[catch {set al
0270: 69 61 73 20 5b 6e 61 6d 65 73 70 61 63 65 20 6f  ias [namespace o
0280: 72 69 67 69 6e 20 24 61 6c 69 61 73 5d 7d 5d 7d  rigin $alias]}]}
0290: 20 7b 0a 20 09 09 09 09 72 65 74 75 72 6e 20 22   {. ....return "
02a0: 22 0a 20 09 09 09 7d 0a 20 0a                    ". ...}. .