-
Notifications
You must be signed in to change notification settings - Fork 14
/
init.tcl
49 lines (44 loc) · 1.53 KB
/
init.tcl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# ----------------------------------------------------------------------------
# init.tcl
# This file is part of Unifix BWidget Toolkit
# $Id: init.tcl,v 1.92 2009/10/25 20:55:36 oberdorfer Exp $
# ----------------------------------------------------------------------------
#
namespace eval Widget {}
proc Widget::_opt_defaults {{prio widgetDefault}} {
if {$::tcl_version >= 8.4} {
set plat [tk windowingsystem]
} else {
set plat $::tcl_platform(platform)
}
switch -exact $plat {
"aqua" {
}
"win32" -
"windows" {
option add *ListBox.background SystemWindow $prio
#option add *Button.padY 0 $prio
option add *ButtonBox.padY 0 $prio
option add *Dialog.padY 0 $prio
option add *Dialog.anchor e $prio
}
"x11" -
default {
option add *Scrollbar.width 12 $prio
option add *Scrollbar.borderWidth 1 $prio
option add *Dialog.separator 1 $prio
option add *MainFrame.relief raised $prio
option add *MainFrame.separator none $prio
}
}
}
Widget::_opt_defaults
option read [file join $::BWIDGET::LIBRARY "lang" "en.rc"]
# Add a TraverseIn binding to standard Tk widgets to handle some of
# the BWidget-specific things we do.
bind Entry <<TraverseIn>> { %W selection range 0 end; %W icursor end }
bind Spinbox <<TraverseIn>> { %W selection range 0 end; %W icursor end }
bind all <Key-Tab> { Widget::traverseTo [Widget::focusNext %W] }
bind all <<PrevWindow>> { Widget::traverseTo [Widget::focusPrev %W] }
::BWidget::createSystemFonts
::BWidget::set_themedefaults "default"