Skip navigation
Home/Support/

Forums

391 Views 4 Replies Latest reply: Feb 17, 2011 4:01 PM by stefan van dinther RSS
Mahesh_Khatri Calculating status... 22 posts since
Oct 28, 2009
Currently Being Moderated

Jan 28, 2010 11:27 PM

Tab in TLF

I am working on a text editing tool and want to give user a Tab functionality but when user hits the tab the text shifts to next line. Is their any way to implement this.


-Mahesh.

  • rdermer Adobe Employee 695 posts since
    Jun 6, 2008
    Currently Being Moderated
    1. Jan 29, 2010 10:40 AM (in response to Mahesh_Khatri)
    Re: Tab in TLF

    In this case I suspect you haven't set any tabstops.  FlashPlayer 10 treats a tab without tabstops as a newline.  FlashPlayer 10.1 (available as a prerelease download) has default tabStops set to every 48 pixels.

     

    You can do one of two things to solve the problem:

    1) set the tabStops property on the containing ParagraphElement (it inherits so you could also set it on the TextFlow)

    2) Get the FlashPlayer 10.1 prerelease

     

    You probably should do both.

     

    Hope that helps,

    Richard

  • stefan van dinther User 48 posts since
    Sep 5, 2010
    Currently Being Moderated
    2. Feb 17, 2011 8:08 AM (in response to rdermer)
    Re: Tab in TLF

    Hello Richard,

     

    Is there a place where the defaultTabs are set?

    Can I change the defaultTabs?

     

    greetings, Stefan

  • rdermer Adobe Employee 695 posts since
    Jun 6, 2008
    Currently Being Moderated
    3. Feb 17, 2011 11:18 AM (in response to stefan van dinther)
    Re: Tab in TLF

    The defaults in FTE are fixed.  TextFlows are all created with a Configuration that defines the defaultTextFormat.

     

    One choice is to create a custom Configuration and set the textFlowInitialFormat with the tabs you want.  Pass that Configuration into any TextFlow constructor or importer to get all TextFlows to use those tabs.

     

    Another choice is to set TextFlow.defaultConfiguration to this new Configuration.

     

    Hope that helps,

    Richard

  • stefan van dinther User 48 posts since
    Sep 5, 2010
    Currently Being Moderated
    4. Feb 17, 2011 4:01 PM (in response to rdermer)
    Re: Tab in TLF

    Thanks again, Richard!

     

    greetings, Stefan

More Like This

  • Retrieving data ...

Bookmarked By (0)

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points