Skip to main content
Participating Frequently
October 2, 2009
Question

Set TextFlow scroll

  • October 2, 2009
  • 1 reply
  • 1219 views

Hi Guys,

no solution found about this problem... how set an auto scrollbar for TLF?

This code was working with the first version of TLF Component for Flash CS4:

---------------------------------------------------------------------------------------------------------------------------------------------------

private function setTextFromXML(oXML:XML):void {

     oTextFlow = TextFilter.importToFlow(oXML, TextFilter.TEXT_LAYOUT_FORMAT);

     oTextFlow.flowComposer.updateAllControllers();

}

public function setSize(oWidth:int, oHeight:int):void {

     oTextFlow.flowComposer.addController(new ContainerController(this, oWidth, oHeight));

     oTextFlow.flowComposer.getControllerAt(0).verticalScrollPolicy = ScrollPolicy.ON;

     oTextFlow.flowComposer.getControllerAt(0).setCompositionSize(oWidth, oHeight);

     oTextFlow.flowComposer.compose();

     oTextFlow.flowComposer.updateAllControllers();

}

---------------------------------------------------------------------------------------------------------------------------------------------------

Now I'm working with textLayout.SWC from Flex 3.

This topic has been closed for replies.

1 reply

Adobe Employee
October 2, 2009

I'd suggest you look at the Flex Gumbo controls that use TLF and have scrolling built in. The "RichText" component might be a good place to start.

- robin