At the very least, until you have a font and a size, the other calls can just note their value and return. That's what I plan to add to my patch.
On Feb 6, 2011, at 16:42, Henry Minsky <[email protected]> wrote: > This does look like a waste of time. > > > I had a related JIRA task http://jira.openlaszlo.org/jira/browse/LPP-5354, > wondering if there was some > way to consolidate all the text parameters into one call, instead of each > setter for all the different text properties causing the whole text format > string to be recomputed. > > On Sun, Feb 6, 2011 at 4:04 PM, P T Withington <[email protected]> wrote: > This is causing errors in swf10 because when your text is styled, there is no > text format until way after construct time, but our text sprite constructor > still tries to build the sprite, set a format, etc. I can keep removing > stuff until it stops erring, but it seems odd to me that everything works, > despite the errors. It makes me think all the work done in the constructor > is wasted, since the args later get installed anyways and everything works > out. > > Is there any reason not to just rip out all the duplicate arg processing that > is happening in the constuctor? > > On 2011-02-04, at 23:25, Henry Minsky wrote: > > > thanks! looks to be working, approved! > > > > > > On Fri, Feb 4, 2011 at 11:16 PM, P T Withington <[email protected]> wrote: > > > >> You have a subtle type-oh: CSS classes are specified as '.elapsedtext' in > >> the style sheet. (without the '.' you are naming a tag, or LZX class). > >> Otherwise, yes. > >> > >> On Feb 4, 2011, at 23:05, Henry Minsky <[email protected]> wrote: > >> > >> So should I be able to do > >> > >> <stylesheet> > >> > >> elapsedtext { > >> font-size: 18; > >> font-family: Arial,Sans; > >> fgcolor: #61a5cc > >> } > >> > >> > >> durationtext { > >> font-size: 14; > >> font-family: Arial,Sans; > >> fgcolor: #666666 > >> } > >> > >> > >> </stylesheet> > >> > >> > >> <styledtext valign="middle" styleclass="elapsedtext" > >> name="elapsed" > >> text="${classroot.minsec(classroot.vp.currentTime) || '--:--'}" > >> with="cssfonts" /> > >> > >> And get an 18 point font? > >> > >> On Fri, Feb 4, 2011 at 8:24 PM, P T Withington < <[email protected]> > >> [email protected]> wrote: > >> > >>> [Henry, here is something for you to try out. It turns out I had already > >>> started work on this, so I just spiffed it up a bit.] > >>> > >>> > >>> Change ptw-20110204-8oI by [email protected] on 2011-02-04 20:10:18 EST > >>> in /Users/ptw/OpenLaszlo/trunk-3 > >>> for <http://svn.openlaszlo.org/openlaszlo/trunk> > >>> http://svn.openlaszlo.org/openlaszlo/trunk > >>> > >>> Summary: First cut at cssfont mixin > >>> > >>> Bugs Fixed: LPP-8556 Add default CSS style properties to <view> (partial) > >>> > >>> Technical Reviewer: > >>> <[email protected]>[email protected](pending) > >>> QA Reviewer: <[email protected]>[email protected] (pending) > >>> Doc Reviewer: <[email protected]>[email protected] (pending) > >>> > >>> Documentation: > >>> > >>> TBD > >>> > >>> Release Notes: > >>> > >>> TBD > >>> > >>> Overview: > >>> > >>> Inherited CSS abbreviations (e.g., `font`) do not work yet. Those > >>> only work if applicable directly to the text node. Working on > >>> making that work. This is just for Henry to test. > >>> > >>> Details: > >>> > >>> LzText: Enable disabling of "traditional" cascading, when the CSS > >>> mixin is used. > >>> > >>> cssfonts: Mixin to support styling font with CSS > >>> > >>> Tests: > >>> > >>> Henry to test. > >>> > >>> Files: > >>> M WEB-INF/lps/lfc/views/LzText.lzs > >>> A lps/components/mixins/cssfonts.lzx > >>> > >>> Changeset: > >>> <http://svn.openlaszlo.org/openlaszlo/patches/ptw-20110204-8oI.tar> > >>> http://svn.openlaszlo.org/openlaszlo/patches/ptw-20110204-8oI.tar > >>> > >> > >> > >> > >> -- > >> Henry Minsky > >> Software Architect > >> <[email protected]>[email protected] > >> > >> > >> > > > > > > -- > > Henry Minsky > > Software Architect > > [email protected] > > > > > -- > Henry Minsky > Software Architect > [email protected] > >
