-
Notifications
You must be signed in to change notification settings - Fork 5
/
about.tcl
53 lines (51 loc) · 1.62 KB
/
about.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
50
51
52
53
#
# $Id$
#
# Handle the about box.
#
dialog about {
param obliqueFont -*-helvetica-medium-o-*-*-12-* Font
param font -*-helvetica-medium-r-*-*-12-* Font
param boldFont -*-helvetica-bold-r-*-*-18-* Font
method create {} {
global tkinspect tkinspect_library
wm withdraw $self
wm transient $self .
pack [ttk::frame $self.border] -expand 1 -fill both
ttk::label $self.title -text "tkinspect" -font $slot(boldFont)
ttk::label $self.ver \
-text "Release $tkinspect(release) ($tkinspect(release_date))" \
-font $slot(font)
ttk::label $self.com -text "\n Bugs, suggestions and patches to:\n\
http://sourceforge.net/projects/tkcon/ \n" \
-font $slot(obliqueFont)
ttk::frame $self.mug
ttk::label $self.mug.l -justify left \
-text "Originally by Sam Shen\n\Contributions\
from:\nPaul Healy\nJohn LoVerso\n\T. Schotanus\
\nPat Thoyts\nAlexander Caldwell\n"
global about_priv
if ![info exists about_priv(mug_image)] {
set about_priv(mug_image) \
[image create photo -file $tkinspect_library/sls.ppm]
}
ttk::label $self.mug.bm -image $about_priv(mug_image)
pack $self.mug.l -side left -fill both -expand yes
pack $self.mug.bm -fill none
ttk::button $self.ok -text "Ok" -command "destroy $self"
pack $self.title $self.ver $self.com $self.mug \
-in $self.border -side top -fill x
pack $self.ok -in $self.border -side bottom -pady 5
bind $self <Return> "destroy $self"
}
method reconfig {} {
}
method run {} {
wm deiconify $self
focus $self
center_window $self
tkwait visibility $self
grab set $self
tkwait window $self
}
}