[IGN-5692]Designer showing °C as °C in Perspective Label in Embedded View

v8.1.22

I have a "template" View I'm embedding into another View which has a Label in it that shows a temperature. Below is the label when editing the template View.
image

The units show correctly. However when I embed this into another View for display, in the Designer it shows up as °C:

image

In a standard browser (Chrome) it displays fine, but I'd like to know the reason it displays strangely in the Designer when embedded?

Edit: the template is in my global / parent project.

Edit 2: the binding on the temp label is this:

{
  "type": "expr",
  "config": {
    "expression": "numberFormat({this.custom.pv}, \u00270.0\u0027) + \u0027 °C\u0027"
  }
}

I've tried a simple case and I can't get it to go bad with static text in the label

Edit 3: I've successfully reproduced it by binding the template label to:

{
  "type": "expr",
  "config": {
    "expression": "\u0027°C\u0027"
  }
}

image

Edit 4: This displays correctly:

image

3 Likes

I've had this issue with other symbols:

designer:
image

browser:
image

8.1.21, this was also happening in (I think) 8.1.14.

edit:
copy/pasted your binding on a label, and it seems to work fine:
image

1 Like

image
it seems its really getting converted into this while in jxbrowser

1 Like

Interestingly, the two strings are different.

Expression binding:

'°C'

produces u'\n\xb0C'

but binding:

char(0186) + 'C'

produces u'\n\xbaC'

ºC °C
You can even see the difference here. The first (char(0186)) is bolder, while Alt+0186 is lighter

"Symbol Name: Degree Sign"

"Symbol Name: Masculine Ordinal Indicator"

Oh no! I've been using the wrong little o everywhere for the last 12 years :dizzy_face:

But at least it's masculine.

3 Likes

Haha. It still produces the same thing though with the  at the start if I just do '°C' though :frowning:

very weird why it happens in embeded views only xd
maybe it uses a different parser? xd

2 Likes

I guess for now I'll do the weird char(176) method :confused:
image
much better!

Yea I just replaced my arrows with char(9660) and char(9658) too.
Not that it changes much, as the browser rendered them properly, but...

yeah it's a bit gross, but it's better than looking at strange characters all day and having the labels spill onto the next line because of them!

Possibly the same root cause as this other thread:

I can see Nick is on Windows; @pascal.fragnoud, are you also on Windows?

1 Like

i got this too and im on windows

The designer is. Not sure if relevant, but ignition is installed on debian.

All Chinese characters from binding in embedded view are broken.

That would be super annoying!

If any of you can try out the workaround(s) here, that would be helpful:

I tried both JVM Arguments and ignition.conf, they didn't work.

1 Like

A work around is to pass in the Unicode to the embedded view and then reference that in your view.

image

1 Like