I came across a weird behavior.
When i launch my basicUI the moonphase looks this way:
You see there are just ??? displayed.
At the beginning this was normal for me and i thought i need to look into it later and have done some mistake with saving the file in utf8 etc.
But today i just launched the website and had it standing for 10-15 seconds and suddenly the page changed to this:
Suddenly my unicode symbols for the moonpahse are working, but my time for sunset and sunrise did also change.
This happens not only in the smarthome designer, this happens on all types of devices, brwosers or ipad/iphone.
After a refresh of the website the time of sunrise/sunset is ok again but the unicode symbols turned into ??? again.
You’ll also notice, that some moon unicode characters are not supported by the Basic UI font (Helvetica) but by other UIs e.g. the Android App.
It’s pretty simple: Unicode defines a sheer set of characters and symbols but a font needs to provide the visual presentation. Different fonts have varying coverage.
Regarding your second screenshot: no idea what happened there but that could be an actual bug rather than a feature I’ll try to investigate
i have seen this line later then so i thought ok i have to live with it. But this flickering effect to a working display of the moon characters was made me wonder
Let me know if i can help with any debugging.
Btw. i am on the GA version of OH2, no snapshots
Hi,
i have played with the moon icons today a bit and may have found the reason or a part of it why i only see ? ?.
In one of the threads i have found a user using directly unicode codes to display the zodiac icons, like for cancer it’s \u264B.
Then i was looking for some moon icons and found on this website:
and none
That a beatiful moon unicode icon has the code 1F311, so i tried to use \u1F311 but this was not giving the moon icon in the basicui, it displayed something else.
So i searched a bit and was looking around how java handles usually unicode chars.
I found that JAVA has no issues with every code below FFFE which is unicode 1.1 up to 3.0.
So all items in unicode 4.0 and upwards causing issues.
Source (unfortunately in german: Openbooks: Fachbücher kostenlos online lesen | Rheinwerk Verlag)
I then found a page with some other suggestions how to write the unicode in the text, sample:
For the fullmoon \u1F311 this should be used: \uD83C\uDF11
see Unicode Character 'NEW MOON SYMBOL' (U+1F311)
This is then giving me the 2 Questionmarks.
So my feeling is OH may have some trouble with unicode 4.0 - 6.0. Or is it the used zulu java engine in openhabian 1.2? I have no chance currently to test if it works better with the oracle engine, but maybe one of you have an idea.