File tree Expand file tree Collapse file tree 2 files changed +8
-10
lines changed Expand file tree Collapse file tree 2 files changed +8
-10
lines changed Original file line number Diff line number Diff line change 3
3
# # This demo shows information about the Gtk/GNOME style currently in use.
4
4
# #
5
5
# ##############################################################################
6
- if {[catch {package require Ttk}]} {
7
- package require tile
8
- }
9
- ttk::setTheme tilegtk
6
+ package require Tk
7
+ ttk::setTheme gtkTtk
10
8
11
9
set win {}
12
10
label $win .lbl_option -text Option:
@@ -23,7 +21,7 @@ foreach base {fg bg base text light mid dark text_aa} {
23
21
label $win .$base -text " $base :" -anchor w
24
22
grid $win .$base -row $row -column $col
25
23
foreach state {NORMAL PRELIGHT ACTIVE SELECTED INSENSITIVE} {
26
- set colour [ttk::theme::tilegtk ::currentThemeColour ${base} ($state )]
24
+ set colour [ttk::theme::gtkTtk ::currentThemeColour ${base} ($state )]
27
25
label $win .${base} _$state -background $colour \
28
26
-relief raised -borderwidth 1
29
27
label $win .${base} _${state} _value -text $colour
Original file line number Diff line number Diff line change 1
1
#
2
2
# $Id: autocomplete.tcl,v 1.1 2008/08/03 14:52:09 petasis Exp $
3
3
#
4
- # Demonstration of inline auto-completion for Tile combobox widgets.
4
+ # Demonstration of inline auto-completion for Ttk combobox widgets.
5
5
#
6
6
# Usage:
7
7
#
16
16
# overhead.
17
17
#
18
18
19
- namespace eval tile ::combobox {
19
+ namespace eval ttk ::combobox {
20
20
namespace export enableAutocomplete
21
21
}
22
22
23
23
# # enableAutocomplete
24
24
#
25
25
# Enable inline auto-completion for the specified combobox widget.
26
26
#
27
- proc tile ::combobox::enableAutocomplete { w {presorted 1} } {
27
+ proc ttk ::combobox::enableAutocomplete { w {presorted 1} } {
28
28
bind $w <KeyPress> [namespace code [list DoAutoComplete %W %A $presorted ]]
29
29
}
30
30
31
31
# # DoAutoComplete
32
32
#
33
33
# Perform inline auto-completion of typed text in the combobox.
34
34
#
35
- proc tile ::combobox::DoAutoComplete { w s presorted } {
35
+ proc ttk ::combobox::DoAutoComplete { w s presorted } {
36
36
set old [$w get]
37
- tile ::entry::Insert $w $s
37
+ ttk ::entry::Insert $w $s
38
38
set new [$w get]
39
39
40
40
# Only auto-complete if the string length has changed due to insertion.
You can’t perform that action at this time.
0 commit comments