Posted By

LeeProbert on 03/24/10


Tagged

textmate text layout Framework TLF FlowElement TextFlowLine


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

TrentSkunk
thastyle


Finding the position of an element within a TextFlow


 / Published in: ActionScript 3
 

  1. var linkStart:int = link.getAbsoluteStart();
  2. var linkEnd:int = linkStart+link.textLength;
  3.  
  4. var textFlowLine:TextFlowLine = textFlow.flowComposer.findLineAtPosition(linkStart);
  5. var lineStart:int = textFlowLine.absoluteStart;
  6. var isStartOfLine:Boolean = linkStart==lineStart;

Report this snippet  

You need to login to post a comment.