Index: openacs-4/packages/acs-templating/tcl/widget-procs.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/acs-templating/tcl/widget-procs.tcl,v
diff -u -r1.25 -r1.26
--- openacs-4/packages/acs-templating/tcl/widget-procs.tcl 5 Oct 2003 17:55:55 -0000 1.25
+++ openacs-4/packages/acs-templating/tcl/widget-procs.tcl 9 Oct 2003 11:07:40 -0000 1.26
@@ -209,13 +209,12 @@
set output [textarea_internal $element(name) attributes $value $mode]
- set spellcheck_properties [template::util::spellcheck::spellcheck_properties -element_ref element]
- set spellcheck [lindex $spellcheck_properties 0]
-
- if { ![string equal ":nospell:" $spellcheck] } {
- set selected_option [lindex $spellcheck_properties 1]
+ # Spell-checker
+ array set spellcheck [template::util::spellcheck::spellcheck_properties -element_ref element]
+
+ if { $spellcheck(render_p) } {
append output "
Spellcheck:
-[menu "$element(id).spellcheck" [nsv_get spellchecker lang_options] $selected_option {}]"
+[menu "$element(id).spellcheck" [nsv_get spellchecker lang_options] $spellcheck(selected_option) {}]"
}
return $output
@@ -330,13 +329,12 @@
upvar $element_reference element
- set spellcheck_properties [template::util::spellcheck::spellcheck_properties -element_ref element]
- set spellcheck [lindex $spellcheck_properties 0]
-
- if { [string equal $element(mode) "edit"] && ![string equal ":nospell:" $spellcheck] } {
- set selected_option [lindex $spellcheck_properties 1]
+ # Spell-checker
+ array set spellcheck [template::util::spellcheck::spellcheck_properties -element_ref element]
+
+ if { [string equal $element(mode) "edit"] && $spellcheck(render_p) } {
return "[input text element $tag_attributes]
Spellcheck:
-[menu "$element(id).spellcheck" [nsv_get spellchecker lang_options] $selected_option {}]"
+[menu "$element(id).spellcheck" [nsv_get spellchecker lang_options] $spellcheck(selected_option) {}]"
} else {
return [input text element $tag_attributes]
}