move reset_defaults to beginning of loop

This commit is contained in:
Seb Shader 2021-11-04 12:01:56 -07:00
parent 0e491e2fb4
commit 29e0670602

View file

@ -241,6 +241,7 @@ proc ::color-themes::opendialog {} {
set counter 0 set counter 0
set names "" set names ""
foreach i $themes { foreach i $themes {
::color-themes::reset_defaults
source ${i} source ${i}
set name [{::color-themes::trimsubstringright} [file tail ${i}] -plugin.tcl] set name [{::color-themes::trimsubstringright} [file tail ${i}] -plugin.tcl]
lappend names $name lappend names $name
@ -405,7 +406,7 @@ proc ::color-themes::opendialog {} {
-anchor nw -font $fontinfo -fill $::pd_colors(graph_text) -anchor nw -font $fontinfo -fill $::pd_colors(graph_text)
incr height $boxincr incr height $boxincr
incr counter incr counter
::color-themes::reset_defaults
} }
set canvas_height $height set canvas_height $height
set num_themes $counter set num_themes $counter