2

I am using gnuplot and would like to get the symbol for "Angstrom" (Å, ISO encoding 305) and the Greek letter Delta (Δ, Symbol 104) in the plot. How can I combine the two encoding schemes when producing my output eps?

2

You can see the characters in this example:

set terminal postscript eps color enhanced size 10cm,10cm
set output 'pic.eps'
set encoding iso_8859_1
set xlabel "{/Symbol=30 a}"
set ylabel "{/Symbol=30 b}" 
set label "Label {/Symbol \104}{\305} End" at 1.7,2.5 font "Times,30"
set title "TITLE {/Symbol=30 \104}{/Helvetica=30 \305} END"
set key off
plot "-" with lines
1 3
2 2
3 3
end

The syntax for a character is {/fontname=size \code} so for example we have {/Symbol=30 \104} for the delta, and {/Helvetica=30 \305} or just {\305} for Angstrom. Ensure you have set encoding iso_8859_1 or similar to use the ISO Latin-1 encoding. See Enhanced text mode in the gnuplot guide at gnuplot.info.

enter image description here

1

For readability of your code, why not use UTF8?

set xlabel "{/Symbol D} Δ (Å)"

Gives in PDF terminal : result

with encoding to default but UTF8 as system wide locale:

gnuplot> show encoding

nominal character encoding is default
however LC_CTYPE in current locale is fr_FR.UTF-8

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.