Unnamed Fossil Project

Check-in [5c2b7dd74b]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:initial version
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:5c2b7dd74b87e780597bbe7b8d9dd37e0a391fab
User & Date: arnulf 2013-09-21 20:38:20
Context
2013-09-21
20:39
fixes and code for useQuadColor Leaf check-in: 131f274417 user: arnulf tags: trunk
20:38
initial version check-in: 5c2b7dd74b user: arnulf tags: trunk
19:24
initial version check-in: 4711f9ace7 user: arnulf tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Added nt4.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
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
295
296
297
298
299
300
301
302
303
package require Itcl 4.0
package require Tk
set auto_path [concat [list .] $auto_path]
package require themedntk
#load /home/arnulf/lib/libtk8.6.so 
package require gles2
lappend auto_path library

#TEMPORARY!!!
source /home/arnulf/SOURCES/TCL/itcl4.0head/itcl/library/itclHullCmds.tcl

#set cmd "puts stderr \"======= frame button 1 pressed\""
#bind .gles2 <Button-1> $cmd

::ntk::Debug::DebugInit
#source library/ntkStyleTheme.tcl
#source library/styleThemeInit.tcl
lappend auto_path library

::gles2::builtin::setuprenderbuffer
::gles2::builtin::setupframebuffer
::gles2::builtin::clearbuffer 216 216 216 255
::gles2::builtin::compileshaders notexture
::gles2::swapbuffers

set depth 0
if {[llength $argv] > 0} {
    set depth [lindex $argv 0]
}
puts stderr "depth!$depth!"
set ::useQuadColor 1
if {0} {
set ::tb1 [::ntk::button .b1 -text HelloB -depth $depth]
puts stderr "button created!$::tb1!"
::ntk::classes::place::place $::tb1 30 0
set ch [read stdin 1]

#::ntk::classes::theme::ThemeUse classic
#set ::tmb1 [::ntk::menubutton .mb1 -text HelloMB -depth $depth]
#::ntk::classes::place::place $::tmb1 30 0

#set ::trb1 [::ntk::radiobutton .rb1 -text HelloRB]
#::ntk::classes::place::place $::trb1 30 0

#set ::te1 [::ntk::entry .te1]
#::ntk::classes::place::place $::te1 30 0

#set ::tcb1 [::ntk::combobox .tcb1 -values [list val1 val2 val3]]
#::ntk::classes::place::place $::tcb1 30 0

#set ::tsb1 [::ntk::scrollbar .tsb1]
#::ntk::classes::place::place $::tsb1 30 0

#set ::tf1 [::ntk::frame .tf1]
#::ntk::classes::place::place $::tf1 30 0

#set ::tlf1 [::ntk::labelframe .tlf1]
#::ntk::classes::place::place $::tlf1 30 0

#set ::tpw1 [::ntk::panedwindow .tpw1 -orient horizontal]
#set ::l2 [::ntk::label .l2 -text hello]
#set ::l3 [::ntk::label .l3 -text world]
#$::tpw1 add .l2
#$::tpw1 add .l3
#$::tpw1 UpdateLayout
#$::tpw1 SizeChanged "" width height
#::ntk::classes::place::place $::tpw1 30 0

#set ::ttv1 [::ntk::treeview .ttv1 -columns [list a b c]]
#::ntk::classes::place::place $::ttv1 30 0
#$::ttv1 insert {} end -id newnode -text "New node"
#$::ttv1 insert newnode 0 -id newnode.n1 -text "Foo1"
#$::ttv1 insert newnode 0 -id newnode.n2 -text "Foo2"

#set ch [read stdin 1]
#$::ttv1 item newnode -open 1
#set ch [read stdin 1]
#$::ttv1 item newnode -open 0
#set ch [read stdin 1]

#$::te1 insert insert "abc"
#$::tcb1 insert insert "abc"
#set ch [read stdin 1]
#$::te1 insert insert "def"
#$::tcb1 insert insert "abc"
#set ch [read stdin 1]
#$::te1 insert insert "ghi123"
#$::tcb1 insert insert "abc"
#set ch [read stdin 1]
}

if {1} {
proc MakeButtons {num} {
if {1} {
#puts stderr "Button"
#::ntk::classes::styleTheme::themeUse default
set ::tb1 [::ntk::button .b$num -text HelloB -depth $::depth]
}

if {1} {
#puts stderr "Label"
set ::tl1 [::ntk::label .l$num -text "Hello World"]
}

if {1} {
#puts stderr "Checkbutton"
set ::tcb1 [::ntk::checkbutton .cb$num -text "H WorldC"]
}

if {1} {
#puts stderr "Radiobutton"
set ::trb1 [::ntk::radiobutton .rb$num -text "H WorldR"]
}

if {1} {
#puts stderr "Menubutton"
set ::tmb1 [::ntk::menubutton .mb$num -text "H WorldM" -depth $::depth]
}
}

MakeButtons 1

proc ShowButtons {xoffset} {
if {1} {
#puts stderr "Button"
::ntk::classes::place::place $::tb1 30 0
#puts stderr "Button done"
}

if {1} {
#puts stderr "Label"
::ntk::classes::place::place $::tl1 50 30
}

if {1} {
#puts stderr "Checkbutton"
::ntk::classes::place::place $::tcb1 70 60
}

if {1} {
#puts stderr "Radiobutton"
::ntk::classes::place::place $::trb1 90 90
}

if {1} {
#puts stderr "Menubutton"
::ntk::classes::place::place $::tmb1 110 120
}
}

proc ShowButtons2 {xoffset} {
if {1} {
#puts stderr "Button"
::ntk::classes::place::place $::tb1 -90 120
#puts stderr "Button done"
}

if {1} {
#puts stderr "Label"
::ntk::classes::place::place $::tl1 -60 150
}

if {1} {
#puts stderr "Checkbutton"
::ntk::classes::place::place $::tcb1 -30 180
}

if {1} {
#puts stderr "Radiobutton"
::ntk::classes::place::place $::trb1 0 210
}

if {1} {
#puts stderr "Menubutton"
::ntk::classes::place::place $::tmb1 30 240
}
}

proc ShowButtons3 {xoffset} {
if {1} {
#puts stderr "Button"
::ntk::classes::place::place $::tb1 290 80
#puts stderr "Button done"
}

if {1} {
#puts stderr "Label"
::ntk::classes::place::place $::tl1 260 110
}

if {1} {
#puts stderr "Checkbutton"
::ntk::classes::place::place $::tcb1 230 140
}

if {1} {
#puts stderr "Radiobutton"
::ntk::classes::place::place $::trb1 200 170
}

if {1} {
#puts stderr "Menubutton"
::ntk::classes::place::place $::tmb1 170 200
}
}

proc ShowButtons4 {xoffset} {
if {1} {
#puts stderr "Button"
::ntk::classes::place::place $::tb1 350 0
#puts stderr "Button done"
}

if {1} {
#puts stderr "Label"
::ntk::classes::place::place $::tl1 350 40
}

if {1} {
#puts stderr "Checkbutton"
::ntk::classes::place::place $::tcb1 350 70
}

if {1} {
#puts stderr "Radiobutton"
::ntk::classes::place::place $::trb1 350 100
}

if {1} {
#puts stderr "Menubutton"
::ntk::classes::place::place $::tmb1 350 130
}
}

proc GenerateEvents {} {
if {1} {
if {1} {
set ch [read stdin 1]
::ntk::generateevent::generateevent $::trb1 Enter ""
}

if {1} {
set ch [read stdin 1]
::ntk::generateevent::generateevent $::trb1 Leave ""
}

if {1} {
set ch [read stdin 1]
set eventInfo [dict create]
::ntk::generateevent::generateevent $::tcb1 ButtonPress Button1

::ntk::generateevent::generateevent $::tcb1 ButtonRelease Button1
}

if {1} {
set ch [read stdin 1]
::ntk::generateevent::generateevent $::trb1 FocusIn Button1
::ntk::generateevent::generateevent $::trb1 ButtonPress Button1
::ntk::generateevent::generateevent $::trb1 ButtonRelease Button1

set ch [read stdin 1]
::ntk::generateevent::generateevent $::trb1 FocusOut Button1
}

if {1} {
set ch [read stdin 1]
::ntk::generateevent::generateevent $::tb1 FocusIn Button1
::ntk::generateevent::generateevent $::tb1 ButtonPress Button1
::ntk::generateevent::generateevent $::tb1 ButtonRelease Button1

set ch [read stdin 1]
::ntk::generateevent::generateevent $::tb1 FocusOut Button1
}
}
}

if {1} {
ShowButtons 0
set ch [read stdin 1]
::gles2::builtin::rotate 0 0 45
ShowButtons2 0
::gles2::builtin::rotate -45 -45 -45
set ch [read stdin 1]
ShowButtons3 0
GenerateEvents
}

set ch [read stdin 1]
::ntk::classes::widgetInfo::destroyWidget $::tb1
::ntk::classes::widgetInfo::destroyWidget $::tl1
::ntk::classes::widgetInfo::destroyWidget $::tcb1
::ntk::classes::widgetInfo::destroyWidget $::trb1
::ntk::classes::widgetInfo::destroyWidget $::tmb1
::ntk::classes::theme::ThemeUse classic
::gles2::builtin::rotate 0 0 0
MakeButtons 2
ShowButtons4 0

GenerateEvents
#::ntk::classes::theme::ShowPkg
#$tb1 ShowCore

}