Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8793
Modified Files: Tag: desiredata desire.tk Log Message: KeyboardDialog: more accurate key size
Index: desire.tk =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v retrieving revision 1.1.2.600.2.217 retrieving revision 1.1.2.600.2.218 diff -C2 -d -r1.1.2.600.2.217 -r1.1.2.600.2.218 *** desire.tk 11 Jul 2007 16:07:24 -0000 1.1.2.600.2.217 --- desire.tk 11 Jul 2007 18:59:33 -0000 1.1.2.600.2.218 *************** *** 7893,7897 ****
set keyboard_layout { ! {Escape F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12} {grave 1 2 3 4 5 6 7 8 9 0 minus equal BackSpace} {Tab q w e r t y u i o p bracketleft bracketright backslash} --- 7893,7897 ----
set keyboard_layout { ! {Escape " " F1 F2 F3 F4 " " F5 F6 F7 F8 " " F9 F10 F11 F12} {grave 1 2 3 4 5 6 7 8 9 0 minus equal BackSpace} {Tab q w e r t y u i o p bracketleft bracketright backslash} *************** *** 7900,7910 **** {Control_L Super_L Alt_L space Alt_R Super_R Menu Control_R} } - foreach {k v} { ! grave ` minus - equal = bracketleft [ bracketright ] backslash \ ! semicolon ; apostrophe ' comma , period . slash / Shift_L Shift Shift_R Shift Control_L Ctrl Control_R Ctrl Alt_L Alt Alt_R AltGr ! Super_L Win Super_R Win ! } {set keyboard_rename($k) $v}
def KeyboardDialog init {} { --- 7900,7917 ---- {Control_L Super_L Alt_L space Alt_R Super_R Menu Control_R} } foreach {k v} { ! Escape 5 ! BackSpace 5 ! Tab 4 backslash 4 ! Caps_Lock 5 Return 7 ! Shift_L 8 Shift_R 8 ! Control_L 4 Super_L 4 Alt_L 4 space 24 Alt_R 4 Super_R 4 Menu 4 Control_R 4 ! } {set keyboard_width_of($k) $v} ! foreach {k v} { ! grave ` minus - equal = bracketleft [ bracketright ] backslash \ BackSpace BkSp ! Caps_Lock Caps semicolon ; apostrophe ' comma , period . slash / Shift_L Shift Shift_R Shift Control_L Ctrl Control_R Ctrl Alt_L Alt Alt_R AltGr ! Super_L Win Super_R Win Escape Esc ! } {set keyboard_text_of($k) $v}
def KeyboardDialog init {} { *************** *** 7912,7925 **** set @history $::event_history wm title .$self "Keyboard View" ;# say ! set i 0 foreach row $::keyboard_layout { frame .$self.$i foreach key $row { ! set ::keyboard_rowof($key) $i #pack [button .$self.$i.key$key -text "$key"] -side left ! if {[info exists ::keyboard_rename($key)]} {set text $::keyboard_rename($key)} {set text $key} ! pack [label .$self.$i.key$key -text " $text " -relief raise -border 4 -bg "#dddddd"] -side left } pack .$self.$i -fill x incr i } --- 7919,7935 ---- set @history $::event_history wm title .$self "Keyboard View" ;# say ! set i 0; set j 0 foreach row $::keyboard_layout { frame .$self.$i foreach key $row { ! if {$key==" "} {pack [label .$self.$i.shim$j -image icon_empty] -side left; incr j; continue} ! set ::keyboard_row_of($key) $i #pack [button .$self.$i.key$key -text "$key"] -side left ! if {[info exists ::keyboard_width_of($key)]} {set width $::keyboard_width_of($key)} {set width 3} ! if {[info exists ::keyboard_text_of($key)]} {set text $::keyboard_text_of($key)} {set text $key} ! pack [label .$self.$i.key$key -text " $text " -relief raise -border 4 -bg "#dddddd" -width $width] -side left } pack .$self.$i -fill x + if {$i==0} {pack [label .$self.shim -image icon_empty]} incr i } *************** *** 7929,7934 **** def KeyboardDialog notice {origin add event} { mset {type k x y w} $event ! if {![info exists ::keyboard_rowof($k)]} {puts "unknown event $event"; return} ! set row $::keyboard_rowof($k) switch -- $type { KeyPress {puts "$k on"; .$self.$row.key$k configure -bg "#ff0000"} --- 7939,7944 ---- def KeyboardDialog notice {origin add event} { mset {type k x y w} $event ! if {![info exists ::keyboard_row_of($k)]} {puts "unknown event $event"; return} ! set row $::keyboard_row_of($k) switch -- $type { KeyPress {puts "$k on"; .$self.$row.key$k configure -bg "#ff0000"}