/usr/share/tkgate/scripts/init.tcl is in tkgate-data 2.0~b10-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 | #############################################################################
#
# Copyright (C) 1987-2009 by Jeffery P. Hansen
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
# Last edit by hansen on Sun Jan 18 15:25:08 2009
#
#set imtest 0
#catch {
# set imtest [tk useinputmethods 1]
#}
set tinyFontSet {
{dipFont Couier 6 normal roman}
{dialogCapFont Helvetica 8 bold roman}
{dialogExpFont Helvetica 6 normal roman}
{dialogBigExpFont Helvetica 6 bold roman}
{labelFont Helvetica 6 normal roman}
{boldLabelFont Helvetica 6 bold roman}
{smallLabelFont Helvetica 6 normal roman}
{buttonFont Helvetica 6 normal roman}
{menuFont Helvetica 6 normal roman}
{entryFont Helvetica 6 normal roman}
{menuButtonFont Helvetica 6 normal roman}
{checklistFont Helvetica 6 normal roman}
{checklistBoldFont Helvetica 6 bold roman}
{hdlFont Courier 6 normal roman}
{hdlItalicFont Courier 6 normal italic}
{hdlBoldFont Courier 6 bold roman}
{hdlBoldItalicFont Courier 6 bold italic}
{Tree:font Helvetica 6 normal roman}
{Tree:actfont Helvetica 6 bold roman}
{Tree:act2font Helvetica 6 bold roman 1}
}
set smallFontSet {
{dipFont Couier 8 normal roman}
{dialogCapFont Helvetica 10 bold roman}
{dialogExpFont Helvetica 8 normal roman}
{dialogBigExpFont Helvetica 8 bold roman}
{labelFont Helvetica 8 normal roman}
{boldLabelFont Helvetica 8 bold roman}
{smallLabelFont Helvetica 8 normal roman}
{buttonFont Helvetica 8 normal roman}
{menuFont Helvetica 8 normal roman}
{entryFont Helvetica 8 normal roman}
{menuButtonFont Helvetica 8 normal roman}
{checklistFont Helvetica 8 normal roman}
{checklistBoldFont Helvetica 8 bold roman}
{hdlFont Courier 8 normal roman}
{hdlItalicFont Courier 8 normal italic}
{hdlBoldFont Courier 8 bold roman}
{hdlBoldItalicFont Courier 8 bold italic}
{Tree:font Helvetica 8 normal roman}
{Tree:actfont Helvetica 8 bold roman}
{Tree:act2font Helvetica 8 bold roman 1}
}
set normalFontSet {
{dipFont Couier 10 normal roman}
{dialogCapFont Helvetica 12 bold roman}
{dialogExpFont Helvetica 10 normal roman}
{dialogBigExpFont Helvetica 10 bold roman}
{labelFont Helvetica 10 normal roman}
{boldLabelFont Helvetica 10 bold roman}
{smallLabelFont Helvetica 10 normal roman}
{buttonFont Helvetica 10 normal roman}
{menuFont Helvetica 10 normal roman}
{entryFont Helvetica 10 normal roman}
{menuButtonFont Helvetica 10 normal roman}
{checklistFont Helvetica 10 normal roman}
{checklistBoldFont Helvetica 10 bold roman}
{hdlFont Courier 10 normal roman}
{hdlItalicFont Courier 10 normal italic}
{hdlBoldFont Courier 10 bold roman}
{hdlBoldItalicFont Courier 10 bold italic}
{Tree:font Helvetica 10 normal roman}
{Tree:actfont Helvetica 10 bold roman}
{Tree:act2font Helvetica 10 bold roman 1}
}
set largeFontSet {
{dipFont Couier 14 normal roman}
{dialogCapFont Helvetica 16 bold roman}
{dialogExpFont Helvetica 14 normal roman}
{dialogBigExpFont Helvetica 14 bold roman}
{labelFont Helvetica 14 normal roman}
{boldLabelFont Helvetica 14 bold roman}
{smallLabelFont Helvetica 14 normal roman}
{buttonFont Helvetica 14 normal roman}
{menuFont Helvetica 14 normal roman}
{entryFont Helvetica 14 normal roman}
{menuButtonFont Helvetica 14 normal roman}
{checklistFont Helvetica 14 normal roman}
{checklistBoldFont Helvetica 14 bold roman}
{hdlFont Courier 14 normal roman}
{hdlItalicFont Courier 14 normal italic}
{hdlBoldFont Courier 14 bold roman}
{hdlBoldItalicFont Courier 14 bold italic}
{Tree:font Helvetica 14 normal roman}
{Tree:actfont Helvetica 14 bold roman}
{Tree:act2font Helvetica 14 bold roman 1}
}
set hugeFontSet {
{dipFont Couier 20 normal roman}
{dialogCapFont Helvetica 24 bold roman}
{dialogExpFont Helvetica 20 normal roman}
{dialogBigExpFont Helvetica 20 bold roman}
{labelFont Helvetica 20 normal roman}
{boldLabelFont Helvetica 20 bold roman}
{smallLabelFont Helvetica 20 normal roman}
{buttonFont Helvetica 20 normal roman}
{menuFont Helvetica 20 normal roman}
{entryFont Helvetica 20 normal roman}
{menuButtonFont Helvetica 20 normal roman}
{checklistFont Helvetica 20 normal roman}
{checklistBoldFont Helvetica 20 bold roman}
{hdlFont Courier 20 normal roman}
{hdlItalicFont Courier 20 normal italic}
{hdlBoldFont Courier 20 bold roman}
{hdlBoldItalicFont Courier 20 bold italic}
{Tree:font Helvetica 20 normal roman}
{Tree:actfont Helvetica 20 bold roman}
{Tree:act2font Helvetica 20 bold roman 1}
}
#############################################################################
#
# Create all needed fonts from the font list
#
proc createFontSet {fontList} {
foreach fontSpec $fontList {
set name [lindex $fontSpec 0]
set family [lindex $fontSpec 1]
set size [lindex $fontSpec 2]
set weight [lindex $fontSpec 3]
set slant [lindex $fontSpec 4]
set overstrike 0
if { [llength $fontSpec] > 5} {
set overstrike [lindex $fontSpec 5]
}
font create $name -family $family -size $size -weight $weight -slant $slant -overstrike $overstrike
}
}
#############################################################################
#
# Set the font size for the application. Size is one of "small", "normal",
# "large" or "huge"
#
proc setFontSet {size} {
global tkg_initialWidth tkg_initialHeight
global treeItemHeight
global tinyFontSet smallFontSet normalFontSet largeFontSet hugeFontSet
switch $size {
tiny {
set treeItemHeight 13
createFontSet $tinyFontSet
}
small {
set treeItemHeight 15
createFontSet $smallFontSet
}
normal {
set treeItemHeight 17
createFontSet $normalFontSet
}
large {
set treeItemHeight 20
createFontSet $largeFontSet
}
huge {
set tkg_initialWidth 1400
set tkg_initialHeight 850
set treeItemHeight 22
createFontSet $hugeFontSet
}
}
}
proc setupOptions {} {
global tkg_tearawayMenus
#
# I'm not sure how to figure out what the default properties for widgets
# are, so for now we will just create something to get its properites
# then destroy it later. We need to use these default properties for
# our home-grown wigets, but since the actual property values may depend
# on the window manager and theme options, we want to figure out what
# these defaults are so we can blend in with the theme.
#
menubutton .bogus_mb
set activeBackground [.bogus_mb cget -activebackground]
set activeForeground [.bogus_mb cget -activeforeground]
set unselectedBackground [.bogus_mb cget -background]
set foreground [.bogus_mb cget -foreground]
if { $activeBackground == "" } {
set activeBackground "\#dcdcff"
}
if { $activeForeground == "" } {
set activeForeground black
}
if { $unselectedBackground == "" } {
set unselectedBackground gray70
}
if { $foreground == "" } {
set foreground black
}
option add *highlightColor blue
option add *font labelFont
option add *exportselection 0
option add *activeBackground $activeBackground
option add *activeForeground $activeForeground
option add *unselectedBackground $unselectedBackground
option add *borderWidth 1
# option add *background $unselectedBackground
# option add *foreground $foreground
option add *FlatRadioButton*activeBackground $unselectedBackground
option add *FlatRadioButton*background $unselectedBackground
option add *SpreadSheet*headerColor "\#fff0f0"
option add *SpreadSheet*entryColor "\#f0f0ff"
option add *SpreadSheet*selectColor "\#d0ffd0"
option add *SpreadSheet*grabColor "\#80ff80"
option add *SpreadSheet*selectMode multiple
option add *TabBox*foreground $foreground
option add *TabBox*background $unselectedBackground
option add *TabBox*unselectedForeground black
option add *TabBox*unselectedBackground gray60
option add *TabBox*disabledForeground gray30
option add *TabBox*disabledBackground gray60
option add *TkgDialog*borderWidth 1
option add *TkgDialog*relief raised
option add *Entry*background white
option add *LabelFrame*borderWidth 2
option add *LabelFrame*relief groove
option add *Listbox*takeFocus 0
option add *Scrollbar*takeFocus 0
option add *Scrollbar*width 10
option add *Label*font labelFont
option add *Checkbutton*font labelFont
option add *Radiobutton*font labelFont
option add *Button*font buttonFont
option add *Menu*font menuFont
option add *Popup*font menuFont
option add *Menubutton*font menuFont
option add *Entry*font entryFont
option add *Listbox*font entryFont
option add *Text*font hdlFont
option add *Listbox*background white
option add *SpreadSheet*selectmode shift-multiple
option add *Menu*tearOff $tkg_tearawayMenus
#option add *Checkbutton*image [gifI checkoff.gif]
#option add *Checkbutton*selectImage [gifI checkon.gif]
#option add *Checkbutton*compound left
#option add *Checkbutton*indicatorOn 0
#option add *Checkbutton*relief flat
#option add *Checkbutton*boarderwidth 0
destroy .bogus_mb
#
# Disable normal handling of Tab and BackTab
#
#bind all <Tab> ""
#bind all <<PrevWindow>> ""
}
|