summaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2022-12-29 22:56:24 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2022-12-29 22:56:24 (GMT)
commitda883877fe19f11084092eb164c88c49485d0058 (patch)
tree347a71e76d6dec98bb6e97f68188703ba3fd24d0 /library
parent1ba683df5b82930fde24c4b820700304a278296a (diff)
downloadtk-da883877fe19f11084092eb164c88c49485d0058.zip
tk-da883877fe19f11084092eb164c88c49485d0058.tar.gz
tk-da883877fe19f11084092eb164c88c49485d0058.tar.bz2
Use some more point-expressions in stead of tk::ScaleNum
Diffstat (limited to 'library')
-rw-r--r--library/bgerror.tcl3
-rw-r--r--library/dialog.tcl2
-rw-r--r--library/megawidget.tcl3
-rw-r--r--library/safetk.tcl2
-rw-r--r--library/tk.tcl14
5 files changed, 11 insertions, 13 deletions
diff --git a/library/bgerror.tcl b/library/bgerror.tcl
index b3fe539..812e44a 100644
--- a/library/bgerror.tcl
+++ b/library/bgerror.tcl
@@ -207,8 +207,7 @@ proc ::tk::dialog::error::bgerror {err {flag 1}} {
foreach {name caption} $buttons {
ttk::button $dlg.$name -text $caption -default normal \
-command [namespace code [list set button $i]]
- grid $dlg.$name -in $dlg.bot -column $i -row 0 -sticky ew \
- -padx [::tk::ScaleNum 10]
+ grid $dlg.$name -in $dlg.bot -column $i -row 0 -sticky ew -padx 7.5p
grid columnconfigure $dlg.bot $i -weight 1
# We boost the size of some Mac buttons for l&f
if {$windowingsystem eq "aqua"} {
diff --git a/library/dialog.tcl b/library/dialog.tcl
index e011d70..16ba128 100644
--- a/library/dialog.tcl
+++ b/library/dialog.tcl
@@ -109,7 +109,7 @@ proc ::tk_dialog {w title text bitmap default args} {
$w.button$i configure -default normal
}
grid $w.button$i -in $w.bot -column $i -row 0 -sticky ew \
- -padx [::tk::ScaleNum 10] -pady [::tk::ScaleNum 4]
+ -padx 7.5p -pady 3p
grid columnconfigure $w.bot $i
# We boost the size of some Mac buttons for l&f
if {$windowingsystem eq "aqua"} {
diff --git a/library/megawidget.tcl b/library/megawidget.tcl
index 47bdbf7..5114f63 100644
--- a/library/megawidget.tcl
+++ b/library/megawidget.tcl
@@ -284,8 +284,7 @@ package require tk
method CreateHull {} {
ttk::frame $w
set hull [ttk::entry $w.cHull -takefocus 0 -cursor $options(-cursor)]
- set ipad [::tk::ScaleNum 2]
- pack $hull -expand yes -fill both -ipadx $ipad -ipady $ipad
+ pack $hull -expand yes -fill both -ipadx 1.5p -ipady 1.5p
my TraceOption -cursor UpdateCursorOption
}
}
diff --git a/library/safetk.tcl b/library/safetk.tcl
index b86db1a..f3dacd7 100644
--- a/library/safetk.tcl
+++ b/library/safetk.tcl
@@ -250,7 +250,7 @@ proc ::safe::tkTopLevel {child display} {
-command [list ::safe::tkDelete $w $w $child]
pack $wc.fb.b -side right -fill both
pack $wc.fb -side right -fill both -expand 1
- pack $wc.l -side left -fill both -expand 1 -ipady [::tk::ScaleNum 2]
+ pack $wc.l -side left -fill both -expand 1 -ipady 1.5p
pack $wc -side bottom -fill x
# Container frame
diff --git a/library/tk.tcl b/library/tk.tcl
index 7f37a25..3cc0e8b 100644
--- a/library/tk.tcl
+++ b/library/tk.tcl
@@ -814,18 +814,18 @@ if {[info commands ::tk::startOfCluster] eq ""} {
set ::tk::Priv(IMETextMark) [dict create]
# Scale the default parameters of the panedwindow sash
-option add *Panedwindow.handlePad [::tk::ScaleNum 8] widgetDefault
-option add *Panedwindow.handleSize [::tk::ScaleNum 8] widgetDefault
-option add *Panedwindow.sashWidth [::tk::ScaleNum 3] widgetDefault
+option add *Panedwindow.handlePad 6p widgetDefault
+option add *Panedwindow.handleSize 6p widgetDefault
+option add *Panedwindow.sashWidth 2p widgetDefault
# Scale the default size of the scale widget and its slider
-option add *Scale.length [::tk::ScalingPct] widgetDefault
-option add *Scale.sliderLength [::tk::ScaleNum 30] widgetDefault
-option add *Scale.width [::tk::ScaleNum 15] widgetDefault
+option add *Scale.length 75p widgetDefault
+option add *Scale.sliderLength 22.5p widgetDefault
+option add *Scale.width 11.25p widgetDefault
# Scale the default scrollbar width on X11
if {[tk windowingsystem] eq "x11"} {
- option add *Scrollbar.width [::tk::ScaleNum 11] widgetDefault
+ option add *Scrollbar.width 8.25p widgetDefault
}
# Run the Ttk themed widget set initialization