Not approved yet.  I'm getting warnings building the LFC in DHTML:

lzl:
[echo] Compiling /Users/maxcarlson/openlaszlo/trunk2/lps/includes/lfc/LFCdhtml-debug.js [java] Warning: __makeSprite free reference(s) converted to instance reference(s): [useTLF] [java] Warning: __makeSprite free reference(s) converted to instance reference(s): [useTLF] [java] Warning: $lzc$set_enabled free reference(s) converted to instance reference(s): [id]

On 7/12/10 3:37 PM, Henry Minsky wrote:

updated to include bidi-text direction setter and examples

Change 20100712-hqm-f by [email protected] on 2010-07-12 12:35:07 EDT
     in /Users/hqm/openlaszlo/trunktlf
     for http://svn.openlaszlo.org/openlaszlo/trunk

Summary: add support for bidirectional text

New Features:

Bugs Fixed: LPP-9179

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

Documentation:

Release Notes:

Overview:

A new class LzTLFTextField is added which is compatible with the
native flash.text.TextField implementation.

A flag in LzTextSprite, useTLF, says whether the instance should use
the new TextField implementation or the old native text class.


Details:

LzTLFTextField.as:

   + Implements a TextField compatible class

   + There are some TextField methods which LzTextSprite and
   LzInputTextSprite need that are not yet implemented, such as the
   scrolling APIs. These were largely working in the LzTLFTextSprite
   implementation, and need to be ported over.

   + This implementation contains code which is supposed to optimize the
   common case of simple non-HTML, non-selectable text, by bypassing the
   TextFlow and HTML importer mechanism.

   Currently however all LzText is using the htmlText feature, so all
   text views using this will be calling the HTML import and TextFlow
   layout routines. I'm leaving the 'optimized' code paths in for now so
   that if we run into any efficiency issues we may want to try using it.


   + The LzTLFTextField has a model of 'invalidate and deferred render',
   where if you change some attributes, it doesn't re-layout, but sets a
   flag to re-render when the next frame updates. I have a flag to bypass
   that and render immediately, because the implementation in
   __initTextProperties and __setFormat in LzTextSprite expect to be able
   to set and then measure text immediately. At initialization,
   LzTextSprite sets the flag to render immediately, and after
   __initTextProperties runs it sets it to deferred rendering.


LzText, LzTextSprite.as: created a flag named "useTLF" which says
whether to instantiate a new LzTLFTextField or the old
flash.text.TextField. It defaults to false, for back compatibility,
but text that needs bidirectional functionality can set this to true.

The classes LzTLFTextSprite and LzTLFInputTextSprite are not going to
be used any longer, but the implementation of scrolling from them
still needs to be copied over into LzTLFTextField, so I am leaving
them in the tree for now.

LzTLFSelectionManager.as, LzTLFEditManager.as: now have pointers to
the instance of LzTLFTextField, to allow needed control of some
mouse/cursor behavior

================

LzDebug.lzs, LzBootstrapDebugService.lzs: [not specific to bidi text
feature, but moved some things around so that the flash debugger
doesn't get errors when the app is just starting up, due to the lzx
Debugger not being fully initialized]

+ use LzBrowserKernel.getInitArg('logdebug')) instead of globalValue

+  moved the initialization of Debug.log_all_writes into LFCApplication, so that
the debugger is initialized enough to not get an error


Tests:

test/tlf/text-test.lzx

Files:
A       test/tlf/text-test.lzx
M       WEB-INF/lps/lfc/kernel/swf9/LzTLFTextSprite.as
M       WEB-INF/lps/lfc/kernel/swf9/LzTLFSelectionManager.as
M       WEB-INF/lps/lfc/kernel/swf9/LzTLFEditManager.as
M       WEB-INF/lps/lfc/kernel/swf9/LzInputTextSprite.as
A       WEB-INF/lps/lfc/kernel/swf9/LzTLFTextFieldStyleResolver.as
A       WEB-INF/lps/lfc/kernel/swf9/LzTLFTextFieldHostFormat.as
M       WEB-INF/lps/lfc/kernel/swf9/LzTextSprite.as
M       WEB-INF/lps/lfc/kernel/swf9/LzTextContainerManager.as
M       WEB-INF/lps/lfc/kernel/swf9/LFCApplication.as
A       WEB-INF/lps/lfc/kernel/swf9/LzTLFTextField.as
M       WEB-INF/lps/lfc/kernel/swf9/LzTLFInputTextSprite.as
M       WEB-INF/lps/lfc/kernel/swf9/Library.lzs
M       WEB-INF/lps/lfc/debugger/LzDebug.lzs
M       WEB-INF/lps/lfc/views/LzInputText.lzs
M       WEB-INF/lps/lfc/views/LzText.lzs
M       WEB-INF/lps/lfc/views/Library.lzs
M       WEB-INF/lps/lfc/compiler/LzBootstrapDebugService.lzs
M       WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassModel.java

Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20100712-hqm-f.tar

--
Regards,
Max Carlson
OpenLaszlo.org

Reply via email to