Index: openacs-4/packages/xowiki/tcl/form-field-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/form-field-procs.tcl,v diff -u -r1.284.2.166 -r1.284.2.167 --- openacs-4/packages/xowiki/tcl/form-field-procs.tcl 2 Aug 2021 21:23:19 -0000 1.284.2.166 +++ openacs-4/packages/xowiki/tcl/form-field-procs.tcl 3 Aug 2021 17:26:45 -0000 1.284.2.167 @@ -330,7 +330,6 @@ } FormField instproc behavior {mixin} { - # # Specify the behavior of a form field via # per object mixins @@ -356,6 +355,7 @@ FormField instproc interprete_single_spec {s} { if {$s eq ""} return + #ns_log notice "${:name} interprete_single_spec '$s'" set package_id [${:object} package_id] set s [::xowiki::formfield::FormField get_single_spec -object ${:object} -package_id $package_id $s] @@ -3109,11 +3109,19 @@ {wiki false} } + richtext instproc clear_editor_mixins {} { + foreach m [:info mixin] { + if {[$m exists editor_mixin]} { + :mixin delete $m + } + } + } + richtext instproc editor {args} { # # TODO: this should be made a slot setting # - #:msg "setting editor for ${:name}, args=$args,[llength $args]" + #:log "RICHTEXT setting editor for ${:name}, args=$args,[llength $args]" if {[llength $args] == 0} { return ${:editor} } @@ -3135,6 +3143,7 @@ # if {$editor eq "none"} { set :editor "none" + :clear_editor_mixins return ${:editor} } @@ -3149,7 +3158,7 @@ error [_ xowiki.error-form_constraint-unknown_editor \ [list name ${:name} editor [:editor] editors $editors]] } - foreach m [:info mixin] {if {[$m exists editor_mixin]} {:mixin delete $m}} + :clear_editor_mixins :mixin add $editor_class #:msg "MIXIN $editor: [:info precedence]" :reset_parameter @@ -3189,6 +3198,8 @@ :editor ${:editor} :initialize } + + #set :__initialized 1 } richtext instproc render_richtext_as_div {} { @@ -3252,12 +3263,11 @@ # skin: kama, v2, office2003 # extraPlugins: tcl-list, is converted to comma list for js # - # This formfield class is deprecated, use richtext::ckeditor4 - # instead. + # This formfield class being based on ckeditor3 is deprecated, + # use richtext::ckeditor4 instead. # ########################################################### Class create richtext::ckeditor -superclass richtext -parameter { - {editor ckeditor} {mode wysiwyg} {skin kama} {toolbar Full} @@ -3442,7 +3452,6 @@ # ########################################################### Class create richtext::ckeditor4 -superclass richtext -parameter { - {editor ckeditor4} {mode wysiwyg} {skin "bootstrapck,/resources/xowiki/ckeditor4/skins/bootstrapck/"} {toolbar Full} @@ -3779,7 +3788,6 @@ # ########################################################### Class create richtext::wym -superclass richtext -parameter { - {editor wym} {CSSclass wymeditor} width height