PS_CHAR_ENCODING usage

Hi, Could you please tell me how I should use PS_CHAR_ENCODING? The entry in the manual really confuses me. I’ve tried the following which spits out the error “Error: /undefined in ISO-8859-1_Encoding”.

echo ‘10 10 Magnitude 6 or greater earthquakes’ | gmt pstext -J$proj -R$range
–PS_CHAR_ENCODING=ISO-8859-1
-F+a0+f12p,Bookman-Demi,white+jLT -G0/0/0 -TO -P -O -V -K >> $outps

Having an example in the https://docs.generic-mapping-tools.org/latest/gmt.conf.html would really help.

Also, a hyperlink to Appendix F in the following description is needed as I don’t know where Appendix F is.

PS_CHAR_ENCODING
(static) Names the eight bit character set being used for text in files and in command line parameters. This allows GMT to ensure that the PostScript output generates the correct characters on the plot. Choose from Standard, Standard+, ISOLatin1, ISOLatin1+, and ISO-8859-x (where x is in the ranges [1,10] or [13,15]). See Appendix F for details [ISOLatin1+ (or Standard+)]. Note: Normally the character set is written as part of the PostScript header. If you need to switch to another character set for a later overlay then you must use --PS_CHAR_ENCODING=encoding on the command line and not via gmt set.

Thanks!

Usually people switch to another char set because they are trying to print Russian, Greek, or other characters. I dont see that here. Anyway, this works in the sense there are no errors:

echo “10 10 Magnitude 6 or greater earthquakes” | gmt text -R0/20/0/20 -JM5i -B -F+a0+f12p,Bookman-Demi,white+jLT -G0/0/0 -TO --PS_CHAR_ENCODING=ISO-8859-1 -pdf map

I dont know what the rest of your script looks like but the single line you showed by itself cannot work without commands that come before it.

You are certainly right we should have some more examples of this in the docs.

Thanks Paul. I actually wanted to add the “≥” which is \263 in octal codes, and the above was a later version of
echo “10 10 M \263 6 earthquakes” | gmt text -R0/20/0/20 -JM5i -B -F+a0+f12p,Bookman-Demi,white+jLT -G0/0/0 -TO --PS_CHAR_ENCODING=Standard+

Just switching in and out of the symbol font (@~) is probably a lot easier.

Of course! Thank you!