ttk::notebook $app.nb -style ButtonNotebook
# Always create the debug tab - but hide it unless -debug given
- set debugf [frame $app.nb.debugf -borderwidth 0 -highlightthickness 0]
- set debug [ttk::frame $app.nb.debugf.debug -style ChatwidgetFrame]
+ set debug [ttk::frame $app.nb.debug -style ChatwidgetFrame]
text $debug.text -relief flat -borderwidth 0 -wrap word \
-state disabled -font DebugFont \
-yscrollcommand [list $debug.vs set]
grid $debug.text $debug.vs -sticky news -padx 1 -pady 1
grid rowconfigure $debug 0 -weight 1
grid columnconfigure $debug 0 -weight 1
- grid $debug -sticky news
- grid rowconfigure $debugf 0 -weight 1
- grid columnconfigure $debugf 0 -weight 1
- $app.nb add $debugf -state hidden -text [mc "Debug"]
- if {$opts(-debug)} { $app.nb tab $debugf -state normal }
+ $app.nb add $debug -state hidden -text [mc "Debug"]
+ if {$opts(-debug)} { $app.nb tab $debug -state normal }
set status [ttk::frame $app.status]
ttk::label $status.pane0 -anchor w
proc Debug {Chat message {type debug}} {
upvar #0 $Chat chat
- set w $chat(app).nb.debugf.debug.text
+ set w $chat(app).nb.debug.text
if {[winfo exists $w]} {
set t [clock format [clock seconds] -format "%H:%M:%S"]
$w configure -state normal
wm title $tab $title
wm protocol $tab WM_DELETE_WINDOW \
[namespace code [list AttachWindow $app $tab $index]]
+ raise $tab
}
}
proc AttachWindow {app w {index end}} {