[Laszlo-checkins] r10877 - in openlaszlo/trunk: WEB-INF/lps/lfc/views lps/components/base lps/components/debugger lps/components/extensions/av lps/components/incubator lps/components/incubator/rich-text lps/components/lz

pbr@openlaszlo.org pbr at openlaszlo.org
Thu Sep 4 16:18:01 PDT 2008


Author: pbr
Date: 2008-09-04 16:17:51 -0700 (Thu, 04 Sep 2008)
New Revision: 10877

Modified:
   openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloCanvas.lzs
   openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs
   openlaszlo/trunk/WEB-INF/lps/lfc/views/LzInputText.lzs
   openlaszlo/trunk/WEB-INF/lps/lfc/views/LzText.lzs
   openlaszlo/trunk/lps/components/base/basebutton.lzx
   openlaszlo/trunk/lps/components/base/basecombobox.lzx
   openlaszlo/trunk/lps/components/base/baselistitem.lzx
   openlaszlo/trunk/lps/components/base/basetabs.lzx
   openlaszlo/trunk/lps/components/base/basetabslider.lzx
   openlaszlo/trunk/lps/components/base/basewindow.lzx
   openlaszlo/trunk/lps/components/base/swatchview.lzx
   openlaszlo/trunk/lps/components/debugger/debugger.lzx
   openlaszlo/trunk/lps/components/debugger/newcontent.lzx
   openlaszlo/trunk/lps/components/debugger/scrollingtext.lzx
   openlaszlo/trunk/lps/components/extensions/av/videoview.lzx
   openlaszlo/trunk/lps/components/incubator/borderinput.lzx
   openlaszlo/trunk/lps/components/incubator/rich-text/formatfontcolor.lzx
   openlaszlo/trunk/lps/components/lz/alert.lzx
   openlaszlo/trunk/lps/components/lz/floatinglist.lzx
   openlaszlo/trunk/lps/components/lz/gridcolumn.lzx
   openlaszlo/trunk/lps/components/lz/list.lzx
   openlaszlo/trunk/lps/components/lz/plainfloatinglist.lzx
   openlaszlo/trunk/lps/components/lz/tabelement.lzx
   openlaszlo/trunk/lps/components/lz/tabslider.lzx
   openlaszlo/trunk/lps/components/lz/windowpanel.lzx
Log:
Change 20080902-Philip-4 by Philip at Philip-DC on 2008-09-02 10:55:41 EDT
     in /cygdrive/f/laszlo/svn/src/svn/openlaszlo/trunk
     for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: Modify components to use setters tag

New Features:

Bugs Fixed: LPP-5644 (partial)

Technical Reviewer: ptw
QA Reviewer: (pending)
Doc Reviewer: (pending)

Documentation:

Release Notes:

Details:
I modified the components to use the setters tag. I also modified the old setter and $lzc_$set_* methods in view/canvas/text/inputtext. I added an explicit this to some of the states in the components (form, gridcolumn, modaldialog, window, windowpanel). Some of the components needs extra work to get the desired behavior of bgcolor (windowpanel, list, tabslider, tabelement).

Once this changeset is approved I will modify the setters in the rest of the LFC, and start converting the components and LFC to use setAttribute instead of set*. Until then, running with debugging on will generate a lot of deprecated warnings,

Tests:
   /test/smoke/smokecheck.lzx in swf8/dhtml
   componentsampler, list, grid all work in swf8/swf9/dhtml.
   lzpix/amazon runs in swf8/swf9/dhtml

Files:
M      WEB-INF/lps/lfc/views/LzInputText.lzs
M      WEB-INF/lps/lfc/views/LzText.lzs
M      WEB-INF/lps/lfc/views/LaszloView.lzs
M      WEB-INF/lps/lfc/views/LaszloCanvas.lzs
M      lps/components/debugger/debugger.lzx
M      lps/components/debugger/newcontent.lzx
M      lps/components/debugger/scrollingtext.lzx
M      lps/components/lz/form.lzx
M      lps/components/lz/gridcolumn.lzx
M      lps/components/lz/tabslider.lzx
M      lps/components/lz/modaldialog.lzx
M      lps/components/lz/tabelement.lzx
M      lps/components/lz/plainfloatinglist.lzx
M      lps/components/lz/floatinglist.lzx
M      lps/components/lz/window.lzx
M      lps/components/lz/list.lzx
M      lps/components/lz/windowpanel.lzx
M      lps/components/incubator/rich-text/formatfontcolor.lzx
M      lps/components/incubator/borderinput.lzx
M      lps/components/extensions/av/videoview.lzx
M      lps/components/base/basebutton.lzx
M      lps/components/base/swatchview.lzx
M      lps/components/base/baselistitem.lzx
M      lps/components/base/basewindow.lzx
M      lps/components/base/basecombobox.lzx
M      lps/components/base/basetabslider.lzx
M      lps/components/base/basetabs.lzx

Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20080902-Philip-4.tar


Modified: openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloCanvas.lzs
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloCanvas.lzs	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloCanvas.lzs	2008-09-04 23:17:51 UTC (rev 10877)
@@ -679,9 +679,9 @@
 /**
   * @access private
   */
-override function setWidth (v ){
+override function $lzc$set_width(v) {
     if ( $debug ){
-        Debug.error( "setWidth cannot be called on the canvas." );
+        Debug.error( "You cannot set the width on the canvas." );
     }
 }
 
@@ -695,27 +695,27 @@
 /**
   * @access private
   */
-override function setX ( v, force = null){
+override function $lzc$set_x(v) {
     if ( $debug ){
-        Debug.error( "setX cannot be called on the canvas." );
+        Debug.error( "You cannot set the X coordinate on the canvas." );
     }
 }
 
 /**
   * @access private
   */
-override function setHeight (v ){
+override function $lzc$set_height(v) {
     if ( $debug ){
-        Debug.error( "setHeight cannot be called on the canvas." );
+        Debug.error( "You cannot set the height on the canvas." );
     }
 }
 
 /**
   * @access private
   */
-override function setY ( v, force = null){
+override function $lzc$set_y(v) {
     if ( $debug ){
-        Debug.error( "setY cannot be called on the canvas." );
+        Debug.error( "You cannot set the Y coordinate on the canvas." );
     }
 }
 

Modified: openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/views/LaszloView.lzs	2008-09-04 23:17:51 UTC (rev 10877)
@@ -78,22 +78,16 @@
 /** @access private */
   static var earlySetters = new LzInheritedHash(LzNode.earlySetters);
     
+    /** true forces next call to setAttribute('x',...) to run
+        @access private */
+    var _xrecompute:Boolean = false;
+    /** true forces next call to setAttribute('y',...) to run
+        @access private */
+    var _yrecompute:Boolean = false;
     /** @access private */
-    var _height:Number;
-    /** @access private */
-    var _width:Number;
-    /** @access private */
-    var _y:Number;
-    /** @access private */
-    var _x:Number;
-    /** @access private */
     var __LZlayout
 
     /** @access private */
-    var fontname;
-    /** @access private */
-    var _visible;
-    /** @access private */
     var __LZstoredbounds;
 
     /** @access private */
@@ -109,7 +103,33 @@
     var playing = false;
     
 
+/** @access private */
+var _visible;
 
+/** @access private */
+function $lzc$set_visible( amVisible ) {
+    if (this._visible == amVisible) return;
+    this._visible = amVisible;
+
+    // make us compatible with the new 'visibility' attribute
+    if (amVisible) {
+        var v = "visible";
+    } else if (amVisible == null) {
+        if ($debug) {
+          Debug.info("%w.%s(%w) is deprecated.  Perhaps you meant %w.%s(%s)?  If not, use %w.%s('collapse').",
+                     this, arguments.callee, amVisible, this, arguments.callee, false, this, this.setVisibility);
+        }
+        var v = "collapse";
+    } else {
+        var v = "hidden";
+    }
+    this.visibility = v;
+
+    if (this.onvisibility.ready) this.onvisibility.sendEvent( this.visibility );
+    this.__LZupdateShown();
+}
+
+
 /** Event called when this view adds a subview   
   * @access public
   * @lzxtype event
@@ -573,20 +593,8 @@
 var clip = false;
 /** @access private */
 var $lzc$set_clip =  -1;
-/** @access private */
-function $lzc$set_x(v) { this.setX(v) }
-/** @access private */
-function $lzc$set_y(v) { this.setY(v) }
 
 
-/** @access private */
-function $lzc$set_rotation(v) { this.setRotation(v); }
-/** @access private */
-function $lzc$set_opacity(v) { this.setOpacity(v); }
-/** @access private */
-function $lzc$set_alpha(v) { this.setOpacity(v); }
-/** @access private */
-function $lzc$set_visibility(v) { this.setVisibility(v) }
 
 /**
   * @type String
@@ -595,8 +603,34 @@
   * @keywords final
   */
 var align = "left";
+
 /** @access private */
-function $lzc$set_align(v) { this.setAlign(v) }
+function $lzc$set_align(align) {
+  if (this.align == align) return;
+  function map (align) {
+    switch (align) {
+      case "center": return "__LZalignCenter";
+      case "right": return "__LZalignRight";
+      case "left": return null;
+      default:
+        if ($debug) {
+          Debug.error("%w.%s(%w): Invalid argument.  Valid choices are: 'left', 'center', or 'right'.",
+                      this, arguments.callee, align);
+        }
+    }
+  }
+  var from = map(this.align);
+  var to = map(align);
+  if (from != null) {
+    this.releaseConstraintMethod(from);
+  }
+  if (to != null) {
+    this.applyConstraintMethod(to, [this.immediateparent, "width", this, "width"]);
+  } else {
+    this.$lzc$set_x(0);
+  }
+  this.align = align;
+}
 
 /**
   * Creates a constraint on the view's y position which is a function
@@ -607,8 +641,34 @@
   * @lzxdefault "top"
   */
 var valign = "top";
+
 /** @access private */
-function $lzc$set_valign(v) { this.setValign(v) }
+function $lzc$set_valign(valign) {
+  if (this.valign == valign) return;
+  function map (align) {
+    switch (align) {
+      case "middle": return "__LZvalignMiddle";
+      case "bottom": return "__LZvalignBottom";
+      case "top": return null;
+      default:
+        if ($debug) {
+          Debug.error("%w.%s(%w): Invalid argument.  Valid choices are: 'top', 'middle', or 'bottom'.",
+                      this, arguments.callee, valign);
+        }
+    }
+  }
+  var from = map(this.valign);
+  var to = map(valign);
+  if (from != null) {
+    this.releaseConstraintMethod(from);
+  }
+  if (to != null) {
+    this.applyConstraintMethod(to, [this.immediateparent, "height", this, "height"]);
+  } else {
+    this.$lzc$set_y(0);
+  }
+  this.valign = valign;
+}
 
 /** The URL from which to load the resource for this
   * view.  If this attribute is set, the media for the view is loaded
@@ -626,20 +686,7 @@
   * @access private 
   */ 
 function $lzc$set_source(v) { this.setSource(v); }
-/** The background color of the canvas. 
-  * @lzxtype token
-  * @access private 
-  */
-function $lzc$set_bgcolor(v) { this.setBGColor(v) }
 
-/** If true, this view intercepts click events; otherwise they are passed
-  * to its container.  This defaults to true if the view defines a mouse
-  * event handler or a cursor.
-  * @type Boolean
-  * @lzxtype boolean
-  * @access private
-  */
-function $lzc$set_clickable(v) { this.setClickable(v); }
 /** Setting to a vector-based resource changes the clickable hotspot for the mouse.  Check capabilities.clickregion before using to avoid debugger warnings.
   * @access public
   * @type String
@@ -662,16 +709,20 @@
   * @lzxtype token
   */
 var cursor;  
-/** @access private */
-function $lzc$set_cursor(v) { this.setCursor(v); }
+
 /** A color to use to render object that appears inside this view,
   * which includes any vector or bitmap art in the view's resource
   * and any contained views.
   * @lzxtype color
   */
 var fgcolor;   
+
 /** @access private */
-function $lzc$set_fgcolor(v) { this.setColor(v); }
+function $lzc$set_fgcolor(c) {
+    this.sprite.setColor(c);
+    this.fgcolor = c;
+}
+
 /** The font to use for any <sgmltag class="element" role="LzText">&lt;text&gt;</sgmltag> or <sgmltag class="element" role="LzInputText">&lt;inputtext&gt;</sgmltag> elements that
   * appear inside this view. Like all the font properties
   * (<code>fontstyle</code> and <code>fontsize</code> too) these
@@ -683,9 +734,21 @@
   * @lzxtype string
   */
 var font;  
+
 /** @access private */
-function $lzc$set_font(v) { this.setFontName(v) ; }
+var fontname;
 
+/** @access private */
+function $lzc$set_font(val) {
+    this.font = val;
+    this.fontname = val ;
+    // Canvas has no sprite
+    if (! this.sprite) {
+      return;
+    }
+    this.sprite.setFontName(val, null);
+}
+
 /** The style to use to render text fields that appear inside of
   * this view. One of "plain", "bold" , "italic" or "bolditalic".
   * @type String
@@ -711,12 +774,37 @@
   * @lzxdefault "none"
   */
 var stretches = "none"; 
+
 /** @access private */
-function $lzc$set_play(v) { this.setPlay(v); }
-/** Show or hide the handcursor for this view, if clickable 
-  * @access private */
-function $lzc$set_showhandcursor(v) { this.setShowHandCursor(v); }
+function $lzc$set_stretches( stretch ){
+    if (!(stretch == "none" || stretch == "both" || stretch == "width" || stretch == "height")) {
+        //TODO: Remove null, x, y options from here when components are moved
+        var newstretch = (stretch == null ? "both" : stretch == "x" ? "width" : stretch == "y" ? "height" : "none");
+        if ($debug && newstretch != "none") {
+            Debug.info("%w.%s(%w) is deprecated.  Use %w.%s(%w) instead.",
+                this, arguments.callee, stretch, this, arguments.callee, newstretch);
+        }
+        stretch = newstretch;
+    } else if (this.stretches == stretch) {
+        return;
+    }
+    
+    this.stretches = stretch;
+    this.sprite.stretchResource(stretch);
+    
+    if (stretch == "width" || stretch == "both") {
+        this._setrescwidth = true;
+        this.__LZcheckwidth = true;
+        this.reevaluateSize( "width" );
+    }
 
+    if (stretch == "height" || stretch == "both") {
+        this._setrescheight = true;
+        this.__LZcheckheight = true;
+        this.reevaluateSize( "height" );
+    }
+}
+
 /** A CSS property when declared in the tag: value sequence of layout
   * parameters, which are used to create a layout that is attached to
   * this view. If there is a class property, it names the class of the
@@ -729,59 +817,132 @@
   * @access public
   */
 var layout; 
+
 /** @access private */
-function $lzc$set_layout(v) { this.setLayout(v); }
+function $lzc$set_layout(layoutobj) {
+    this.layout = layoutobj;
+    if (!this.isinited) {
+        this.__LZstoreAttr( layoutobj , "layout" );
+        return;
+    }
 
+
+    var classname = layoutobj['class'];
+    
+    if ( classname == null) {
+        classname = 'simplelayout';
+    }
+    
+    if ( this.__LZlayout ){
+        this.__LZlayout.destroy();
+    }
+    if (classname != 'none') {
+        var o = {};
+        for (var i in layoutobj) {
+           if (i != 'class')  {
+               o[i] = layoutobj[i];
+           }
+        }
+
+        if (classname == 'null') {
+            // FIXME [2006.09.25 bshine] (LPP-2759) This bogus check can be 
+            // removed when the underlying bug is fixed
+            // FIXME [2006.09.25 max] (LPP-2759) Actually, 
+            // laszlo-explorer/explore-nav.lzx counts on this failing 
+            // silently in the swf runtime - return here instead.
+            this.__LZlayout = null;
+            return;
+        }    
+        this.__LZlayout = new lz[ classname ] (this, o);
+   }
+}
+
 /** Activate/inactivate children for accessibility
   * @type Boolean
   * @lzxtype boolean
   */
 var aaactive; 
+
 /** @access private */
-function $lzc$set_aaactive(v) { this.setAAActive(v); }
+function $lzc$set_aaactive(s) {
+    if (this.capabilities.accessibility) {
+        this.aaactive = s;
+        this.sprite.setAAActive(s);
+    } else if ($debug) {
+        this.__warnCapability('view.setAAActive()'); 
+    }
+}
+
 /** Set accessibility name
   * @type String
   * @lzxtype string
   */
 var aaname;
+
 /** @access private */
-function $lzc$set_aaname(v) { this.setAAName(v); }
+function $lzc$set_aaname(s) {
+    if (this.capabilities.accessibility) {
+        this.aaname = s;
+        this.sprite.setAAName(s);
+    } else if ($debug) {
+        this.__warnCapability('view.setAAName()'); 
+    }
+}
+
 /** Set accessibility description
   * @type String
   * @lzxtype string
   */
 var aadescription; 
+
 /** @access private */
-function $lzc$set_aadescription(v) { this.setAADescription(v); }
+function $lzc$set_aadescription(s) {
+    if (this.capabilities.accessibility) {
+        this.aadescription = s;
+        this.sprite.setAADescription(s);
+    } else if ($debug) {
+        this.__warnCapability('view.setAADescription()'); 
+    }
+}
+
 /** Set accessibility tab order
   * @type Number
   * @lzxtype number
   */
 var aatabindex;   
+
 /** @access private */
-function $lzc$set_aatabindex(v) { this.setAATabIndex(v); }
+function $lzc$set_aatabindex(s) {
+    if (this.capabilities.accessibility) {
+        this.aatabindex = s;
+        this.sprite.setAATabIndex(s);
+    } else if ($debug) {
+        this.__warnCapability('view.setAATabIndex()'); 
+    }
+}
+
+
 /** Set accessibility silencing/unsilencing
   * @type Boolean
   * @lzxtype boolean
   */
 var aasilent; 
+
 /** @access private */
-function $lzc$set_aasilent(v) { this.setAASilent(v); }
+function $lzc$set_aasilent(s) {
+    if (this.capabilities.accessibility) {
+        this.aasilent = s;
+        this.sprite.setAASilent(s);
+    } else if ($debug) {
+        this.__warnCapability('view.setAASilent()'); 
+    }
+}
 
+
 LzView.__LZdelayedSetters.layout = "$lzc$set_layout";
 LzView.earlySetters.clickregion = 7;
 LzView.earlySetters.stretches = 8;
 
-/** 
-  * @type Number
-  * @access private 
-  */
-function $lzc$set_xoffset(v) { this.setXOffset(v); }
-/**
-  * @access private 
-  * @type Number
-  */
-function $lzc$set_yoffset(v) { this.setYOffset(v); }
 
 /** @access private */
 var sprite:LzSprite = null;
@@ -809,6 +970,20 @@
 var visibility = "collapse";
 
 /** @access private */
+function $lzc$set_visibility(amVisible) {
+    if (this.visibility == amVisible) return;
+    this.visibility = amVisible;
+    if ($debug) {
+        if (! (amVisible == "visible" || amVisible == "hidden" || amVisible == "collapse")) {
+          Debug.error("%w.%s called with unknown arg '%s' use 'visible', 'hidden', or 'collapse'.",
+                      this, arguments.callee, amVisible);
+        }
+    }
+    if (this.onvisibility.ready) this.onvisibility.sendEvent( amVisible );
+    this.__LZupdateShown();
+}
+
+/** @access private */
 var __LZvizO = true;
 
 /** @access private */
@@ -825,11 +1000,46 @@
   * @lzxdefault "1.0"
   */
 var opacity =   1;
+
+/** @access private */
+function $lzc$set_opacity(v) 
+{
+    if (this.capabilities.opacity) {
+        this.sprite.setOpacity(v);
+    } else if ($debug) {
+        this.__warnCapability('view.setOpacity()'); 
+    }
+    this.opacity = v;
+    if (this.onopacity.ready) this.onopacity.sendEvent( v );
+    var coviz = this.__LZvizO;
+    var newoviz = v != 0;
+    if ( coviz != newoviz ){
+        this.__LZvizO = newoviz;
+        this.__LZupdateShown();
+    }
+}
+
+/** @access private */
+function $lzc$set_alpha(v) { this.$lzc$set_opacity(v); }
+
 /** The color of background of this view. Null if there is
   * no bgcolor. A number from 0 - 0xFFFFFF.
   * @lzxtype color
   */
 var bgcolor =   null;
+
+/** The background color of the canvas. 
+  * @lzxtype token
+  * @access private 
+  */
+function $lzc$set_bgcolor(bgc) { 
+    bgc = lz.Utils.hextoint(bgc);
+    //trace('setting bgcolor ',bgc, this, this.sprite);
+    this.sprite.setBGColor(bgc);
+    if (bgc != null) this.bgcolor = bgc;
+    if (this.onbgcolor.ready) this.onbgcolor.sendEvent( bgc );
+}
+
 /** The horizontal offset of this view's upper left corner from the
   * upper left corner of its container.
   * @type Number
@@ -837,6 +1047,35 @@
   * @lzxdefault "0"
   */
 var x =   0;
+
+/** @access private */
+var _x:Number;
+
+/** @access private */
+function $lzc$set_x(v) {
+    if (this._xrecompute || this._x != v) {
+        this._x = v;
+        this.x = v;
+        if ( this.__LZhasoffset ){
+            if (this.capabilities.rotation) {
+                v -= ( this.xoffset * this.__LZrcos  -
+                    this.yoffset * this.__LZrsin );
+            } else {
+                v -= this.xoffset;
+            }
+        }
+        
+        if ( this.pixellock ) v = Math.floor( v );
+        this.sprite.setX(v)
+        
+        var vip:LzView = (this.immediateparent cast LzView);
+        if (vip.__LZcheckwidth)
+            vip.__LZcheckwidthFunction( this );
+        if (this.onx.ready) this.onx.sendEvent( this.x );
+        this._xrecompute = false;
+    }
+}
+
 /** The vertical offset of this view's upper left corner from the
   * upper left corner of its container
   * @type Number
@@ -844,6 +1083,34 @@
   * @lzxdefault "0"
   */
 var y =   0;
+
+/** @access private */
+var _y:Number;
+
+/** @access private */
+function $lzc$set_y(v) {
+    if (this._yrecompute || this._y != v) {
+        this._y = v;
+        this.y = v;
+        if ( this.__LZhasoffset ){
+            if (this.capabilities.rotation) {
+                v -= ( this.xoffset * this.__LZrsin  +
+                    this.yoffset * this.__LZrcos );
+            } else {
+                v -= this.yoffset;
+            }
+        }
+        
+        if ( this.pixellock ) v = Math.floor( v );
+        this.sprite.setY(v)
+        var vip:LzView = (this.immediateparent cast LzView);
+        if (vip.__LZcheckheight)
+            vip.__LZcheckheightFunction( this );
+        if (this.ony.ready) this.ony.sendEvent( this.y );
+        this._yrecompute = false;
+    }
+}
+
 /** The rotation value for the view (in degrees).
   * Value may be less than zero or greater than 360.
   * @type Number
@@ -852,6 +1119,33 @@
   */
 var rotation =   0;
 
+/** @access private */
+function $lzc$set_rotation(v) {
+    if (this.capabilities.rotation) {
+        this.sprite.setRotation(v)
+    } else if ($debug) {
+        this.__warnCapability('view.setRotation()'); 
+    }
+    this.rotation = v;
+    var rrad = Math.PI /180 * this.rotation;
+    this.__LZrsin = Math.sin( rrad )
+    this.__LZrcos = Math.cos( rrad )
+    if (this.onrotation.ready) this.onrotation.sendEvent( v );
+
+    if ( this.__LZhasoffset ){
+        this._xrecompute = true;
+        this._yrecompute = true;
+        $lzc$set_x(this.x);
+        $lzc$set_y(this.y);
+    }
+
+    var vip:LzView = (this.immediateparent cast LzView);
+    if (vip.__LZcheckwidth)
+        vip.__LZcheckwidthFunction( this );
+    if (vip.__LZcheckheight)
+        vip.__LZcheckheightFunction( this );
+}
+
 /**
   * The width of the view
   * @access public
@@ -859,9 +1153,53 @@
   * @lzxtype sizeExpression
   */
 var width =   0;
+
 /** @access private */
-function $lzc$set_width(v) { this.setWidth(v); }
+var _width:Number;
 
+/** @access private */
+function $lzc$set_width(v) {
+    if (this._width != v) {
+        this._width = v;
+        this.sprite.setWidth(v);
+
+        if ( v == null ){
+            this.hassetwidth = false;
+            // expose proto method
+            this.__LZcheckwidth = true;
+            if ( this._setrescwidth ){
+                // will be updated by reevaluateSize
+                this.unstretchedwidth = null;
+                // defaults
+                this._xscale = 1;
+                //this.__LZmovieClipRef._xscale =  100;
+            }
+            this.reevaluateSize( 'width' );
+            return;
+        }
+        this.width = v;
+        if ( this.pixellock ) v = Math.floor( v );
+        if ( this._setrescwidth ){
+        var xscale = this.unstretchedwidth == 0 ? 100 : v/this.unstretchedwidth;
+        this._xscale = xscale;
+        //this.__LZmovieClipRef._xscale = xscale * 100;
+        } else {
+            this.__LZcheckwidth = false;
+        }
+        
+        this.hassetwidth = true;
+        
+        //this.__LZbgRef._xscale = v;
+
+        var vip:LzView = (this.immediateparent cast LzView);
+        if (vip && vip.__LZcheckwidth)
+            vip.__LZcheckwidthFunction( this );
+
+
+        if (this.onwidth.ready) this.onwidth.sendEvent( v );
+    }
+}
+
 /**
   * The height of the view
   * @access public
@@ -869,9 +1207,51 @@
   * @lzxtype sizeExpression
   */
 var height =   0;
+
 /** @access private */
-function $lzc$set_height(v) { this.setHeight(v); }
+var _height:Number;
 
+/** @access private */
+function $lzc$set_height(v) {
+    if (this._height != v) {
+        this._height = v;
+        this.sprite.setHeight(v);
+
+        if ( v == null ){
+            this.hassetheight = false;
+            // expose proto method
+            this.__LZcheckheight = true;
+
+            if ( this._setrescheight ){
+                // will be updated by reevaluateSize
+                this.unstretchedheight = null;
+                // defaults
+                this._yscale = 1;
+                //this.__LZmovieClipRef._yscale =  100;
+            }
+            this.reevaluateSize( 'height' );
+            return;
+        }
+        this.height = v;
+        if ( this.pixellock ) v = Math.floor( v );
+        if ( this._setrescheight ){
+            var yscale = this.unstretchedheight == 0 ? 100 : v/this.unstretchedheight;
+            this._yscale = yscale;
+            //this.__LZmovieClipRef._yscale = yscale * 100;
+        } else {
+            this.__LZcheckheight = false;
+        }
+        this.hassetheight = true;
+        
+        var vip:LzView = (this.immediateparent cast LzView);
+        if (vip && vip.__LZcheckheight)
+            vip.__LZcheckheightFunction( this );
+
+
+        if (this.onheight.ready) this.onheight.sendEvent( v );
+    }
+}
+
 /** If stretches is not set to none, the width
   * that this view would be if it weren't stretched. This attribute can be used
   * to scale a view by a percentage of its original size, or to determine the
@@ -906,6 +1286,21 @@
   * @lzxdefault "0"
   */
 var xoffset =   0;
+
+/** 
+  * @type Number
+  * @access private 
+  */
+function $lzc$set_xoffset(o) {
+    this.__LZhasoffset = o != 0;
+    this.xoffset = o;
+    this._xrecompute = true;
+    this._yrecompute = true;
+    this.$lzc$set_x(this.x);
+    this.$lzc$set_y(this.y);
+    if (this.onxoffset.ready) this.onxoffset.sendEvent( o );
+}
+
 /**
   * Specifies a translation point for drawing of this view. If the yoffset
   * is set, then rotation and y position will be calculated by first adding
@@ -915,6 +1310,21 @@
   * @lzxdefault "0"
   */
 var yoffset =   0;
+
+/**
+  * @access private 
+  * @type Number
+  */
+function $lzc$set_yoffset(o) {
+    this.__LZhasoffset = o != 0;
+    this.yoffset = o;
+    this._xrecompute = true;
+    this._yrecompute = true;
+    this.$lzc$set_x(this.x);
+    this.$lzc$set_y(this.y);
+    if (this.onyoffset.ready) this.onyoffset.sendEvent( o );
+}
+
 /** @access private */
 var __LZrsin = 0;
 /** @access private */
@@ -947,9 +1357,17 @@
   * @lzxdefault "1"
   */
 var frame = 1;
+
 /** @access private */
-function $lzc$set_frame(v) { this.setResourceNumber(v); }
+function $lzc$set_frame(n) {
+    //Debug.write('$lzc$set_frame', n, this, this.playing)
 
+    // prevent play status tracking from running if the frame was set oninit, like in windowframe class
+    this.frame = n;
+    this.stop( n );
+    if (this.onframe.ready) this.onframe.sendEvent(n);
+}
+
 /** For views whose resource is loaded at runtime,
   * the ratio of the loaded frames to the total frames. This is a number between
   * zero and 1.
@@ -1017,11 +1435,33 @@
   */ 
 var clickable = false;
 
+/** If true, this view intercepts click events; otherwise they are passed
+  * to its container.  This defaults to true if the view defines a mouse
+  * event handler or a cursor.
+  * @type Boolean
+  * @lzxtype boolean
+  * @access private
+  */
+function $lzc$set_clickable(amclickable) {
+    this.sprite.setClickable(amclickable);
+    this.clickable = amclickable;
+    if (this.onclickable.ready) this.onclickable.sendEvent( amclickable );
+}
+
+
 /** Show or hide the hand cursor for this view, if clickable
   * @type Boolean
   * @lzxtype boolean
   */
 var showhandcursor = null;
+
+/** Show or hide the handcursor for this view, if clickable 
+  * @access private */
+function $lzc$set_showhandcursor(s) {
+    this.showhandcursor = s;
+    this.sprite.setShowHandCursor(s);
+}
+
 /** @access private */
 var updatePlayDel = null;
 /**
@@ -1036,6 +1476,13 @@
   */
 var resource:String = null;
 
+/** @access private */
+function $lzc$set_resource( resourceName ) {
+    if (resourceName == null || resourceName == this._resource) return;
+    this.resource = this._resource = resourceName;
+    this.sprite.setResource(resourceName);
+}
+
 /**
   * The width of the resource that this view attached
   * @keywords readonly
@@ -1064,6 +1511,8 @@
 /** @access private */ var __LZoutliewidth = null;
 /** @access private */ var __LZsubUniqueNum = null;
 
+
+
 /**
   * this creates a specific child layout for this view. When called a second time
   * the first layout will be replaced by the second.
@@ -1078,43 +1527,10 @@
   * @deprecated Use setAttribute('layout', ...) instead.
   */
 function setLayout ( layoutobj ){
-    this.layout = layoutobj;
-    if (!this.isinited) {
-        this.__LZstoreAttr( layoutobj , "layout" );
-        return;
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_layout(layoutobj);    
+}
 
-
-    var classname = layoutobj['class'];
-    
-    if ( classname == null) {
-        classname = 'simplelayout';
-    }
-    
-    if ( this.__LZlayout ){
-        this.__LZlayout.destroy();
-    }
-    if (classname != 'none') {
-        var o = {};
-        for (var i in layoutobj) {
-           if (i != 'class')  {
-               o[i] = layoutobj[i];
-           }
-        }
-
-        if (classname == 'null') {
-            // FIXME [2006.09.25 bshine] (LPP-2759) This bogus check can be 
-            // removed when the underlying bug is fixed
-            // FIXME [2006.09.25 max] (LPP-2759) Actually, 
-            // laszlo-explorer/explore-nav.lzx counts on this failing 
-            // silently in the swf runtime - return here instead.
-            this.__LZlayout = null;
-            return;
-        }    
-        this.__LZlayout = new lz[ classname ] (this, o);
-   }
- }
-
 /**
   * Sets the font name for this view. The font information (font, fontsize, and
   * fontstyle) will cascade down the runtime view hierarchy.
@@ -1123,13 +1539,8 @@
   * @deprecated Use setAttribute('font', ...) instead.
   */
 function setFontName ( val ,prop = null){
-    this.font = val;
-    this.fontname = val ;
-    // Canvas has no sprite
-    if (! this.sprite) {
-      return;
-    }
-    this.sprite.setFontName(val, prop);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_font(val);    
 }
 
 /** If true, the view does not set its
@@ -1220,12 +1631,6 @@
     this.$lzc$set_resource(v);    
 }
 
-/** @access private */
-function $lzc$set_resource( resourceName ) {
-    if (resourceName == null || resourceName == this._resource) return;
-    this.resource = this._resource = resourceName;
-    this.sprite.setResource(resourceName);
-}
 
 /**
   * @access private
@@ -1384,29 +1789,8 @@
     this.$lzc$set_visible(v)
 }
 
-/** @access private */
-function $lzc$set_visible( amVisible ) {
-    if (this._visible == amVisible) return;
-    this._visible = amVisible;
 
-    // make us compatible with the new 'visibility' attribute
-    if (amVisible) {
-        var v = "visible";
-    } else if (amVisible == null) {
-        if ($debug) {
-          Debug.info("%w.%s(%w) is deprecated.  Perhaps you meant %w.%s(%s)?  If not, use %w.%s('collapse').",
-                     this, arguments.callee, amVisible, this, arguments.callee, false, this, this.setVisibility);
-        }
-        var v = "collapse";
-    } else {
-        var v = "hidden";
-    }
-    this.visibility = v;
 
-    if (this.onvisibility.ready) this.onvisibility.sendEvent( this.visibility );
-    this.__LZupdateShown();
-}
-
 /**
   * This method sets the <attribute>visibility</attribute> attribute of the view
   * and also disables or re-enables any click region associated with the view.
@@ -1421,16 +1805,8 @@
   * @deprecated Use setAttribute('visibility', ...) instead.
   */
 function setVisibility( amVisible ) {
-    if (this.visibility == amVisible) return;
-    this.visibility = amVisible;
-    if ($debug) {
-        if (! (amVisible == "visible" || amVisible == "hidden" || amVisible == "collapse")) {
-          Debug.error("%w.%s called with unknown arg '%s' use 'visible', 'hidden', or 'collapse'.",
-                      this, arguments.callee, amVisible);
-        }
-    }
-    if (this.onvisibility.ready) this.onvisibility.sendEvent( amVisible );
-    this.__LZupdateShown();
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_visibility(amVisible);
 }
     
 /**
@@ -1471,47 +1847,13 @@
   * @deprecated Use setAttribute('width', ...) instead.
   */
 function setWidth ( v ){
-    if (this._width != v) {
-        this._width = v;
-        this.sprite.setWidth(v);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_width(v);
+}
 
-        if ( v == null ){
-            this.hassetwidth = false;
-            // expose proto method
-            this.__LZcheckwidth = true;
-            if ( this._setrescwidth ){
-                // will be updated by reevaluateSize
-                this.unstretchedwidth = null;
-                // defaults
-                this._xscale = 1;
-                //this.__LZmovieClipRef._xscale =  100;
-            }
-            this.reevaluateSize( 'width' );
-            return;
-        }
-        this.width = v;
-        if ( this.pixellock ) v = Math.floor( v );
-        if ( this._setrescwidth ){
-        var xscale = this.unstretchedwidth == 0 ? 100 : v/this.unstretchedwidth;
-        this._xscale = xscale;
-        //this.__LZmovieClipRef._xscale = xscale * 100;
-        } else {
-            this.__LZcheckwidth = false;
-        }
-        
-        this.hassetwidth = true;
-        
-        //this.__LZbgRef._xscale = v;
 
-        var vip:LzView = (this.immediateparent cast LzView);
-        if (vip && vip.__LZcheckwidth)
-            vip.__LZcheckwidthFunction( this );
 
 
-        if (this.onwidth.ready) this.onwidth.sendEvent( v );
-    }
-}
-
     /**
     * Sets the height of the view the given value. If the view is set to stretch
     * its resource, the resource will be resized to the new value. If the value
@@ -1521,46 +1863,12 @@
   * @deprecated Use setAttribute('height', ...) instead.
   */
 function setHeight ( v ){
-    if (this._height != v) {
-        this._height = v;
-        this.sprite.setHeight(v);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_height(v);
+}
 
-        if ( v == null ){
-            this.hassetheight = false;
-            // expose proto method
-            this.__LZcheckheight = true;
 
-            if ( this._setrescheight ){
-                // will be updated by reevaluateSize
-                this.unstretchedheight = null;
-                // defaults
-                this._yscale = 1;
-                //this.__LZmovieClipRef._yscale =  100;
-            }
-            this.reevaluateSize( 'height' );
-            return;
-        }
-        this.height = v;
-        if ( this.pixellock ) v = Math.floor( v );
-        if ( this._setrescheight ){
-            var yscale = this.unstretchedheight == 0 ? 100 : v/this.unstretchedheight;
-            this._yscale = yscale;
-            //this.__LZmovieClipRef._yscale = yscale * 100;
-        } else {
-            this.__LZcheckheight = false;
-        }
-        this.hassetheight = true;
-        
-        var vip:LzView = (this.immediateparent cast LzView);
-        if (vip && vip.__LZcheckheight)
-            vip.__LZcheckheightFunction( this );
 
-
-        if (this.onheight.ready) this.onheight.sendEvent( v );
-    }
-}
-
-
 /**
   * Sets the opacity for the view.  The opacity is a number between 0.0
   * (transparent) and 1.0 (opaque).
@@ -1568,75 +1876,31 @@
   * @deprecated Use setAttribute('opacity', ...) instead.
   */
 function setOpacity ( v ){
-    if (this.capabilities.opacity) {
-        this.sprite.setOpacity(v);
-    } else if ($debug) {
-        this.__warnCapability('view.setOpacity()'); 
-    }
-    this.opacity = v;
-    if (this.onopacity.ready) this.onopacity.sendEvent( v );
-    var coviz = this.__LZvizO;
-    var newoviz = v != 0;
-    if ( coviz != newoviz ){
-        this.__LZvizO = newoviz;
-        this.__LZupdateShown();
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_opacity(v);
 }
 
 
 
+
 /**
   * Sets the <attribute>x</attribute> position of the view to the given value.
   * @param Number v: The new value for <attribute>x</attribute>.
+  * @deprecated Use setAttribute('x', ...) instead.
   */
-function setX ( v, force = null){
-    if (force || this._x != v) {
-        this._x = v;
-        this.x = v;
-        if ( this.__LZhasoffset ){
-            if (this.capabilities.rotation) {
-                v -= ( this.xoffset * this.__LZrcos  -
-                    this.yoffset * this.__LZrsin );
-            } else {
-                v -= this.xoffset;
-            }
-        }
-        
-        if ( this.pixellock ) v = Math.floor( v );
-        this.sprite.setX(v)
-        
-        var vip:LzView = (this.immediateparent cast LzView);
-        if (vip.__LZcheckwidth)
-            vip.__LZcheckwidthFunction( this );
-        if (this.onx.ready) this.onx.sendEvent( this.x );
-    }
+function setX (v){
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_x(v);
 }
 
-
 /**
   * Sets the <attribute>y</attribute> position for the view to the given value.
   * @param Number v: The new value for <attribute>y</attribute>.
+  * @deprecated Use setAttribute('y', ...) instead.
   */
-function setY ( v, force = null){
-    if (force || this._y != v) {
-        this._y = v;
-        this.y = v;
-        if ( this.__LZhasoffset ){
-            if (this.capabilities.rotation) {
-                v -= ( this.xoffset * this.__LZrsin  +
-                    this.yoffset * this.__LZrcos );
-            } else {
-                v -= this.yoffset;
-            }
-        }
-        
-        if ( this.pixellock ) v = Math.floor( v );
-        this.sprite.setY(v)
-        var vip:LzView = (this.immediateparent cast LzView);
-        if (vip.__LZcheckheight)
-            vip.__LZcheckheightFunction( this );
-        if (this.ony.ready) this.ony.sendEvent( this.y );
-    }
+function setY (v) {
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_y(v);
 }
 
 
@@ -1646,29 +1910,11 @@
   * @deprecated Use setAttribute('rotation', ...) instead.
   */
 function setRotation ( v ){
-    if (this.capabilities.rotation) {
-        this.sprite.setRotation(v)
-    } else if ($debug) {
-        this.__warnCapability('view.setRotation()'); 
-    }
-    this.rotation = v;
-    var rrad = Math.PI /180 * this.rotation;
-    this.__LZrsin = Math.sin( rrad )
-    this.__LZrcos = Math.cos( rrad )
-    if (this.onrotation.ready) this.onrotation.sendEvent( v );
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_rotation(v);
+}
 
-    if ( this.__LZhasoffset ){
-        this.setX( this.x, true );
-        this.setY( this.y, true );
-    }
 
-    var vip:LzView = (this.immediateparent cast LzView);
-    if (vip.__LZcheckwidth)
-        vip.__LZcheckwidthFunction( this );
-    if (vip.__LZcheckheight)
-        vip.__LZcheckheightFunction( this );
-}
-
 /**
   * Sets the <attribute>alignment</attribute> for the view to the
   * given value. The alignment is based on the size of this view as
@@ -1682,44 +1928,20 @@
   * 'onalign', should we?
   */
 function setAlign ( align ){
-  if (this.align == align) return;
-  function map (align) {
-    switch (align) {
-      case "center": return "__LZalignCenter";
-      case "right": return "__LZalignRight";
-      case "left": return null;
-      default:
-        if ($debug) {
-          Debug.error("%w.%s(%w): Invalid argument.  Valid choices are: 'left', 'center', or 'right'.",
-                      this, arguments.callee, align);
-        }
-    }
-  }
-  var from = map(this.align);
-  var to = map(align);
-  if (from != null) {
-    this.releaseConstraintMethod(from);
-  }
-  if (to != null) {
-    this.applyConstraintMethod(to, [this.immediateparent, "width", this, "width"]);
-  } else {
-    this.setAttribute('x', 0);
-  }
-  this.align = align;
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_align(align);
 }
 
 /** @access private */
 function __LZalignCenter (e=null) {
   var vip:LzView = (this.immediateparent cast LzView);
-  this.setAttribute( "x" , vip.width /2
-                     - this.width /2);
+  this.$lzc$set_x(vip.width /2 - this.width /2);
 }
 
 /** @access private */
 function __LZalignRight (e=null) {
   var vip:LzView = (this.immediateparent cast LzView);
-  this.setAttribute( "x" , vip.width
-                     - this.width);
+  this.$lzc$set_x(vip.width - this.width);
 }
 
 
@@ -1729,11 +1951,8 @@
   * @deprecated Use setAttribute('xoffset', ...) instead.
   */
 function setXOffset ( o ){
-    this.__LZhasoffset = o != 0;
-    this.xoffset = o;
-    this.setX( this.x, true );
-    this.setY( this.y, true );
-    if (this.onxoffset.ready) this.onxoffset.sendEvent( o );
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_xoffset(o);
 }
 
 /**
@@ -1742,11 +1961,8 @@
   * @deprecated Use setAttribute('yoffset', ...) instead.
   */
 function setYOffset ( o ){
-    this.__LZhasoffset = o != 0;
-    this.yoffset = o;
-    this.setX( this.x, true );
-    this.setY( this.y, true );
-    if (this.onyoffset.ready) this.onyoffset.sendEvent( o );
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_yoffset(o);
 }
 
 
@@ -1824,6 +2040,8 @@
     return [ self, 'rotation' , self, 'x' , self , 'y' , self , 'width' ,
              self , 'height' ];
 }
+
+
 /**
   * Sets the vertical alignment for the view to the given value. The
   * alignment is based on the height of this view as compared to the
@@ -1837,44 +2055,20 @@
   * 'onvalign', should we?
   */
 function setValign ( valign ){
-  if (this.valign == valign) return;
-  function map (align) {
-    switch (align) {
-      case "middle": return "__LZvalignMiddle";
-      case "bottom": return "__LZvalignBottom";
-      case "top": return null;
-      default:
-        if ($debug) {
-          Debug.error("%w.%s(%w): Invalid argument.  Valid choices are: 'top', 'middle', or 'bottom'.",
-                      this, arguments.callee, valign);
-        }
-    }
-  }
-  var from = map(this.valign);
-  var to = map(valign);
-  if (from != null) {
-    this.releaseConstraintMethod(from);
-  }
-  if (to != null) {
-    this.applyConstraintMethod(to, [this.immediateparent, "height", this, "height"]);
-  } else {
-    this.setAttribute('y', 0);
-  }
-  this.valign = valign;
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_valign(valign);
 }
 
 /** @access private */
 function __LZvalignMiddle (e=null) {
   var vip:LzView = (this.immediateparent cast LzView);
-  this.setAttribute( "y" , vip.height /2
-                     - this.height /2);
+  this.$lzc$set_y(vip.height /2 - this.height /2);
 }
 
 /** @access private */
 function __LZvalignBottom (e=null) {
   var vip:LzView = (this.immediateparent cast LzView);
-  this.setAttribute( "y" , vip.height
-                     - this.height);
+  this.$lzc$set_y(vip.height - this.height);
 }
 
 /**
@@ -1886,11 +2080,10 @@
   * @deprecated Use setAttribute('fgcolor', ...) instead.
   */
 function setColor ( c ){
-    this.sprite.setColor(c);
-    this.fgcolor = c;
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_fgcolor(c);
 }
 
-
 /**
   * Gets the color of the view (the view's resource and any subviews) view as
   * as set with setColor().
@@ -1950,6 +2143,7 @@
     }
 }
 
+
 /**
  * @devnote measureSize must agree with this
  *
@@ -2483,12 +2677,8 @@
   * @deprecated Use setAttribute('frame', ...) instead.
   */
 function setResourceNumber( n ) {
-    //Debug.write('setResourceNumber', n, this, this.playing)
-
-    // prevent play status tracking from running if the frame was set oninit, like in windowframe class
-    this.frame = n;
-    this.stop( n );
-    if (this.onframe.ready) this.onframe.sendEvent(n);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_frame(n); 
 }
 
 /**
@@ -2506,47 +2696,15 @@
     this.$lzc$set_stretches(v); 
 }
 
-/** @access private */
-function $lzc$set_stretches( stretch ){
-    if (!(stretch == "none" || stretch == "both" || stretch == "width" || stretch == "height")) {
-        //TODO: Remove null, x, y options from here when components are moved
-        var newstretch = (stretch == null ? "both" : stretch == "x" ? "width" : stretch == "y" ? "height" : "none");
-        if ($debug && newstretch != "none") {
-            Debug.info("%w.%s(%w) is deprecated.  Use %w.%s(%w) instead.",
-                this, arguments.callee, stretch, this, arguments.callee, newstretch);
-        }
-        stretch = newstretch;
-    } else if (this.stretches == stretch) {
-        return;
-    }
-    
-    this.stretches = stretch;
-    this.sprite.stretchResource(stretch);
-    
-    if (stretch == "width" || stretch == "both") {
-        this._setrescwidth = true;
-        this.__LZcheckwidth = true;
-        this.reevaluateSize( "width" );
-    }
 
-    if (stretch == "height" || stretch == "both") {
-        this._setrescheight = true;
-        this.__LZcheckheight = true;
-        this.reevaluateSize( "height" );
-    }
-}
-
 /**
   * Gives the view a bgcolor that is the same size as the view.
   * @param Integer bgc: The 0-FFFFFF number to be used for the new background color.
   * @deprecated Use setAttribute('bgcolor', ...) instead.
   */
 function setBGColor ( bgc ) {
-    bgc = lz.Utils.hextoint(bgc);
-    //trace('setting bgcolor ',bgc, this, this.sprite);
-    this.sprite.setBGColor(bgc);
-    if (bgc != null) this.bgcolor = bgc;
-    if (this.onbgcolor.ready) this.onbgcolor.sendEvent( bgc );
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_bgcolor(bgc);
 }
 
 /**
@@ -2600,13 +2758,16 @@
   * @deprecated Use setAttribute('clickable', ...) instead.
   */
 function setClickable ( amclickable ){
-    this.sprite.setClickable(amclickable);
-    this.clickable = amclickable;
-    if (this.onclickable.ready) this.onclickable.sendEvent( amclickable );
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_clickable(amclickable);
+}
 
+
+/** @access private */
+function $lzc$set_cursor(cursor) {
+    this.sprite.setCursor(cursor);
 }
 
-
 /**
   * Sets the cursor to the given resource when the mouse is over this view
   * @param String cursor: The name of the resource to use as a cursor when it is over
@@ -2614,21 +2775,28 @@
   * @deprecated Use setAttribute('cursor', ...) instead.
   */
 function setCursor ( cursor = null){
-    this.sprite.setCursor(cursor);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_cursor(cursor);
 }
 
 
+/** @access private */
+function $lzc$set_play(b) {
+    if ( b ) {
+        this.play();
+    } else {
+        this.stop();
+    }
+}
+
 /**
   * Start or stop playing the attached resource.
   * @param Boolean b: If true, starts playing, otherwise stops
   * @deprecated Use setAttribute('play', ...) instead.
   */
 function setPlay (b){
-    if ( b ) {
-        this.play();
-    } else {
-        this.stop();
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_play(b);
 }
 
 /**
@@ -2792,6 +2960,7 @@
     }
 }
 
+
 /**
   * Shows or hides the hand cursor for this view.
   * @param Boolean s: true shows the hand cursor for this view, false hides 
@@ -2799,8 +2968,8 @@
   * @deprecated Use setAttribute('showhandcursor', ...) instead.
   */
 function setShowHandCursor ( s ){
-    this.showhandcursor = s;
-    this.sprite.setShowHandCursor(s);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_showhandcursor(s);
 }
 
 /**
@@ -2820,12 +2989,8 @@
   * @deprecated Use setAttribute('aaactive', ...) instead.
   */
 function setAAActive ( s ){
-    if (this.capabilities.accessibility) {
-        this.aaactive = s;
-        this.sprite.setAAActive(s);
-    } else if ($debug) {
-        this.__warnCapability('view.setAAActive()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_aaactive(s);
 }
 
 
@@ -2835,26 +3000,19 @@
   * @deprecated Use setAttribute('aaname', ...) instead.
   */
 function setAAName ( s ){
-    if (this.capabilities.accessibility) {
-        this.aaname = s;
-        this.sprite.setAAName(s);
-    } else if ($debug) {
-        this.__warnCapability('view.setAAName()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_aaname(s);
 }
 
+
 /**
   * Set accessibility description
   * @param string s: Sets the accessibility description for this view
   * @deprecated Use setAttribute('aadescription', ...) instead.
   */
 function setAADescription ( s ){
-    if (this.capabilities.accessibility) {
-        this.aadescription = s;
-        this.sprite.setAADescription(s);
-    } else if ($debug) {
-        this.__warnCapability('view.setAADescription()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_aadescription(s);
 }
 
 /**
@@ -2863,12 +3021,8 @@
   * @deprecated Use setAttribute('aatabindex', ...) instead.
   */
 function setAATabIndex ( s ){
-    if (this.capabilities.accessibility) {
-        this.aatabindex = s;
-        this.sprite.setAATabIndex(s);
-    } else if ($debug) {
-        this.__warnCapability('view.setAATabIndex()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_aatabindex(s);
 }
 
 /**
@@ -2878,12 +3032,8 @@
   * @deprecated Use setAttribute('aasilent', ...) instead.
   */
 function setAASilent ( s ){
-    if (this.capabilities.accessibility) {
-        this.aasilent = s;
-        this.sprite.setAASilent(s);
-    } else if ($debug) {
-        this.__warnCapability('view.setAASilent()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_aasilent(s);
 }
 
 /**
@@ -2995,13 +3145,10 @@
   * @deprecated Use setAttribute('proxyurl', ...) instead.
   */
 function setProxyURL ( f ){
-    this.proxyurl = f;
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_proxyurl(f);
 }
 
-/** @access private */ 
-function $lzc$set_proxyurl( f ){
-    this.setProxyURL(f);
-}
 
 
 /** The url of the proxy server, if the app is running in proxied mode.
@@ -3025,6 +3172,12 @@
     return canvas.getProxyURL(url);
 };
 
+/** @access private */ 
+function $lzc$set_proxyurl( f ){
+    this.proxyurl = f;
+}
+
+
 /**
   * Install menu items for the right-mouse-button 
   * @param LzContextMenu cmenu: LzContextMenu to install on this view
@@ -3080,6 +3233,7 @@
         }
     }
 }
+
 } // End of LzView
 
 lz[LzView.tagname] = LzView;  //publish

Modified: openlaszlo/trunk/WEB-INF/lps/lfc/views/LzInputText.lzs
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/views/LzInputText.lzs	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/views/LzInputText.lzs	2008-09-04 23:17:51 UTC (rev 10877)
@@ -216,24 +216,29 @@
   */
     public var enabled = true;
 
-
 /**
-  * Sets whether user can modify input text field
-  * @param Boolean enabled: true if the text field can be edited
-  * @deprecated Use setAttribute('enabled', ...) instead.
+  * @access private
   */
-function setEnabled (enabled){
-    this.setAttribute('focusable', enabled);
+function $lzc$set_enabled(enabled) {
+    this.focusable = true;
     this.enabled = enabled;
     var isprite:LzInputTextSprite = (this.sprite cast LzInputTextSprite);    
     isprite.setEnabled(enabled);
     if (this.onenabled.ready) this.onenabled.sendEvent(enabled);
 }
 
+
+
+
 /**
-  * @access private
+  * Sets whether user can modify input text field
+  * @param Boolean enabled: true if the text field can be edited
+  * @deprecated Use setAttribute('enabled', ...) instead.
   */
-function $lzc$set_enabled(v) { this.setEnabled(v); }
+function setEnabled (enabled){
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_enabled(enabled);
+}
 
 /**
   * Set the html flag on this text view

Modified: openlaszlo/trunk/WEB-INF/lps/lfc/views/LzText.lzs
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/views/LzText.lzs	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/views/LzText.lzs	2008-09-04 23:17:51 UTC (rev 10877)
@@ -110,24 +110,88 @@
   * @keywords read-only
   */
     var selectable = false;
+
+function $lzc$set_selectable(isSel) {
+    this.selectable = isSel;
+    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+    tsprite.setSelectable(isSel);
+}
+
+
 // these 4 are only available in swf8 and higher
 /** @access private */
     var antiAliasType = "advanced";
+
 /** @access private */
-    function $lzc$set_antiAliasType(v) { this.setAntiAliasType(v) }
+function $lzc$set_antiAliasType(aliasType) {
+    if (this.capabilities.advancedfonts) {    
+        if ((aliasType == "normal") || (aliasType == "advanced")) {
+            this.antiAliasType = aliasType; 
+            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+            tsprite.setAntiAliasType(aliasType);
+        } else if ($debug) {
+            Debug.warn("antiAliasType invalid, must be 'normal' or 'advanced', but you said '" + aliasType + "'");
+        }        
+    } else if ($debug) {
+        this.__warnCapability('text.setAntiAliasType()'); 
+    }
+}
+
 /** @access private */
     var gridFit = "subpixel";
+
 /** @access private */
-    function $lzc$set_gridFit(v) { this.setGridFit(v) }
+function $lzc$set_gridFit(gridFit) {
+    if (this.capabilities.advancedfonts) {    
+        if ((gridFit == "none") || (gridFit == "pixel") || (gridFit == "subpixel")) {
+            this.gridFit = gridFit; 
+            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+            tsprite.setGridFit(gridFit);
+        } else if ($debug) {
+            Debug.warn("gridFit invalid, must be 'none', 'pixel', or 'subpixel' but you said '" + gridFit + "'");
+        }
+    } else if ($debug) {
+        this.__warnCapability('text.setGridFit()'); 
+    }
+}
+
 /** @access private */
     var sharpness = 0;
+
 /** @access private */
-    function $lzc$set_sharpness(v) { this.setSharpness(v) }
+function $lzc$set_sharpness(sharpness) {
+    if (this.capabilities.advancedfonts) {
+        if  ((sharpness >= -400) && (sharpness <= 400)) {
+            this.sharpness = sharpness; 
+            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+            tsprite.setSharpness(sharpness);
+        } else if ($debug) {
+            Debug.warn("sharpness out of range, must be -400 to 400");
+        }        
+    } else if ($debug) {
+        this.__warnCapability('text.setSharpness()'); 
+    }
+}
+
 /** @access private */
     var thickness = 0;
+
 /** @access private */
-    function $lzc$set_thickness(v) { this.setThickness(v) }
+function $lzc$set_thickness(thickness) {
+    if (this.capabilities.advancedfonts) {
+        if  ((thickness >= -200) && (thickness <= 200)) {
+            this.thickness = thickness;
+            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+            tsprite.setThickness(thickness); 
+        } else if ($debug) {
+            Debug.warn("thickness out of range, must be -200 to 200");
+        }
+    } else if ($debug) {
+        this.__warnCapability('text.setThickness()'); 
+    }
+}
 
+
 /** @access private */
     function LzText ( parent:LzNode? = null , attrs:Object? = null , children:Array? = null, instcall:Boolean  = false) {
         super(parent,attrs,children,instcall);
@@ -146,6 +210,16 @@
     var yscroll;
 
 /**
+  * @access private
+  */
+function $lzc$set_yscroll(n) {
+    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+    tsprite.setYScroll(n);
+    this.yscroll = n;
+    this.onyscroll.sendEvent(n);
+}
+
+/**
   * The x scroll position of the textfield.
   * @lzxtype Number
   * @type Number
@@ -153,6 +227,16 @@
   */
     var xscroll;
 
+/**
+  * @access private
+  */
+function $lzc$set_xscroll(n) {
+    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+    tsprite.setXScroll(n);
+    this.xscroll = n;
+    this.onxscroll.sendEvent(n);
+}
+
 /** @access private */
     var scrollheight;
 
@@ -253,12 +337,63 @@
 var resize = true;
 
 /**
+  * @access private
+  */
+function $lzc$set_resize(val) {
+    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+    tsprite.setResize(val);
+    this.resize = val;
+}
+
+
+/**
   * The text to display in this text field.
   * @lzxtype string
   * @type String
   */
 var text;
 
+/**
+  * @access private
+  */
+function $lzc$set_text(t) {
+    // force to a string
+    t = '' + t;
+    if (this._textrecompute != true && t == this.getText()) return;
+    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);
+    if (this.visible) tsprite.setVisible(this.visible);
+    if (this.maxlength != null && t.length > this.maxlength){
+        t = t.substring(0, this.maxlength);
+    }
+    tsprite.setText(t);
+    this.text =  t;
+
+    if (this.width == 0 || (this.resize && this.multiline == false)) {
+        // single line resizable fields adjust their width to match the text
+        var w = this.getTextWidth();
+        // only set width if it changed
+        if (w != this.width) {
+            this.$lzc$set_width (w);
+        }
+    }
+
+    //resizable fields adjust their height
+    if (this.sizeToHeight) {
+        var h = tsprite.getTextfieldHeight();
+        if (h > 0) {
+            this.$lzc$set_height (h);
+        }
+    }
+
+    if (this.ontext.ready) this.ontext.sendEvent(t);
+    this._textrecompute = false;
+}
+
+
+/** true forces $lzc$set_text to do a full update
+    @access private */
+var _textrecompute:Boolean = false;
+
 /** @access private */ 
 var colorstring = "#000000"; // black
 
@@ -272,7 +407,7 @@
         var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
         var h = tsprite.getTextfieldHeight();
         if (h > 0) {
-            this.setHeight(h);
+            this.$lzc$set_height(h);
         }
     }
 }
@@ -321,10 +456,10 @@
     this.xscroll = 0;
 
     this.resize = ('resize' in args && (! (args.resize is LzValueExpr))) ? (!! args.resize) : this.resize;
-    this.setResize(this.resize);
+    this.setAttribute('resize', this.resize);
     
     if ('maxlength' in args && (! (args.maxlength is LzValueExpr)) && args.maxlength != null) {
-        this.setMaxLength(args.maxlength);
+       this.$lzc$set_maxlength(args.maxlength);
     }
 
     this.text =  (!('text' in args) || args.text == null || args.text instanceof LzInitExpr) ? "" : args.text;
@@ -356,7 +491,7 @@
             }
         }
     } else {
-        this.setResize(false);
+        this.$lzc$set_resize(false);
     }
 
     // To compute our height:
@@ -368,22 +503,22 @@
     if (!this.hassetheight) {
         this.sizeToHeight = true;
     } else if (! (args.height is LzValueExpr)) {
-        this.setHeight(args.height);
+        this.$lzc$set_height(args.height);
     }
     // Default the scrollheight to the visible height.
     this.scrollheight = this.height;
 
     if ('pattern' in args && (! (args.pattern is LzValueExpr)) && args.pattern != null) {
-        this.setPattern(args.pattern);
+        this.$lzc$set_pattern(args.pattern);
     }
 
 
     if (this.capabilities.advancedfonts) {
         if (! 'antiAliasType' in args && args.antiAliasType == null) {
-            this.setAntiAliasType("advanced"); 
+            this.$lzc$set_antiAliasType ("advanced");
         }
         if (! 'gridFit' in args && args.gridFit == null) {
-            this.setGridFit("subpixel"); 
+            this.$lzc$set_gridFit ("subpixel");
         }
     }
 }
@@ -412,23 +547,7 @@
 /**
   * @access private
   */
-function $lzc$set_text(v) { this.setText(v); }
-/**
-  * @access private
-  */
-function $lzc$set_resize(v) { this.setResize(v); }
-/**
-  * @access private
-  */
 var $lzc$set_multiline = -1;
-/**
-  * @access private
-  */
-function $lzc$set_yscroll(v) { this.setYScroll(v); }
-/**
-  * @access private
-  */
-function $lzc$set_xscroll(v) { this.setXScroll(v); }
 
 /**
   * If true, the text is selectable
@@ -439,7 +558,6 @@
 // no var decl since this is a virtual field
   * @access private
   */
-function $lzc$set_selectable(v) { this.setSelectable(v); }
 LzText.attributes.selectable = false;
 
 /**
@@ -449,9 +567,22 @@
   * @keywords read-only
   */
 var maxlength; 
+
 /** @access private */ 
-function $lzc$set_maxlength(v) { this.setMaxLength(v); }
+function $lzc$set_maxlength(val) {
+    if (val == null || val == '') return;
+    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+    tsprite.setMaxLength(val);
+    this.maxlength = val;
+    if (this.onmaxlength.ready) this.onmaxlength.sendEvent(val);
 
+    var t = this.getText();
+    if(t && t.length > this.maxlength){
+        this._textrecompute = true;
+        this.$lzc$set_text (t);
+    }
+}
+
 /**
   * regexp describing set of characters allowed in this field Restrict the characters that can be entered to a pattern specified by a regular expression. 
   * Currently only the expression [ ]* enclosing a set of characters or character ranges, preceded by an optional "^", is supported. examples: [0-9]* , [a-zA-Z0-9]*, [^0-9]*
@@ -460,8 +591,15 @@
   * @keywords read-only
   */
 var pattern; 
+
 /** @access private */  
-function $lzc$set_pattern(v) { this.setPattern(v); }
+function $lzc$set_pattern(val) {
+    if (val == null || val == '') return;
+    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
+    tsprite.setPattern(val);
+    this.pattern = val;
+    if (this.onpattern.ready) this.onpattern.sendEvent(val);
+}
 
 
 LzText.attributes.clip = true;
@@ -470,30 +608,30 @@
 
 
 
+
 /**
   * setResize set behavior of text field width when new text is added.
   * LzText only (cannot be used with LzInputText).
   * @param Boolean val: if true, the textfield will recompute it's width after setText() is called
   */
 function setResize ( val ){
-    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-    tsprite.setResize(val);
-    this.resize = val;
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_resize(val);
 }
 
 
 /**
   * @access private
   */
-override function setWidth ( val ){
+override function $lzc$set_width(val) {
     var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
     tsprite.setWidth(val);
-    super.setWidth.apply(this, arguments);
+    super.$lzc$set_width.apply(this, arguments);
     // recalculate height
     if (this.sizeToHeight) {
         var h = tsprite.getTextfieldHeight();
         if (h > 0) {
-            this.setHeight(h);
+            this.$lzc$set_height (h);
         }
     }
 }
@@ -512,14 +650,14 @@
     //tsprite.appendText( t );
     //this.text = tsprite.getText();
  
-   this.setText( this.getText() + t );
+    this.$lzc$set_text (this.getText() + t);
 }
 
 /**
   * Clears the text field (by setting its text to the empty string)
   */
 function clearText ( ){
-    this.setText( "" );
+    this.$lzc$set_text ("");
 }
 
 /**
@@ -528,29 +666,19 @@
   * @deprecated Use setAttribute('maxlength', ...) instead.
   */
 function setMaxLength ( val ){
-    if (val == null || val == '') return;
-    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-    tsprite.setMaxLength(val);
-    this.maxlength = val;
-    if (this.onmaxlength.ready) this.onmaxlength.sendEvent(val);
-
-    var t = this.getText();
-    if(t && t.length > this.maxlength){
-        this.setText (t, true);
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_maxlength(val);
 }
 
+
 /**
   * @access private
   * Set the pattern of chars a textfield can contain
   * @deprecated Use setAttribute('pattern', ...) instead.
   */
 function setPattern ( val ){
-    if (val == null || val == '') return;
-    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-    tsprite.setPattern(val);
-    this.pattern = val;
-    if (this.onpattern.ready) this.onpattern.sendEvent(val);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_pattern(val);
 }
 
 /**
@@ -585,7 +713,7 @@
     if ( null == d ){
         this.clearText();
     } else {
-        this.setText( d );
+        this.$lzc$set_text (d);
     }
 }
 
@@ -660,12 +788,11 @@
   * @deprecated Use setAttribute('xscroll', ...) instead.
   */
 function setXScroll ( n ){
-    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-    tsprite.setXScroll(n);
-    this.xscroll = n;
-    this.onxscroll.sendEvent(n);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_xscroll(n);
 }
 
+
 /**
   * Set the y scroll position of the textfield.
   * @param Number n: set the top line of the textfield to offset n pixels
@@ -673,24 +800,9 @@
   * @deprecated Use setAttribute('yscroll', ...) instead.
   */
 function setYScroll ( n ){
-    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-    tsprite.setYScroll(n);
-    this.yscroll = n;
-    this.onyscroll.sendEvent(n);
+    this.$lzc$set_yscroll(n);
 }
 
-/**
-  * @access private
-  */
-override function $lzc$set_font(v) { this.setFontName(v); }
-/**
-  * @access private
-  */
-function $lzc$set_fontsize(v) { this.setFontSize(v); }
-/**
-  * @access private
-  */
-function $lzc$set_fontstyle(v) { this.setFontStyle(v); }
 
 /**
   * @access private
@@ -784,41 +896,15 @@
     return end;
 }
 
+
 /**
   * Sets the text of the field to display
   * @param String t: the string to which to set the text
   * @deprecated Use setAttribute('text', ...) instead.
   */
-function setText ( t, force = null){
-    // force to a string
-    t = '' + t;
-    if (force != true && t == this.getText()) return;
-    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);
-    if (this.visible) tsprite.setVisible(this.visible);
-    if (this.maxlength != null && t.length > this.maxlength){
-        t = t.substring(0, this.maxlength);
-    }
-    tsprite.setText(t);
-    this.text =  t;
-
-    if (this.width == 0 || (this.resize && this.multiline == false)) {
-        // single line resizable fields adjust their width to match the text
-        var w = this.getTextWidth();
-        // only set width if it changed
-        if (w != this.width) {
-            this.setWidth(w);
-        }
-    }
-
-    //resizable fields adjust their height
-    if (this.sizeToHeight) {
-        var h = tsprite.getTextfieldHeight();
-        if (h > 0) {
-            this.setHeight(h);
-        }
-    }
-
-    if (this.ontext.ready) this.ontext.sendEvent(t);
+function setText (t) {
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_text(t);    
 }
 
 /**
@@ -834,7 +920,7 @@
   * control string
   */
 function format (control:String, ...args) {
-  this.setText(this.formatToString.apply(this, [control].concat(args)));
+    this.$lzc$set_text (this.formatToString.apply(this, [control].concat(args)));
 }
 
 /**
@@ -895,45 +981,62 @@
   * @deprecated Use setAttribute('selectable', ...) instead.
   */
 function setSelectable ( isSel ){
-    this.selectable = isSel;
-    var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-    tsprite.setSelectable(isSel);
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_selectable(isSel);
 }
 
 /**
   * @access private
   */
-override function setFontName ( fname ,prop = null){
+override function $lzc$set_font(fname) {
     var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
     tsprite.setFontName(fname);
     this.fontname = fname;
     // force recompute of height if needed
-    this.setText( this.getText(), true);
+    this._textrecompute = true;
+    this.$lzc$set_text(this.getText());
 }
 
 /**
   * @access private
-  * @deprecated Use setAttribute('fontsize', ...) instead.
   */
-function setFontSize ( fsize ){
+function $lzc$set_fontsize(fsize) {
     var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
     tsprite.setFontSize(fsize);
     this.fontsize = fsize;
     // force recompute of height if needed
-    this.setText( this.getText(), true);
+    this._textrecompute = true;
+    this.$lzc$set_text(this.getText());
 }
 
 /**
   * @access private
-  * @deprecated Use setAttribute('fontstyle', ...) instead.
+  * @deprecated Use setAttribute('fontsize', ...) instead.
   */
-function setFontStyle ( fstyle ){
+function setFontSize ( fsize ){
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_fontsize(fsize);
+}
+
+/**
+  * @access private
+  */
+function $lzc$set_fontstyle(fstyle) {
     var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
     tsprite.setFontStyle(fstyle);
     this.fontstyle = fstyle;
- }
+}
 
+/**
+  * @access private
+  * @deprecated Use setAttribute('fontstyle', ...) instead.
+  */
+function setFontStyle ( fstyle ){
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_fontstyle(fstyle);
+}
 
+
 /**
   * Sets whether or not the textfield wraps.  If false, only a single line
   * of text will appear and extra lines will be trucated if the text is set with
@@ -974,6 +1077,7 @@
     tsprite.setEmbedFonts(onroff);
 }
 
+
 /***
  * Sets what type of antialiasing the text field should use. Only works in swf8
  * and higher. 
@@ -981,17 +1085,8 @@
  * @deprecated Use setAttribute('antiAliasType', ...) instead.
  */
 function setAntiAliasType( aliasType ){
-    if (this.capabilities.advancedfonts) {    
-        if ((aliasType == "normal") || (aliasType == "advanced")) {
-            this.antiAliasType = aliasType; 
-            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-            tsprite.setAntiAliasType(aliasType);
-        } else if ($debug) {
-            Debug.warn("antiAliasType invalid, must be 'normal' or 'advanced', but you said '" + aliasType + "'");
-        }        
-    } else if ($debug) {
-        this.__warnCapability('text.setAntiAliasType()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_antiAliasType(aliasType);
 }
 
 /**
@@ -1006,6 +1101,7 @@
     }
 }
 
+
 /***
  * Sets what type of grid fitting the text field should use. 
  * Only works in swf8 and higher. 
@@ -1013,17 +1109,8 @@
  * @deprecated Use setAttribute('gridFit', ...) instead.
  */
 function setGridFit( gridFit ){
-    if (this.capabilities.advancedfonts) {    
-        if ((gridFit == "none") || (gridFit == "pixel") || (gridFit == "subpixel")) {
-            this.gridFit = gridFit; 
-            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-            tsprite.setGridFit(gridFit);
-        } else if ($debug) {
-            Debug.warn("gridFit invalid, must be 'none', 'pixel', or 'subpixel' but you said '" + gridFit + "'");
-        }
-    } else if ($debug) {
-        this.__warnCapability('text.setGridFit()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_gridFit(gridFit);
 }
 
 /**
@@ -1046,17 +1133,8 @@
  * @deprecated Use setAttribute('sharpness', ...) instead.
  */
 function setSharpness( sharpness ){
-    if (this.capabilities.advancedfonts) {
-        if  ((sharpness >= -400) && (sharpness <= 400)) {
-            this.sharpness = sharpness; 
-            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-            tsprite.setSharpness(sharpness);
-        } else if ($debug) {
-            Debug.warn("sharpness out of range, must be -400 to 400");
-        }        
-    } else if ($debug) {
-        this.__warnCapability('text.setSharpness()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_sharpness(sharpness);
 }
 
 /**
@@ -1072,6 +1150,7 @@
 }
 
 
+
 /***
  * Sets the thickness for the text rendering 
  * Only works in swf8 and higher. 
@@ -1079,17 +1158,8 @@
  * @deprecated Use setAttribute('thickness', ...) instead.
  */
 function setThickness( thickness ){
-    if (this.capabilities.advancedfonts) {
-        if  ((thickness >= -200) && (thickness <= 200)) {
-            this.thickness = thickness;
-            var tsprite:LzTextSprite = (this.sprite cast LzTextSprite);    
-            tsprite.setThickness(thickness); 
-        } else if ($debug) {
-            Debug.warn("thickness out of range, must be -200 to 200");
-        }
-    } else if ($debug) {
-        this.__warnCapability('text.setThickness()'); 
-    }
+    if ($debug) Debug.deprecated(this, arguments.callee, this.setAttribute);
+    this.$lzc$set_thickness(thickness);
 }
 
 /**

Modified: openlaszlo/trunk/lps/components/base/basebutton.lzx
===================================================================
--- openlaszlo/trunk/lps/components/base/basebutton.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/base/basebutton.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -100,15 +100,15 @@
         <!--- Overrides view's method for resourceviewcount.
               @param Number r: resource number.
               @access private -->
-        <method name="setResourceNumber" args="r"><![CDATA[
+        <setter name="frame" args="r"><![CDATA[
             if ( this.resourceviewcount > 0 ) {
                 for (var i = 0;i < resourceviewcount; i++ ) {
-                    this.subviews[i].setResourceNumber(r);
+                    this.subviews[i].setAttribute('frame', r);
                 }
             } else {
-                super.setResourceNumber(r);
+                super.setAttribute('frame', r);
             }
-       ]]> </method>
+       ]]> </setter>
 
         <!--- When the space bar is down, basebutton shows its down state. -->
         <method name="doSpaceDown" >

Modified: openlaszlo/trunk/lps/components/base/basecombobox.lzx
===================================================================
--- openlaszlo/trunk/lps/components/base/basecombobox.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/base/basecombobox.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -554,7 +554,7 @@
            return rv;
         </method>
 
-        <!--- Sets the displayed text.
+        <!--- Sets the displayed text. (This isn't an override from LzText)
               @param String t: the text to display. -->
         <method name="setText" args="t">
             this.text = t;
@@ -668,9 +668,9 @@
             }
         </method>
 
-        <method name="setWidth" args="w">
-            super.setWidth(Math.max(w,this.min_width));
-        </method>
+        <setter name="width" args="w">
+            super.setAttribute('width', (Math.max(w,this.min_width)));
+        </setter>
 
         <doc>
           <tag name="shortdesc"><text>baseclass for a combobox</text></tag>

Modified: openlaszlo/trunk/lps/components/base/baselistitem.lzx
===================================================================
--- openlaszlo/trunk/lps/components/base/baselistitem.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/base/baselistitem.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -22,7 +22,7 @@
         <attribute name="_selectonevent" value="onclick" type="string" setter="this.setSelectOnEvent(_selectonevent)" />
 
         <!--- @keywords private -->
-        <method name="setDatapath" args="dp">
+        <setter name="datapath" args="dp">
             if (null != this.datapath) {
                 this.datapath.setXPath(dp);
             } else {
@@ -37,7 +37,7 @@
                 }
                 new lz.datapath ( this, data_args );
             }
-        </method>
+        </setter>
 
         <!--- @keywords private -->
         <attribute name="_valuedatapath" value="null"/>

Modified: openlaszlo/trunk/lps/components/base/basetabs.lzx
===================================================================
--- openlaszlo/trunk/lps/components/base/basetabs.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/base/basetabs.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -358,9 +358,9 @@
               @keywords private -->
         <attribute name="_keepchildren" value="0" type="number" />
 
-        <!--- Overrides LzNode.setDatapath().
+        <!--- Overrides LzNode.datapath setter
               @keywords private -->
-        <method name="setDatapath" args="dp">
+        <setter name="datapath" args="dp">
 
                     if (null != this.datapath) {
                 this.datapath.setXPath(dp);
@@ -371,7 +371,7 @@
                 }
                 new lz.datapath ( this, data_args );
             }
-        </method>
+        </setter>
 
 
         <!--- Everything after _keepchildren number will be swallowed by 

Modified: openlaszlo/trunk/lps/components/base/basetabslider.lzx
===================================================================
--- openlaszlo/trunk/lps/components/base/basetabslider.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/base/basetabslider.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -101,14 +101,14 @@
         </method>
 
 
-        <!--- Set the height of the basetabslider.
+        <!--- Set the height of the basetabslider. Overrides LzView setter
               @param Number h: the height. -->
-        <method name="setHeight" args="h" >
+        <setter name="setHeight" args="h" >
             if ( h != height ) {
-                super.setHeight(h);
+                super.setAttribute('height', h);
                 this.resetHeight();
             }
-        </method>
+        </setter>
 
 
         <!--- Select a tabelement.

Modified: openlaszlo/trunk/lps/components/base/basewindow.lzx
===================================================================
--- openlaszlo/trunk/lps/components/base/basewindow.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/base/basewindow.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -357,16 +357,16 @@
         </method>
 
         <!--- @keywords private -->
-        <method name="setHeight" args="h">
+        <setter name="height" args="h">
            var nh = Math.round(h);
-           super.setHeight(nh);
-        </method>
+           super.setAttribute('height', nh);
+        </setter>
 
         <!--- @keywords private -->
-        <method name="setWidth" args="w">
+        <setter name="setWidth" args="w">
            var nw = Math.round(w);
-           super.setWidth(nw);
-        </method>
+           super.setAttribute('width', nw);
+        </setter>
 
         <doc>
           <tag name="shortdesc"><text>base window class</text></tag>

Modified: openlaszlo/trunk/lps/components/base/swatchview.lzx
===================================================================
--- openlaszlo/trunk/lps/components/base/swatchview.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/base/swatchview.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -12,9 +12,6 @@
         @keywords readonly -->
     <attribute name="color" value="0xffffff"/>
 
-    <!--- setting the fgcolor attribute is equivalent to setting bgcolor -->
-    <attribute name="fgcolor" setter="this.setColor( fgcolor )" />
-
     <!--- @keywords private -->
     <method name="construct" args="parent, args">  <![CDATA[
         super.construct( parent, args );
@@ -31,15 +28,17 @@
     </method>
 
 
-    <!--- @keywords private -->
-    <method name="setColor" args="c">
-        this.setBGColor( c );
-    </method>
+    <!--- setting the fgcolor attribute is equivalent to setting bgcolor
+        @keywords private -->
 
+    <setter name="fgcolor" args="c">
+        this.setAttribute('bgcolor', c);
+    </setter>
+
     <!--- sets the bgcolor with the color transform applied
     @param Number c: new bgcolor (e.g. 0xffffff for white)
     -->
-    <method name="setBGColor" args="c"> <![CDATA[
+    <setter name="bgcolor" args="c"> <![CDATA[
         this.color = c;
         if (this.ctransform != null) {
              var red= (c >> 16) & 0xFF;
@@ -57,9 +56,9 @@
              c = blue + (green << 8) + (red << 16);
 
         }
-        super.setBGColor(c);
+        super.setAttribute('bgcolor', c);
         ]]>
-    </method>
+    </setter>
 
     <!--- affects the bgcolor, unlike in regular views where only the
         resource and subviews are affected by the color transform
@@ -68,7 +67,7 @@
     <method name="setColorTransform" args="o">
         delete this.ctransform;
         this.ctransform = o;
-        this.setBGColor(this.color);
+        this.setAttribute('bgcolor', this.color);
     </method>
 
     <doc>

Modified: openlaszlo/trunk/lps/components/debugger/debugger.lzx
===================================================================
--- openlaszlo/trunk/lps/components/debugger/debugger.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/debugger/debugger.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -144,24 +144,24 @@
       this.commandhistory_ptr = this.commandhistory.length;
     </method>
 
-    <method name="setWidth" args="w" > 
-        super.setWidth( Math.max( 170 , Math.min( w , canvas.width) ) ); 
-    </method> 
+    <setter name="width" args="w" > 
+        super.setAttribute('width', Math.max( 170 , Math.min( w , canvas.width) ) ); 
+    </setter> 
 
-    <method name="setHeight" args="h" > 
-        super.setHeight( Math.max( 112 , Math.min( h , canvas.height) ) ); 
+    <setter name="height" args="h" > 
+        super.setAttribute ('height', Math.max( 112 , Math.min( h , canvas.height) ) ); 
         if (this.isLoaded) {
            this.middle.content.updateDisplay();
        }
-    </method> 
+    </setter> 
 
-    <method name="setX" args="x, force=null" > 
-        super.setX( Math.max( 0-(this.width-10), Math.min( x , canvas.width - 4) ) ); 
-    </method> 
+    <setter name="x" args="x, force=null" > 
+        super.setAttribute ('x', Math.max( 0-(this.width-10), Math.min( x , canvas.width - 4) ) ); 
+    </setter> 
 
-    <method name="setY" args="y, force=null" > 
-        super.setY( Math.max( 0 , Math.min( y , canvas.height - 4) ) ); 
-    </method> 
+    <setter name="y" args="y, force=null" > 
+        super.setAttribute ('y', Math.max( 0 , Math.min( y , canvas.height - 4) ) ); 
+    </setter> 
 
     <method name="initEvalView">
       <![CDATA[
@@ -685,14 +685,14 @@
           onmousedown="parent.bringToFront()"
         pixellock="true">
 
-       <method name="setHeight" args="h" > 
+       <setter name="setHeight" args="h" > 
         // keep a minimum of two lines of text displayed
           var minheight = (classroot.lineheight + 16);
-          super.setHeight( Math.max( parent.smallInputAreaHeight , Math.min( h , parent.height - (parent.top.height + minheight)) ) ); 
+          super.setAttribute('height', Math.max( parent.smallInputAreaHeight , Math.min( h , parent.height - (parent.top.height + minheight)) ) ); 
           if (parent.isLoaded) {
              parent.middle.content.updateDisplay();
          }
-       </method> 
+       </setter> 
 
        <state name="splitter">
           <attribute name="height" 

Modified: openlaszlo/trunk/lps/components/debugger/newcontent.lzx
===================================================================
--- openlaszlo/trunk/lps/components/debugger/newcontent.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/debugger/newcontent.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -129,9 +129,9 @@
                    resource="scrolldragdimpleshorz_rsc" options="ignorelayout" 
                    x="6" y="4" />
 
-           <method name="setX" args="x, force=null" > 
-              super.setX( Math.max(parent.arrowbuttonwidth-1 , Math.min( x, parent.width - parent.arrowbuttonwidth))); 
-           </method> 
+           <setter name="x" args="x" > 
+              super.setAttribute('x', Math.max(parent.arrowbuttonwidth-1 , Math.min( x, parent.width - parent.arrowbuttonwidth)));
+           </setter> 
 
           <!-- this gets called every time the x value changes -->
           <handler name="onx" reference="this"> 
@@ -153,14 +153,10 @@
      <method name="adjustDraggerXpos">
        // disable the constraint between ypos of dragger and text window for a moment
        this.setAttribute('autoscroll', false);
-       this.dragger.setX(this.computeDraggerXPos());
+       this.dragger.setAttribute('x', this.computeDraggerXPos());
        this.setAttribute('autoscroll', true);
      </method>
 
-    <method name="setWidth" args="w" > 
-       super.setWidth(w);
-    </method> 
-
      <method name="computeDraggerXPos">
        // subtract out height of left and right buttons
        var bw = this.arrowbuttonwidth;
@@ -251,9 +247,9 @@
               this.dimples.setResourceNumber(n)
            </method>
 
-           <method name="setY" args="y, force=null" > 
-              super.setY( Math.max(parent.arrowbuttonheight-1 , Math.min( y , parent.height - (parent.thumbheight + parent.arrowbuttonheight)))); 
-           </method> 
+           <setter name="y" args="y" > 
+              super.setAttribute('y', Math.max(parent.arrowbuttonheight-1 , Math.min( y , parent.height - (parent.thumbheight + parent.arrowbuttonheight)))); 
+           </setter>
 
           <!-- this gets called every time the y value changes -->
           <handler name="ony" reference="this"> 
@@ -285,10 +281,10 @@
                           width="${parent.width - 11}" 
                           bgcolor="#666666" height="13" />
 
-    <method name="setHeight" args="h" > 
-       super.setHeight(h);
+    <setter name="height" args="h" > 
+       super.setAttribute('height', h);
        this.updateDisplay();
-    </method> 
+    </setter> 
 
 
      <method name="setText" args="str">
@@ -310,7 +306,7 @@
      <method name="updateDisplay">
        // disable the constraint between ypos of dragger and text window for a moment
        this.setAttribute('autoscroll', false);
-       this.scrollbar.dragger.setY(this.computeDraggerYPos());
+       this.scrollbar.dragger.setAttribute('y', this.computeDraggerYPos());
        this.setAttribute('autoscroll', true);
      </method>
 
@@ -359,12 +355,12 @@
 
      <!-- incrementally slide the text content area left or right -->
      <method name="scrollx" args="nx">
-       this.textpane.setX(Math.min(0, Math.max(-(this.textpane.width), this.textpane.x + nx)));
+       this.textpane.setAttribute('x', Math.min(0, Math.max(-(this.textpane.width), this.textpane.x + nx)));
      </method>
 
      <!-- set the x offset of the text output content area -->
      <method name="setXScroll" args="x">
-       this.textpane.setX(Math.max (-(this.textpane.width), Math.min( 0, x)));
+       this.textpane.setAttribute('x', Math.max (-(this.textpane.width), Math.min( 0, x)));
      </method>
 
      <method name="scrollToEnd">

Modified: openlaszlo/trunk/lps/components/debugger/scrollingtext.lzx
===================================================================
--- openlaszlo/trunk/lps/components/debugger/scrollingtext.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/debugger/scrollingtext.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -153,10 +153,6 @@
        this.setAttribute('autoscroll', true);
      </method>
 
-    <method name="setWidth" args="w" > 
-       super.setWidth(w);
-    </method> 
-
      <method name="computeDraggerXPos">
        // subtract out height of left and right buttons
        var bw = this.arrowbuttonwidth;
@@ -285,10 +281,10 @@
                           width="${parent.width - 11}" 
                           bgcolor="#666666" height="13" />
 
-    <method name="setHeight" args="h" > 
-       super.setHeight(h);
+    <setter name="setHeight" args="h" > 
+       super.setAttribute('height', h);
        this.updateDisplay();
-    </method> 
+    </setter>
 
 
      <method name="setText" args="str">

Modified: openlaszlo/trunk/lps/components/extensions/av/videoview.lzx
===================================================================
--- openlaszlo/trunk/lps/components/extensions/av/videoview.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/extensions/av/videoview.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -181,8 +181,8 @@
 
         <!--- Set the videoview width. 
               @keywords private -->
-        <method name="setWidth" args="w"><![CDATA[
-            super.setWidth(w);
+        <setter name="setWidth" args="w"><![CDATA[
+            super.setAttribute('width', w);
 
             if (!this._clipinitdone) { 
                 this.width = w;
@@ -193,13 +193,13 @@
                 this._getflashvideo();
             vid._width = w;
           ]]>
-        </method>
+        </setter>
 
 
         <!--- Set the videoview height. 
               @keywords private -->
-        <method name="setHeight" args="h"><![CDATA[
-            super.setHeight(h);
+        <setter name="setHeight" args="h"><![CDATA[
+            super.setAttribute('height', h);
 
             if (!this._clipinitdone) {
                 this.height = h;
@@ -210,7 +210,7 @@
                 this._getflashvideo();
             vid._height = h;
           ]]>
-        </method>
+        </setter>
 
 
         <!--- Setter for the "playvolume" attribute. 

Modified: openlaszlo/trunk/lps/components/incubator/borderinput.lzx
===================================================================
--- openlaszlo/trunk/lps/components/incubator/borderinput.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/incubator/borderinput.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -42,14 +42,14 @@
         </baseedittext>
 
         <!--- @keywords private -->
-        <method name="setWidth" args="w">
-            super.setWidth(w);
+        <setter name="width" args="w">
+            super.setAttribute('width', w);
             if (this.isinited ) {
                 this.border.setWidth(w - this.labelwidth);
                 this.txt.setWidth(w - this.labelwidth - 2);
 
             }
-        </method>
+        </setter>
         
         <!--- Set text for border input.
               @param String t: text to set. 

Modified: openlaszlo/trunk/lps/components/incubator/rich-text/formatfontcolor.lzx
===================================================================
--- openlaszlo/trunk/lps/components/incubator/rich-text/formatfontcolor.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/incubator/rich-text/formatfontcolor.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -96,12 +96,12 @@
              this.editor.saveSelectionRegion();
          </handler>
          <colorsquare x="11" y="3" name="csq" drawsquare="true">
-             <method name="setColor" args="color">
+             <setter name="fgcolor" args="color">
                  this.setAttribute('visible',  color != null );
                  if (this.visible) {
                  this.setAttribute('swatchcolor', color);
                  }
-             </method>
+             </setter>
          </colorsquare>
      </class>
      

Modified: openlaszlo/trunk/lps/components/lz/alert.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/alert.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/alert.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -42,9 +42,9 @@
 
         <text name="alerttext" x="${parent.text_x}" y="${parent.text_y}"
             resize="true" multiline="true">
-            <attribute name="text" type="text" value="${parent.text}" setter="this.mySetText(text)"/>
-            <method name="mySetText" args="t">
-                super.setText(t);
+            <attribute name="text" type="text" value="${parent.text}"/>
+            <setter name="text" args="t">
+                super.setAttribute('text', t);
                 if (!parent._usecontentwidth) {
                     this.setWidth(parent.width
                         - parent.inset_left - parent.inset_right
@@ -58,7 +58,7 @@
                     }
                     this.setWidth(twidth);
                 }
-            </method>
+            </setter>
         </text>
 
         <!--- Opens the alert window. -->

Modified: openlaszlo/trunk/lps/components/lz/floatinglist.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/floatinglist.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/floatinglist.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -123,12 +123,12 @@
             <view resource="menucap_mid" stretches="width"/>
             <view resource="menucap_rt"/>
             <stableborderlayout axis="x" />
-            <method name="setResourceNumber" args="r"> <![CDATA[
+            <setter name="frame" args="r"> <![CDATA[
                 var L = this.subviews.length;
                 for ( var i = 0; i < L; i++ ) {
-                    this.subviews[i].setResourceNumber(r);
+                    this.subviews[i].setAttribute('frame', r);
                 } 
-             ]]> </method>
+             ]]> </setter>
             <method name="setY" args="y, force=null"> <![CDATA[
                 super.setY(y);
                 if ( y < 0 ) {
@@ -154,10 +154,10 @@
         </method>
         
         <!--- @keywords private -->
-        <method name="setBGColor" args="c" >
+        <setter name="bgcolor" args="c" >
             if ( !isinited ) return;
-            this.bkgnd.borderview.setBGColor(c);
-        </method>
+            this.bkgnd.borderview.setAttribute('bgcolor', c);
+        </setter>
 
         <!--- @keywords private -->
         <method name="getMenuCapHeight">

Modified: openlaszlo/trunk/lps/components/lz/gridcolumn.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/gridcolumn.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/gridcolumn.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -61,9 +61,9 @@
                     onclick="parent.doSort()"
                     clickable="$once{classroot.sortable}">
 
-                <method name="setClickable" args="cl">
-                    <![CDATA[ super.setClickable( cl && classroot.sortable );]]>
-                </method>
+                <setter name="clickable" args="cl">
+                    <![CDATA[ super.setAttribute ('clickable', cl && this.classroot.sortable );]]>
+                </setter>
                     
                 <view resource="lzgridsortarrow_rsrc"  name="sortarrow"
                       x="${ parent._title.x + parent._title.width + 2}"

Modified: openlaszlo/trunk/lps/components/lz/list.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/list.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/list.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -68,7 +68,7 @@
               y="${classroot.border_top}"
               width="${classroot.width
                         - classroot.border_right - classroot.border_left}"
-              bgcolor="${classroot._bgcolor}"
+              bgcolor="${classroot.bgcolor}"
               clip="true">
             <!-- height of this view is set in class' adjustheight method -->
 
@@ -229,7 +229,7 @@
         <attribute name="_heightinternal" value="false" type="boolean" />
 
         <!--- @keywords private -->
-        <method name="setHeight" args="h"> <![CDATA[
+        <setter name="height" args="h"> <![CDATA[
             if (h != null && !this._heightinternal) {
                 this._hasSetHeight = true;
             } else {
@@ -239,13 +239,13 @@
                     h = hgt + border_top + border_bottom;
                 }
             }
-            super.setHeight(h);
+            super.setAttribute('height', h);
             if ( this._initcomplete ) {
                 interior.setHeight( h - border_top - border_bottom );
                 checkscrollbar();
             }
             ]]>
-        </method>
+        </setter>
 
          <!--- @keywords private -->
          <method name="checkscrollbar"> <![CDATA[
@@ -284,34 +284,32 @@
         </method>
 
          <!--- @keywords private -->
-         <attribute name="_bgcolor" value="null"/>
-         <!--- @keywords private -->
          <attribute name="_setbordercolor" value="false" type="boolean" />
 
-         <!--- this._setbordercolor == true : call super to set border color
-               else set _bgcolor for "interior" view
-               @keywords private -->
-         <method name="setBGColor" args="c">
-             if (this._setbordercolor) {
-                super.setBGColor(c);
-             } else {
-                 // don't actually set the bgcolor,  'interior' view
-                 // sets its bgcolor from this attribute
-                this._bgcolor = c;
-                 if (this['on_bgcolor']) {
-                     this.on_bgcolor.sendEvent(c);
-                 }
-             }
-         </method>
+        <!--- @keywords private -->
+        <setter name="bgcolor" args="c"> <![CDATA[
+            if (this._setbordercolor) {
+                super.setAttribute('bgcolor', c);
+            }
+            else {
+                // DON'T call the super setter, we take over bgcolor to control
+                // the bgcolor of the content pane.
+                this.bgcolor = c;
+                var event = this['onbgcolor'];
+                if (event && event.ready) {
+                    event.sendEvent(c);
+                }
+            }
+        ]]> </setter>
 
          <!--- @keywords private -->
         <method name="_applystyle" args="s">
             if (this.style != null) {
                 super._applystyle(s);
                 this._setbordercolor = true;
-                this.setBGColor(s.bordercolor);
+                this.setAttribute('bgcolor', s.bordercolor);
                 this._setbordercolor = false;
-                if (this._bgcolor == null) this.interior.setBGColor(s.bgcolor);
+                if (this.bgcolor == null) this.interior.setAttribute('bgcolor', s.bgcolor);
             }
         </method>
 

Modified: openlaszlo/trunk/lps/components/lz/plainfloatinglist.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/plainfloatinglist.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/plainfloatinglist.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -41,10 +41,10 @@
         </method>
         
         <!--- @keywords private -->
-        <method name="setBGColor" args="c" >
+        <setter name="bgcolor" args="c" >
             if ( !isinited ) return;
-            this.bkgnd.borderview.setBGColor(c);
-        </method>
+            this.bkgnd.borderview.setAttribute('bgcolor', c);
+        </setter>
 
         <!-- initially this view will cover the contents of the list.
              this is rectified oninit by sending this.sendToBack()
@@ -75,7 +75,7 @@
 
 </library>
 <!-- * X_LZ_COPYRIGHT_BEGIN ***************************************************
-* Copyright 2001-2007 Laszlo Systems, Inc.  All Rights Reserved.              *
+* Copyright 2001-2008 Laszlo Systems, Inc.  All Rights Reserved.              *
 * Use is subject to license terms.                                            *
 * X_LZ_COPYRIGHT_END ****************************************************** -->
 <!-- @LZX_VERSION@                                                         -->

Modified: openlaszlo/trunk/lps/components/lz/tabelement.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/tabelement.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/tabelement.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -56,11 +56,6 @@
               @keywords private -->
         <attribute name="_mdoffset" value="2"/>
 
-        <!--- The background color for the tabelement. -->
-        <attribute name="bgcolor" setter="this._setBGColor( bgcolor );" />
-
-        <!--- @keywords private -->
-        <attribute name="_bgcolor"  value="null" />
         <!--- Insets the header art on the x-axis. Default is 0. -->
         <attribute name="headerpadding"   value="0" />
 
@@ -97,6 +92,7 @@
             <view name="content"
                   x="${classroot.inset_left}"
                   y="${classroot.inset_top}" 
+                  bgcolor="${classroot.bgcolor}"           
                   width="${ Math.max(parent.width - classroot.inset_left - classroot.inset_right, 0 ) }" 
                   height="${ Math.max(parent.height - classroot.inset_top - classroot.inset_bottom, 0) }" 
                   clip="true" visible="${classroot.contentvisible}"/>
@@ -126,24 +122,14 @@
             if (this.style != null) {
                 super._applystyle(s);
                 this.top.header.txt.setAttribute("fgcolor", s.textcolor);
-                if (this._bgcolor == null) {
+                if (this.bgcolor == null) {
                     this.container.setAttribute("bgcolor", s.bgcolor);
-                } else {
-                    this.container.setAttribute("bgcolor", this._bgcolor);
                 }
-                this.top.setBGColor(s.bordercolor);
+                this.top.setAttribute('bgcolor', s.bordercolor);
             }
         </method>
 
         <!--- @keywords private -->
-        <method name="_setBGColor" args="color">
-            this._bgcolor = color;
-            if (_initcomplete) {
-                this.container.setAttribute("bgcolor", color );
-            }
-        </method>
-
-        <!--- @keywords private -->
         <method name="doSpaceDown">
             this.top.bkgnd.doSpaceDown();
         </method>

Modified: openlaszlo/trunk/lps/components/lz/tabslider.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/tabslider.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/tabslider.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -19,18 +19,13 @@
         <attribute name="bordercolor"  value="${this.style != null ? this.style.bordercolor : null}"
                    setter="this.setBorderColor( bordercolor )" type="color" />
 
-        <!--- Background color. -->
-        <attribute name="bgcolor" setter="this._setBGColor( bgcolor );" />
-
-        <!--- @keywords private  -->
-        <attribute name="_bgcolor"  value="null" />
-
         <!--- The size of the border. Default is 1 pixel. -->
         <attribute name="bordersize"  value="1" setter="this.setBordersize(bordersize)" />
 
         <view name="content"
             x="${parent.bordersize}"
             y="${parent.bordersize}"
+            bgcolor="${classroot.bgcolor}"           
             width="${parent.width - 2*parent.bordersize}"
             height="${parent.height - 2*parent.bordersize}"  >
 
@@ -52,18 +47,9 @@
               @param Number color: the color number. -->
         <method name="setBorderColor" args="color" >
             this.bordercolor = color;
-            this.setBGColor( color );
+            this.setAttribute('bgcolor', color); 
         </method>
 
-        <!--- Setter for bgcolor.
-              @keywords private -->
-        <method name="_setBGColor" args="color" >
-            this._bgcolor = color;
-            if (_initcomplete) {
-                this.content.setBGColor( color );
-            }
-        </method>
-
         <!--- @keywords private -->
         <method name="_applystyle" args="s">
             if (this.style != null) {
@@ -71,10 +57,8 @@
                 this.interiorcolor = s.bgcolor;
                 this.fgcolor = s.textcolor;
                 this.bordercolor = s.bordercolor;
-                if (this._bgcolor == null) {
-                    this._setBGColor(s.bgcolor);
-                } else {
-                    this._setBGColor(this._bgcolor);
+                if (this.bgcolor == null) {
+                    this.content.setAttribute('bgcolor', s.bgcolor);
                 }
             }
         </method>

Modified: openlaszlo/trunk/lps/components/lz/windowpanel.lzx
===================================================================
--- openlaszlo/trunk/lps/components/lz/windowpanel.lzx	2008-09-04 21:50:45 UTC (rev 10876)
+++ openlaszlo/trunk/lps/components/lz/windowpanel.lzx	2008-09-04 23:17:51 UTC (rev 10877)
@@ -123,25 +123,22 @@
         </state>
 
         <!--- @keywords private -->
-        <method name="setBGColor" args="c">
+        <setter name="bgcolor" args="c"> <![CDATA[
+            // DON'T call the super setter, we take over bgcolor to control
+            // the bgcolor of the content pane.
             this.bgcolor = c;
-            // don't actually set the bgcolor, since 'content' view
-            // sets its bgcolor from this attribute
-            if (this['onbgcolor']) {
-                this.onbgcolor.sendEvent(c);
+            var event = this['onbgcolor'];
+            if (event && event.ready) {
+                event.sendEvent(c);
             }
-        </method>
+        ]]> </setter>
 
         <!--- @keywords private -->
         <attribute name="_usecontentwidth" value="true"/>
         <!--- @keywords private -->
         <attribute name="_usecontentheight" value="true"/>
 
-        <attribute name="bgcolor" setter="this._setBGColor( bgcolor );" />
         <!--- @keywords private -->
-        <attribute name="_bgcolor"  value="null" />
-
-        <!--- @keywords private -->
         <method name="construct" args="p,args"> <![CDATA[
             super.construct(p, args);
             // need to set these attributes before subviews are created
@@ -283,21 +280,11 @@
             setTint(this.middle, s.basecolor);
             setTint(this.bottom, s.basecolor);
             title_area.title.setAttribute('fgcolor', s.textcolor);
-            if (this._bgcolor == null) {
+            if (this.bgcolor == null) {
                 this.content.setAttribute("bgcolor", s.bgcolor);
-            } else {
-                this.content.setAttribute("bgcolor", this._bgcolor);
             }
         </method>
 
-        <!--- @keywords private -->
-        <method name="_setBGColor" args="color">
-            this._bgcolor = color;
-            if (_initcomplete) {
-                this.content.setAttribute("bgcolor", color );
-            }
-        </method>
-
         <doc>
           <tag name="shortdesc"><text>
               A draggable panel that provides common behavior for various window classes.



More information about the Laszlo-checkins mailing list