Changeset e259ad9 in tol for tolbase/lib/wtree/wtree.tcl
- Timestamp:
- Feb 29, 2012, 8:38:47 AM (15 years ago)
- Branches:
- 1941-docker-image-to-test, devel, master
- Children:
- 7d4ba03
- Parents:
- 73cf07b
- File:
-
- 1 edited
-
tolbase/lib/wtree/wtree.tcl (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
tolbase/lib/wtree/wtree.tcl
r73cf07b re259ad9 915 915 foreach { item I column C elem E } $treeInfo { } 916 916 917 #puts "OnButtonPress1: $treeInfo"918 917 if { $item == "item" && \ 919 918 $column == "column" && \ … … 925 924 set idx_info $column_info(MAPIDX,$C) 926 925 927 if { $column_info($idx_info,-editable) && $E eq "eTXT"} { 926 if { $column_info($idx_info,-editable) && 927 ( $E eq "eTXT" || $E eq "eRECT" ) } { 928 928 set exists [winfo exists $tree.entry] 929 ::TreeCtrl::EntryOpen $tree $I $C $E929 ::TreeCtrl::EntryOpen $tree $I $C eTXT 930 930 if {!$exists} { 931 $tree.entry configure -borderwidth 1 -justify center\931 $tree.entry configure -borderwidth 1 -justify left \ 932 932 -background white -relief sunken 933 933 update idletask 934 934 } 935 935 $tree.entry selection clear 936 scan [ $tree item bbox $I $C $E] "%d %d %d %d" x1 y1 x2 y2936 scan [ $tree item bbox $I $C eRECT ] "%d %d %d %d" x1 y1 x2 y2 937 937 set left $x1 938 938 set right $x2 939 place $tree.entry -y $y1 -x $left -width [expr {$right - $left + 4}]940 $tree.entry icursor [$tree.entry index @[expr {$x - ($x1 + 1)}]]939 place $tree.entry -y $y1 -x $left -width [expr {$right - $left + 1}] 940 $tree.entry icursor [$tree.entry index @[expr {$x - $x1}]] 941 941 return -code break 942 942 … … 994 994 -columns [ list \ 995 995 { {image text} -tags ID -label Identifier } \ 996 { text -tags DESC -label Description } ] ]996 { text -tags DESC -label Description -editable yes } ] ] 997 997 998 998 $T notify bind $T <Expand-before> { … … 1003 1003 } 1004 1004 $T notify bind $T <ActiveItem> { 1005 #puts "now active item is %c the previous was %p"1005 puts "now active item is %c the previous was %p" 1006 1006 } 1007 1007 grid $T -row 1 -column 0 -sticky "snew"
Note: See TracChangeset
for help on using the changeset viewer.
