Index: openacs-4/packages/xotcl-core/tcl/30-widget-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xotcl-core/tcl/30-widget-procs.tcl,v diff -u -r1.63 -r1.64 --- openacs-4/packages/xotcl-core/tcl/30-widget-procs.tcl 16 Feb 2018 16:51:15 -0000 1.63 +++ openacs-4/packages/xotcl-core/tcl/30-widget-procs.tcl 21 Mar 2018 19:37:57 -0000 1.64 @@ -16,15 +16,15 @@ dom createDocument html doc set root [$doc documentElement] if {!$page} { - $root appendFromScript {my render} + $root appendFromScript {:render} set n [$root childNode] if {$n eq ""} { return "" } return [$n asHTML] } else { set slave [$master decorate $root] - $slave appendFromScript {my render} + $slave appendFromScript {:render} ns_return 200 text/html [$root asHTML] } } @@ -70,9 +70,9 @@ # # Create a new instance of the current class and configure it. # - #my log "tdom START $level [self], cmd='$configurecmds'" + #:log "tdom START $level [self], cmd='$configurecmds'" set me [:new -destroy_on_cleanup {*}$configurecmds] - #my log "tdom CREATED $level $me ([$me info class])" + #:log "tdom CREATED $level $me ([$me info class])" # # If we are not on the topmost level, add the created object @@ -81,7 +81,7 @@ set stack($level) $me if {$level > 1} { set parent $stack([expr {$level - 1}]) - #my log "tdom ADD $level $me to $parent ([$parent info class])" + #:log "tdom ADD $level $me to $parent ([$parent info class])" $parent add $me } @@ -96,7 +96,7 @@ # namespace eval ::xo::tmp [list namespace import -force [$cl autoimport]] # } # } - # #my log "tdom CMDS $level [lsort [info commands ::xo::tmp::*]]" + # #:log "tdom CMDS $level [lsort [info commands ::xo::tmp::*]]" if {$createcmd ne ""} { # @@ -111,14 +111,14 @@ # the topmost element is automatically rendered. This makes # the ::xo::tdom classes behave more like plain tDOM commands. # - #my log "tdom AUTO $level [$me autorender]" + #:log "tdom AUTO $level [$me autorender]" if {$level == 1 && [$me autorender]} { - #my log "tdom RNDR $level $me render" + #:log "tdom RNDR $level $me render" $me render } - #my log "tdom END $level [self] me=$me" + #:log "tdom END $level [self] me=$me" set level [:incr_level -1] return $me } @@ -145,7 +145,7 @@ } else { set HTMLattribute $attribute } - #my msg "[:name] check for $attribute => [info exists :$attribute]" + #:msg "[:name] check for $attribute => [info exists :$attribute]" if {[info exists :$attribute]} { lappend pairs $HTMLattribute [set :$attribute] } @@ -169,7 +169,7 @@ } else { set HTMLattribute $attribute } - #my msg "[:name] check for $attribute => [info exists :$attribute]" + #:msg "[:name] check for $attribute => [info exists :$attribute]" if {[:uplevel [list info exists $attribute]]} { lappend pairs $HTMLattribute [:uplevel [list set $attribute]] } @@ -342,7 +342,7 @@ return [::xo::localize [set :$attr]] } \ -instproc render_localizer {} { - #my log "-- " + #:log "-- " if {[info exists :__localizer]} { foreach l ${:__localizer} { $l render @@ -390,9 +390,9 @@ }] Table instproc destroy {} { - #my log "-- " + #:log "-- " foreach c {__bulkactions __actions __columns} { - #my log "-- namespace eval [self]::$c {namespace forget *}" + #:log "-- namespace eval [self]::$c {namespace forget *}" namespace eval [self]::$c {namespace forget *} } next @@ -423,19 +423,19 @@ } Table instproc render_with {renderer trn_mixin} { - #my log "-- renderer=$renderer" + #:log "-- renderer=$renderer" set cl [self class] :mixin ${cl}::$renderer foreach child [$cl info classchildren] { - #my log "-- $child class [$child info class] " + #:log "-- $child class [$child info class] " set mixinname ${cl}::${renderer}::[namespace tail $child] if {[::xotcl::Object isclass $mixinname]} { #if {![$child istype ::xo::OrderedComposite::Child]} continue $child instmixin $mixinname if {$trn_mixin ne ""} {$child instmixin add $trn_mixin} - #my log "-- $child using instmixin <[$child info instmixin]>" + #:log "-- $child using instmixin <[$child info instmixin]>" } else { - #my log "-- no mixin $mixinname" + #:log "-- no mixin $mixinname" } } Table::Line instmixin $trn_mixin @@ -520,7 +520,7 @@ -superclass ::xo::OrderedComposite::Child \ -parameter {name id {html {}} {hide 0}} \ -instproc actions {cmd} { - #my init + #:init set grandParent [[:info parent] info parent] if {![info exists :name]} {set :name [namespace tail [self]]} #set M [::xo::OrderedComposite create ${grandParent}::__bulkactions] @@ -559,7 +559,7 @@ lappend slots [list -[:name].CSSclass [:CSSclass]] foreach att {width height border title alt} { if {[info exists :$att]} { - lappend slots [list -[:name].$att [my $att]] + lappend slots [list -[:name].$att [:$att]] } else { lappend slots [list -[:name].$att] } @@ -612,7 +612,7 @@ Class create TABLE \ -superclass ::xo::Drawable \ -instproc init_renderer {} { - #my log "--" + #:log "--" set :__rowcount 0 set :css.table-class list set :css.tr.even-class list-even @@ -671,37 +671,35 @@ html::tr {html::td { html::t ${:no_data}}} } else { foreach line [:children] { - #my log "--LINE vars=[:info vars] cL: [[self class] info vars] r=[:renderer]" - html::tr -class [expr {[incr :__rowcount]%2 ? - [:set css.tr.odd-class] : - [:set css.tr.even-class] }] { - foreach field [[self]::__columns children] { - html::td [concat [list class list] [$field html]] { - $field render-data $line - } - } - } + #:log "--LINE vars=[:info vars] cL: [[self class] info vars] r=[:renderer]" + html::tr -class [expr {[incr :__rowcount]%2 ? ${:css.tr.odd-class} : ${:css.tr.even-class}}] { + foreach field [[self]::__columns children] { + html::td [concat [list class list] [$field html]] { + $field render-data $line + } + } + } } } } TABLE instproc render {} { - if {![:isobject [self]::__actions]} {my actions {}} - if {![:isobject [self]::__bulkactions]} {my bulkactions {}} + if {![:isobject [self]::__actions]} {:actions {}} + if {![:isobject [self]::__bulkactions]} {:bulkactions {}} set bulkactions [[self]::__bulkactions children] if {$bulkactions eq ""} { - html::table -class [:set css.table-class] { - my render-actions - my render-body + html::table -class ${:css.table-class} { + :render-actions + :render-body } } else { set name [[self]::__bulkactions set __identifier] html::form -name $name -method POST { - html::table -class [:set css.table-class] { - my render-actions - my render-body + html::table -class ${:css.table-class} { + :render-actions + :render-body } - my render-bulkactions + :render-bulkactions } } } @@ -718,7 +716,7 @@ html::a -class button -title [:_ tooltip] -href [:url] { html::t [:_ label] } - #my log "-- " + #:log "-- " } #-proc destroy {} { # :log "-- DESTROY" @@ -835,7 +833,7 @@ Class create TABLE::BulkAction -superclass ::xo::Drawable TABLE::BulkAction instproc render {} { set name [:name] - #my msg [:serialize] + #:msg [:serialize] html::th -class list { html::input -type checkbox -name __bulkaction -id __bulkaction \ -title "Mark/Unmark all rows" @@ -849,7 +847,7 @@ } TABLE::BulkAction instproc render-data {line} { - #my msg [:serialize] + #:msg [:serialize] set name [:name] set value [$line set [:id]] html::input -type checkbox -name $name -value $value \ @@ -870,21 +868,21 @@ } } \ -instproc render {} { - if {![:isobject [self]::__actions]} {my actions {}} - if {![:isobject [self]::__bulkactions]} {my __bulkactions {}} + if {![:isobject [self]::__actions]} {:actions {}} + if {![:isobject [self]::__bulkactions]} {:__bulkactions {}} set bulkactions [[self]::__bulkactions children] html::div { - my render-actions + :render-actions if {$bulkactions eq ""} { html::div -class table { - html::table -class [:set css.table-class] {my render-body} + html::table -class ${:css.table-class} {:render-body} } } else { set name [[self]::__bulkactions set __identifier] html::form -name $name -action "" { html::div -class table { - html::table -class [:set css.table-class] {my render-body} - my render-bulkactions + html::table -class ${:css.table-class} {:render-body} + :render-bulkactions } } } Index: openacs-4/packages/xowiki/tcl/bootstrap-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/bootstrap-procs.tcl,v diff -u -r1.7 -r1.8 --- openacs-4/packages/xowiki/tcl/bootstrap-procs.tcl 14 Mar 2018 15:40:49 -0000 1.7 +++ openacs-4/packages/xowiki/tcl/bootstrap-procs.tcl 21 Mar 2018 19:39:52 -0000 1.8 @@ -436,7 +436,7 @@ set children [:children] html::tbody { foreach line [:children] { - html::tr -class [expr {[incr :__rowcount]%2 ? [:set css.tr.odd-class] : [:set css.tr.even-class] }] { + html::tr -class [expr {[incr :__rowcount]%2 ? ${:css.tr.odd-class} : ${:css.tr.even-class} }] { foreach field [[self]::__columns children] { if {[$field hide]} continue if {[$field istype HiddenField]} continue 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.259 -r1.260 --- openacs-4/packages/xowiki/tcl/form-field-procs.tcl 14 Mar 2018 15:40:49 -0000 1.259 +++ openacs-4/packages/xowiki/tcl/form-field-procs.tcl 21 Mar 2018 19:39:52 -0000 1.260 @@ -3017,7 +3017,9 @@ MI instproc value args { if {[llength $args] == 0} {return ${:value}} else { set v [lindex $args 0] - if {$v eq ""} {return [:set value ""]} else { + if {$v eq ""} { + set :value "" + } else { # round to 5 minutes set :value [lindex ${:options} [expr {($v + 2) / 5}] 1] } Index: openacs-4/packages/xowiki/tcl/includelet-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/includelet-procs.tcl,v diff -u -r1.211 -r1.212 --- openacs-4/packages/xowiki/tcl/includelet-procs.tcl 14 Mar 2018 15:40:49 -0000 1.211 +++ openacs-4/packages/xowiki/tcl/includelet-procs.tcl 21 Mar 2018 19:39:52 -0000 1.212 @@ -1836,8 +1836,8 @@ } PageReorderSupport instproc page_reorder_item_id {-ID -prefix_js -page_order js_} { :upvar $js_ js - set key __count($prefix_js) - if {[info exists :$key]} {set p [incr :$key]} {set p [:set $key 0]} + set key :__count($prefix_js) + set p [incr $key] set id ${ID}_${prefix_js}_$p append js "YAHOO.xo_page_order_region.DDApp.cd\['$id'\] = '$page_order';\n" return $id @@ -1945,7 +1945,7 @@ if {$source ne ""} { # add the page_order to the objects foreach p [$pages children] { - $p set page_order [:set page_order([$p set name])] + $p set page_order [set :page_order([$p set name])] } } Index: openacs-4/packages/xowiki/tcl/xowiki-form-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/xowiki-form-procs.tcl,v diff -u -r1.140 -r1.141 --- openacs-4/packages/xowiki/tcl/xowiki-form-procs.tcl 22 Dec 2017 13:51:41 -0000 1.140 +++ openacs-4/packages/xowiki/tcl/xowiki-form-procs.tcl 21 Mar 2018 19:39:52 -0000 1.141 @@ -56,7 +56,7 @@ foreach __field $field_list { # if there is no field spec, use the default from the slot definitions - set __spec [expr {[:exists f.$__field] ? [:set f.$__field] : "="}] + set __spec [expr {[info exists :f.$__field] ? [set :f.$__field] : "="}] set __wspec [lindex $__spec 0] #my msg "$__field: wspec=$__wspec, spec=$__spec" Index: openacs-4/packages/xowiki/tcl/xowiki-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/xowiki-procs.tcl,v diff -u -r1.506 -r1.507 --- openacs-4/packages/xowiki/tcl/xowiki-procs.tcl 7 Mar 2018 06:58:29 -0000 1.506 +++ openacs-4/packages/xowiki/tcl/xowiki-procs.tcl 21 Mar 2018 19:39:52 -0000 1.507 @@ -1096,7 +1096,7 @@ error "two arguments for match required, [llength $value] passed (arguments='$value')" } ad_try { - set success [string match [lindex $value 1] [:set [lindex $value 0]]] + set success [string match [lindex $value 1] [set :[lindex $value 0]]] } on error {errorMsg} { ns_log error "error during condition match: $errorMsg" set success 0 @@ -1124,7 +1124,7 @@ error "two arguments for regexp required, [llength $value] passed (arguments='$value')" } ad_try { - set success [regexp [lindex $value 1] [:set [lindex $value 0]]] + set success [regexp [lindex $value 1] [set :[lindex $value 0]]] } on error {errorMsg} { ns_log error "error during condition regexp: $errorMsg" set success 0 @@ -3494,7 +3494,7 @@ } #FormPage instproc save args { - # :debug_msg [:set instance attributes] + # :debug_msg [set :instance attributes] # :log "IA=${:instance_attributes}" # next #} @@ -3851,7 +3851,7 @@ if {[info exists op_map($op,sql)]} { lappend sql_clause [subst -nocommands $op_map($op,sql)] if {[info exists :$lhs_var]} { - set lhs_var "\[:set $lhs_var\]" + set lhs_var "\[set :$lhs_var\]" lappend tcl_clause [subst -nocommands $op_map($op,tcl)] } else { :msg "ignoring unknown variable $lhs_var in expression" Index: openacs-4/packages/xowiki/tcl/xowiki-www-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/xowiki-www-procs.tcl,v diff -u -r1.343 -r1.344 --- openacs-4/packages/xowiki/tcl/xowiki-www-procs.tcl 20 Mar 2018 21:48:15 -0000 1.343 +++ openacs-4/packages/xowiki/tcl/xowiki-www-procs.tcl 21 Mar 2018 19:39:52 -0000 1.344 @@ -2126,7 +2126,7 @@ _* { set f [:lookup_form_field -name $c $form_fields] set processed($c) 1 - :set [string range $c 1 end] [$f value] + set :[string range $c 1 end] [$f value] } default { set f [:lookup_form_field -name $c $form_fields] Index: openacs-4/packages/xowiki/tcl/yui-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/yui-procs.tcl,v diff -u -r1.8 -r1.9 --- openacs-4/packages/xowiki/tcl/yui-procs.tcl 14 Mar 2018 15:40:49 -0000 1.8 +++ openacs-4/packages/xowiki/tcl/yui-procs.tcl 21 Mar 2018 19:39:52 -0000 1.9 @@ -541,7 +541,7 @@ set children [:children] html::tbody { foreach line [:children] { - html::tr -class [expr {[incr :__rowcount]%2 ? [:set css.tr.odd-class] : [:set css.tr.even-class] }] { + html::tr -class [expr {[incr :__rowcount]%2 ? ${:css.tr.odd-class} : ${:css.tr.even-class} }] { foreach field [[self]::__columns children] { if {[$field hide]} continue html::td [concat [list class list] [$field html]] { @@ -555,20 +555,20 @@ YUIDataTableRenderer instproc render {} { ::YUI::loader require -module "datatable" - if {![:isobject [self]::__actions]} {my actions {}} - if {![:isobject [self]::__bulkactions]} {my __bulkactions {}} + if {![:isobject [self]::__actions]} {:actions {}} + if {![:isobject [self]::__bulkactions]} {:__bulkactions {}} set bulkactions [[self]::__bulkactions children] if {[llength $bulkactions]>0} { set name [[self]::__bulkactions set __identifier] } else { set name [::xowiki::Includelet js_name [self]] } - # TODO: maybe use skin everywhere? hen to use style/CSSclass or skin? + # TODO: maybe use skin everywhere? When to use style/CSSclass or skin? set skin [expr {[info exists :skin] ? ${:skin} : ""}] html::div -id ${:id}_wrapper -class $skin { html::form -name $name -id $name -method POST { html::div -id ${:id}_container { - html::table -id ${:id} -class [:set css.table-class] { + html::table -id ${:id} -class ${:css.table-class} { # TODO do i need that? my render-actions my render-body