Forums | developer.brewmp.com Forums | developer.brewmp.com

Developer

Forums

Hi all,

I have to add emoticons in to text widget.. i think i may have to write an extension for that.. but not sure where to start with?
Should i use the emoticons .bmp files or some other encoding?
Or should i add them into some font files or something?

thus anyone have any idea? I am kindof stuck.. not knowing what to do.. :(

You can implement the smiley support in a font extension (IFont) and let the font take care of drawing of smiley. You can use this font in your textwidget.
Also, in your font extension, implement some helper APIs for left/right cursor movement & character index calculation at particular width for up/down cursor movement, and use in your textlayout.

You can implement the smiley support in a font extension (IFont) and let the font take care of drawing of smiley. You can use this font in your textwidget.
Also, in your font extension, implement some helper APIs for left/right cursor movement & character index calculation at particular width for up/down cursor movement, and use in your textlayout.

Yes.. writing a Font Extension seemed to be a good idea!! i did the same thing!! thanx for your suggestion!!

Yes.. writing a Font Extension seemed to be a good idea!! i did the same thing!! thanx for your suggestion!!