summaryrefslogtreecommitdiffstats
path: root/library/tk.tcl
diff options
context:
space:
mode:
authorhobbs <hobbs>2002-09-09 23:52:02 (GMT)
committerhobbs <hobbs>2002-09-09 23:52:02 (GMT)
commit958042034bbbe215fbb0915cf6c07b9914923724 (patch)
tree804bf93151524b4ec43b4495c97883b3f0b0d9d8 /library/tk.tcl
parentec6a4daee7df6a5652185b52f34a9e48d28a652e (diff)
downloadtk-958042034bbbe215fbb0915cf6c07b9914923724.zip
tk-958042034bbbe215fbb0915cf6c07b9914923724.tar.gz
tk-958042034bbbe215fbb0915cf6c07b9914923724.tar.bz2
* library/tk.tcl: use command instead of control on Aqua bindings.
Force dialogs to appear below fixed native Mac menubar. * macosx/tkMacOSXKeyEvent.c: * macosx/tkMacOSXKeyboard.c: Keypress/release events for pure modifier keys were not being passed to Tk. Deadkey presses were inserting null characters into text windows. Now they do nothing. (Still not ideal, but better than before!) * macosx/tkMacOSXMenu.c: Allow more than 200 menus to exist - increased to 2000. * macosx/tkMacOSXMouseEvent.c: Bad interactions between floating windows and ordinary ones. Ensure that local<->global coordinate transformations are wrt to the correct window. * macosx/tkMacOSXWm.c: Better error msg for 'wm attributes'. Remove crash in 'wm transient'. Add 'noActivates' and 'noUpdates' flags to unsupported command. [Patch #606658] (darley)
Diffstat (limited to 'library/tk.tcl')
-rw-r--r--library/tk.tcl17
1 files changed, 11 insertions, 6 deletions
diff --git a/library/tk.tcl b/library/tk.tcl
index e695924..cb6e662 100644
--- a/library/tk.tcl
+++ b/library/tk.tcl
@@ -3,7 +3,7 @@
# Initialization script normally executed in the interpreter for each
# Tk-based application. Arranges class bindings for widgets.
#
-# RCS: @(#) $Id: tk.tcl,v 1.43 2002/08/31 06:12:28 das Exp $
+# RCS: @(#) $Id: tk.tcl,v 1.44 2002/09/09 23:52:02 hobbs Exp $
#
# Copyright (c) 1992-1994 The Regents of the University of California.
# Copyright (c) 1994-1996 Sun Microsystems, Inc.
@@ -111,6 +111,11 @@ proc ::tk::PlaceWindow {w {place ""} {anchor ""}} {
} elseif {$y > ([winfo screenheight $w]-[winfo reqheight $w])} {
set y [expr {[winfo screenheight $w]-[winfo reqheight $w]}]
}
+ if {[tk windowingsystem] eq "macintosh" \
+ || [tk windowingsystem] eq "aqua"} {
+ # Avoid the native menu bar which sits on top of everything.
+ if {$y < 20} { set y 20 }
+ }
}
wm geometry $w +$x+$y
wm deiconify $w
@@ -369,13 +374,13 @@ switch [tk windowingsystem] {
event add <<Redo>> <Control-Key-y>
}
"aqua" {
- event add <<Cut>> <Control-Key-x> <Key-F2>
- event add <<Copy>> <Control-Key-c> <Key-F3>
- event add <<Paste>> <Control-Key-v> <Key-F4>
+ event add <<Cut>> <Command-Key-x> <Key-F2>
+ event add <<Copy>> <Command-Key-c> <Key-F3>
+ event add <<Paste>> <Command-Key-v> <Key-F4>
event add <<PasteSelection>> <ButtonRelease-2>
event add <<Clear>> <Clear>
- event add <<Undo>> <Control-Key-z>
- event add <<Redo>> <Control-Key-y>
+ event add <<Undo>> <Command-Key-z>
+ event add <<Redo>> <Command-Key-y>
}
"classic" {
event add <<Cut>> <Control-Key-x> <Key-F2>