Discussion:
[bug #33155] text function fails to display degree symbol
anonymous
2011-04-25 06:30:24 UTC
Permalink
Please use the bug tracker to post updates to a bug report. The mailing list is intended as a read-only notification stream. Info posted to this mailing list address won't appear in the tracker database where it is most useful.

URL:
<http://savannah.gnu.org/bugs/?33155>

Summary: text function fails to display degree symbol
Project: GNU Octave
Submitted by: None
Submitted on: Mon 25 Apr 2011 06:30:23 AM UTC
Category: Plotting
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Incorrect Result
Status: None
Assigned to: None
Originator Name:
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: dev
Operating System: GNU/Linux

_______________________________________________________

Details:

The following code demonstrates the problem:

x=1:10;y=x.^2;plot(x,y);
text(x(3),y(3),' test symbol ° text')


Under fltk, a warning is displayed (4 times) on the terminal:

warning: ft_render: skipping missing glyph for character `�'


Nothing is rendered on the plot.

Under gnuplot, 2 characters are rendered (not the desired one) and the same
warnings are displayed on the terminal.

Have tried setting different default fonts, no change in warnings or outputs.




_______________________________________________________

Reply to this item at:

<http://savannah.gnu.org/bugs/?33155>

_______________________________________________
Messa
Rik
2011-05-15 01:52:00 UTC
Permalink
Please use the bug tracker to post updates to a bug report. The mailing list is intended as a read-only notification stream. Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Update of bug #33155 (project octave):

Status: None => Confirmed

_______________________________________________________

Follow-up Comment #1:

Confirmed on a recent development branch tip (2011/05/14). This is annoying,
but probably won't get fixed immediately. My guess is that it is an
interaction between how your command window is encoding characters (maybe
UTF-8) and how Octave expects them.

For a temporary workaround, try constructing strings using the hex or decimal
value of the special character you are trying to use. For example, the degree
symbol has a decimal value of 176 so the following works:


graphics_toolkit gnuplot
plot (1:10);
str = ["100", char(176), " Celcius is 212", char(176), " Fahrenheit"];
ht = text (2,6,str);


This will only work with gnuplot. The FLTK toolkit won't work even with this
approach.


_______________________________________________________

Reply to this item at:

<http://savannah.gnu.org/bugs/?33155>

_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
Rik
2013-08-28 18:25:14 UTC
Permalink
Please use the bug tracker to post updates to a bug report. The mailing list is intended as a read-only notification stream. Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Follow-up Comment #2, bug #33155 (project octave):

The FLTK toolkit has been modified on the development branch to support both
'char(176)' or the TeX sequence '\circ' for producing a degree symbol

_______________________________________________________

Reply to this item at:

<http://savannah.gnu.org/bugs/?33155>

_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
Michael Godfrey
2013-08-29 03:29:55 UTC
Permalink
Please use the bug tracker to post updates to a bug report. The mailing list is intended as a read-only notification stream. Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Follow-up Comment #4, bug #33155 (project octave):

This report and #39828 are discussing closely related
topics.

Would it make sense to continue the gnuplot issues
here, and fltk issues on #39828?

Sorry for any confusion.


_______________________________________________________

Reply to this item at:

<http://savannah.gnu.org/bugs/?33155>

_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
John W. Eaton
2014-01-03 16:07:20 UTC
Permalink
Please use the bug tracker to post updates to a bug report. The mailing list is intended as a read-only notification stream. Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Follow-up Comment #5, bug #33155 (project octave):

Ping?

The original example seems to work properly for me now with opengl+fltk but
not with gnuplot. With gnuplot, the degree symbol is shown on the screen, but
so is an extra glyph (A with a caret over it).


_______________________________________________________

Reply to this item at:

<http://savannah.gnu.org/bugs/?33155>

_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
Rik
2014-01-03 16:42:57 UTC
Permalink
Please use the bug tracker to post updates to a bug report. The mailing list is intended as a read-only notification stream. Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Update of bug #33155 (project octave):

Category: Plotting => Plotting with gnuplot

_______________________________________________________

Follow-up Comment #6:

The real problem now is UTF-8 characters on the command line. We could file a
bug report about that and mark it postponed since that is going to be quite a
project to work out.

_______________________________________________________

Reply to this item at:

<http://savannah.gnu.org/bugs/?33155>

_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
Mike Miller
2014-03-27 06:03:35 UTC
Permalink
Please use the bug tracker to post updates to a bug report. The mailing list is intended as a read-only notification stream. Info posted to this mailing list address won't appear in the tracker database where it is most useful.

Update of bug #33155 (project octave):

Status: Confirmed => Fixed
Open/Closed: Open => Closed

_______________________________________________________

Follow-up Comment #7:

Using the qt or wxt terminals of gnuplot 4.6.5, this works perfectly. It's
only the x11 terminal that displays the extra  character.

Based on that, Octave is able to send a sequence of UTF-8 bytes to gnuplot and
have it be interpreted correctly. It seems to only depend on the gnuplot
terminal type and that's pretty much out of Octave's control.

I say mark this as fixed.

_______________________________________________________

Reply to this item at:

<http://savannah.gnu.org/bugs/?33155>

_______________________________________________
Message sent via/by

Continue reading on narkive:
Loading...