[PD-cvs] pd/src u_main.tk,1.17.2.7,1.17.2.8
Hans-Christoph Steiner
eighthave at users.sourceforge.net
Tue May 15 03:22:06 CEST 2007
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6789
Modified Files:
Tag: branch-v0-39-2-extended
u_main.tk
Log Message:
pegged Tk to scaling of 1 on all platforms; fixed menu font on Windows since they get really tiny when the tk scaling is changed
Index: u_main.tk
===================================================================
RCS file: /cvsroot/pure-data/pd/src/u_main.tk,v
retrieving revision 1.17.2.7
retrieving revision 1.17.2.8
diff -C2 -d -r1.17.2.7 -r1.17.2.8
*** u_main.tk 22 Feb 2007 02:37:46 -0000 1.17.2.7
--- u_main.tk 15 May 2007 01:22:03 -0000 1.17.2.8
***************
*** 4,7 ****
--- 4,8 ----
if { $tcl_platform(platform) == "windows" } {
set pd_nt 1
+ font create menuFont -family Tahoma -size 11
} elseif { $tcl_platform(os) == "Darwin" } {
set pd_nt 2
***************
*** 10,13 ****
--- 11,19 ----
}
+ # Pd-0.39.2-extended hacks to make font/box sizes the same across platform
+ puts stderr "tk scaling is [tk scaling]"
+ tk scaling 1
+
+
# Copyright (c) 1997-1999 Miller Puckette.
# For information on usage and redistribution, and for a DISCLAIMER OF ALL
***************
*** 127,130 ****
--- 133,145 ----
}
+ # fix menu font size on Windows with tk scaling = 1
+ if {$pd_nt == 1} {
+ .mbar.file configure -font menuFont
+ .mbar.find configure -font menuFont
+ .mbar.windows configure -font menuFont
+ .mbar.audio configure -font menuFont
+ .mbar.help configure -font menuFont
+ }
+
set ctrls_audio_on 0
set ctrls_meter_on 0
***************
*** 1130,1133 ****
--- 1145,1160 ----
-command [concat popup_action $name 2]
+ # fix menu font size on Windows with tk scaling = 1
+ if {$pd_nt == 1} {
+ $name.m.file configure -font menuFont
+ $name.m.edit configure -font menuFont
+ $name.m.find configure -font menuFont
+ $name.m.put configure -font menuFont
+ $name.m.windows configure -font menuFont
+ $name.m.audio configure -font menuFont
+ $name.m.help configure -font menuFont
+ $name.popup configure -font menuFont
+ }
+
# WM protocol
wm protocol $name WM_DELETE_WINDOW [concat menu_close $name]
***************
*** 3584,3589 ****
--- 3611,3620 ----
# create a popup menu
proc audio_popup {name buttonname varname devlist} {
+ global pd_nt
if [winfo exists $name.popup] {destroy $name.popup}
menu $name.popup -tearoff false
+ if {$pd_nt == 1} {
+ $name.popup configure -font menuFont
+ }
# puts stderr [concat $devlist ]
for {set x 0} {$x<[llength $devlist]} {incr x} {
***************
*** 3857,3862 ****
--- 3888,3897 ----
# create a popup menu
proc midi_popup {name buttonname varname devlist} {
+ global pd_nt
if [winfo exists $name.popup] {destroy $name.popup}
menu $name.popup -tearoff false
+ if {$pd_nt == 1} {
+ $name.popup configure -font menuFont
+ }
# puts stderr [concat $devlist ]
for {set x 0} {$x<[llength $devlist]} {incr x} {
More information about the Pd-cvs
mailing list