From b156e79b2cfbe6b998418b9a95240f2a837eb557 Mon Sep 17 00:00:00 2001 From: Tim Edwards Date: Fri, 29 Sep 2023 09:38:48 -0400 Subject: [PATCH] Corrected a toolkit error where the callback to check parameter bounds should be called whenever an entry is changed and either the entry window loses focus or the key is pressed. This had ended up disabled when the scrollbar was added to the dialog window, causing the window hierarchy to change, which invalidated the regexp used to identify the entry and checkbox widgets. --- VERSION | 2 +- tcltk/toolkit.tcl | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/VERSION b/VERSION index 9841aedc..a85871a9 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -8.3.435 +8.3.436 diff --git a/tcltk/toolkit.tcl b/tcltk/toolkit.tcl index b18f5496..1025b696 100644 --- a/tcltk/toolkit.tcl +++ b/tcltk/toolkit.tcl @@ -590,11 +590,11 @@ proc magic::gencell_getparams {} { set parameters [dict create] set slist [grid slaves .params.body.area.edits] foreach s $slist { - if {[regexp {^.params.body.area.edits.(.*)_ent$} $s valid pname] != 0} { + if {[regexp {^\.params\.body\.area\.edits\.(.*)_ent$} $s valid pname] != 0} { set value [subst \$magic::${pname}_val] - } elseif {[regexp {^.params.body.area.edits.(.*)_chk$} $s valid pname] != 0} { + } elseif {[regexp {^\.params\.body\.area\.edits\.(.*)_chk$} $s valid pname] != 0} { set value [subst \$magic::${pname}_val] - } elseif {[regexp {^.params.body.area.edits.(.*)_sel$} $s valid pname] != 0} { + } elseif {[regexp {^\.params\.body\.area\.edits\.(.*)_sel$} $s valid pname] != 0} { set value [subst \$magic::${pname}_val] } dict set parameters $pname $value @@ -1035,7 +1035,7 @@ proc magic::add_entry {pname ptext parameters} { proc magic::add_check_callbacks {gencell_type library} { set wlist [winfo children .params.body.area.edits] foreach w $wlist { - if {[regexp {\.params\.edits\.(.+)_ent} $w valid pname]} { + if {[regexp {\.params\.body\.area\.edits\.(.+)_ent} $w valid pname]} { # Add callback on enter or focus out bind $w \ "magic::update_dialog {} $pname $gencell_type $library"