Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Using Emoji instead of images - good or bad idea

Hello,

 

Considering the multiple warnings in the documentation about images (especially jpg) performance. I tried and confirm that emoji are supported. That would allow me to replace some images with text/emoji.

is that a good or bad idea from a performance perspective ?

 

Thanks,

Jo

Best Answer
0 Votes
8 REPLIES 8

Note that you can't set certain emojis using javascript. For example:

 

myText.text = "Heart";

 

But you can set it inside the SVG file.

 

<text>Heart</text>

Best Answer
0 Votes

I am surprised that it would not work, javascript is supposed to be unicode nowadays. This works in chrome as an example. I can't open the dev studio right now to check why it would not work.

 

But if that is the case you should be able to reference unicode characters like

let myText = "Thumbsup \u{1F44D}";
Best Answer
0 Votes

@AJoewrote:

I am surprised that it would not work, javascript is supposed to be unicode nowadays. This works in chrome as an example. I can't open the dev studio right now to check why it would not work.

 

But if that is the case you should be able to reference unicode characters like

let myText = "Thumbsup \u{1F44D}";

You can reference it, but you can't assign it to the text node. It fails here:

myText.text = "\u{1F44D}";

Best Answer
0 Votes

Interesting point @EmTe i had not noticed. i checked and sadly https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/fromCodePoin... is not supported even with the polyfill. If needed i would place an emoji in hidden text components to dynamically get/add it where needed. 

 

But back to my original point, i was curious if Fitibit staff could give us guidance on this topic. Is that a good practice or not. I thought they were participating in this forum, are they not ?

Best Answer

It would be a nice idea... but from what I can see, the Fitbit OS fonts don't have support for Emoji

 

I tried the ♡ character and I just got the standard bordered question mark placeholder.

 

I could not found much info about the fonts ... For example, default is a custom font name Seville http://atipofoundry.com/custom/seville-font-for-fitbit

 

I found samples of Colfax and Fabrikat on the next but they don't look to support Emoji. https://www.myfonts.com/fonts/hvdfonts/fabrikat/

 

Best Answer
0 Votes

You can copy and paste the character directly into your "index.gui" file in the SVG.

Best Answer
0 Votes

You can copy and paste the character directly into your "index.gui" file in the SVG.

 

I did just that, but the character was not visible on the device...at least not on my simulator.

 

Were you able to show emoji on versa or ionic?

 

Thanks

Best Answer
0 Votes

@adiroiban wrote:

You can copy and paste the character directly into your "index.gui" file in the SVG.

I did just that, but the character was not visible on the device...at least not on my simulator.

Were you able to show emoji on versa or ionic?

Thanks


Yes but copying and pasting the character directly into index.gui as if it were any regular character like "!@#$%^&".

Best Answer
0 Votes