You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by Harbs <ha...@gmail.com> on 2014/02/02 09:45:54 UTC

Easy way to remove TLF text cursor?

I might be missing something obvious, but I don't see an easy way to remove a text cursor from TLF text.

Setting stage.focus = null prevents input, but you still get the blinking cursor. Doing this on multiple text containers will get you multiple blinking cursors.

Any suggestions?

Harbs

Re: Easy way to remove TLF text cursor?

Posted by Harbs <ha...@gmail.com>.
Yup. I'm very familiar with TLF.

My issue was programmatically removing focus from an editable TextFlow…

On Feb 2, 2014, at 3:10 PM, After24 wrote:

> Hi Harbs,
> 
> If you need a non-editable TextFlow, you just have to set his interaction
> manager to null.
> 
> Vincent.
> 
> 
> 
> --
> View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Easy-way-to-remove-TLF-text-cursor-tp4744p4750.html
> Sent from the Apache Flex Users mailing list archive at Nabble.com.


Re: Easy way to remove TLF text cursor?

Posted by After24 <vi...@after24.net>.
Hi Harbs,

If you need a non-editable TextFlow, you just have to set his interaction
manager to null.

Vincent.



--
View this message in context: http://apache-flex-users.2333346.n4.nabble.com/Easy-way-to-remove-TLF-text-cursor-tp4744p4750.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Re: Easy way to remove TLF text cursor?

Posted by Alex Harui <ah...@adobe.com>.
FWIW, setting stage.focus = null may get overridden by the Flex
FocusManager.  It might try to restore focus to the control.  The
FocusManager tries to make sure something always has focus.

Also note that the blinking cursor is a child Sprite or Shape of the text
widget.

-Alex

On 2/2/14 1:09 AM, "Harbs" <ha...@gmail.com> wrote:

>I knew this at some pointŠ
>
>textFlow.interactionManager.selectRange(-1,-1);
>
>On Feb 2, 2014, at 10:45 AM, Harbs wrote:
>
>> I might be missing something obvious, but I don't see an easy way to
>>remove a text cursor from TLF text.
>> 
>> Setting stage.focus = null prevents input, but you still get the
>>blinking cursor. Doing this on multiple text containers will get you
>>multiple blinking cursors.
>> 
>> Any suggestions?
>> 
>> Harbs
>


Re: Easy way to remove TLF text cursor?

Posted by Harbs <ha...@gmail.com>.
I knew this at some point…

textFlow.interactionManager.selectRange(-1,-1);

On Feb 2, 2014, at 10:45 AM, Harbs wrote:

> I might be missing something obvious, but I don't see an easy way to remove a text cursor from TLF text.
> 
> Setting stage.focus = null prevents input, but you still get the blinking cursor. Doing this on multiple text containers will get you multiple blinking cursors.
> 
> Any suggestions?
> 
> Harbs