[UPDATED to address André's comments: 1. Use a shared instance of <text> for the <formatter> trampoline object
2. Use <formatter> in lzunit, resolving LPP-7793 Also tweaked a few doc issues noticed in passing.] Change ptw-20110211-H4Y by [email protected] on 2011-02-11 13:55:49 EST in /Users/ptw/OpenLaszlo/trunk-3 for http://svn.openlaszlo.org/openlaszlo/trunk Summary: Support dynamic tooltips Bugs Fixed: LPP-9750 Make a way for a tooltip to update itself before it is displayed LPP-7793 Cannot use lz.Formatter mxin for lzx classes Technical Reviewer: [email protected], [email protected] (pending) QA Reviewer: [email protected] (pending) Doc Reviewer: [email protected] (pending) Release Notes: The content of a <tooltip> can now be set from a CSS <stylesheet> using the `content` property. <tooltip> now has an `update` method that is called before a tooltip is (potentially) displayed. You can subclass <tooltip> and override this method to compute the tooltip text dynamically, or set the text to the empty string to prevent it from being displayed. A new mixin <formatter> has been added that can be used to add the methods available in the LzFormatter kernel mixin to any LZX class. Details: LzIdleKernel: Give the `__update` method a pretty name, since it shows up at the top of every stack trace. LzDefs: remove the pointless lz.Formatter. LzFormatter: Give the custom object example a little more vertical room so you can see it without scrolling. lzx-autoincludes, mixins/library: Add `cssfonts` (was missed in an earlier checkin), and `formatter`. tooltip: Add the `update` method and the `content` style property. lzunit: Use the new formatter mixin, per LPP-7793 formatter: LZX mixin wrapper for the `LzFormatter` kernel mixin. cssfonts: Give the example a reasonable canvas height. Tests: Test case from bug report used as example in tooltip documentation Files: M WEB-INF/lps/lfc/kernel/LzIdleKernel.lzs M WEB-INF/lps/lfc/core/LzDefs.lzs M WEB-INF/lps/lfc/compiler/LzFormatter.lzs M WEB-INF/lps/misc/lzx-autoincludes.properties M lps/components/lz/tooltip/tooltip.lzx M lps/components/lzunit/lzunit.lzx A lps/components/mixins/formatter.lzx M lps/components/mixins/library.lzx M lps/components/mixins/cssfonts.lzx Changeset: http://svn.openlaszlo.org/openlaszlo/patches/ptw-20110211-H4Y.tar
