• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

Emoticon Support and StageText worries

Explorer ,
Apr 27, 2014 Apr 27, 2014

Copy link to clipboard

Copied

Hi there,

in a new AIR 4 mobile application i need to offer a chat system. Since special characters are also required i'm trying to integrate StageText, since no other text component seems to be able to display these special characters correctly.

Unfortunately StageText still (!!!) does not offer any kind of measuring its content, which makes it impossible for me to display. Since every chat message has a different length the surrounding Scale9Image needs to know the exact

dimensions of the text message object.

Scrolling the container is also important, therefore the StageText needs to draw the content into a Bitmap which will be shown instead (since it's only displaying text messages and no input is required the StageText component is actually only needed for having access to the native emoticon support).

Now my questions:

1) Isn't there really no other way of not having to use StageText for being able to support these special characters ?

2) If not isn't there a more accurate way to measure the dimensions of a StageText object (what about integrating StyleableStageText or some other class) ?

So far i tried using these NativeText implementations:

https://github.com/cantrell/StageTextExample/blob/master/src/NativeText.as

http://firefly.in4ray.com/api/com/in4ray/gaming/components/NativeText.html

http://feathersui.com/documentation/feathers/controls/text/StageTextTextEditor.html

They all try to measure the text content by using the TextField/TextFormat way, but it didn't result in good values.

I hope that someone had similar problems and can help me. Thank you!

TOPICS
Development

Views

666

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jan 13, 2016 Jan 13, 2016

Copy link to clipboard

Copied

Did you find any solution?

I have the same problem too!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Jan 15, 2016 Jan 15, 2016

Copy link to clipboard

Copied

LATEST

What about using html Text and replacing special characters with <img> tags?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines