Ps.map works fine for me until I add a label to the map; then although the file is written OK, it cannot be opened - it gives a parsing error in Adobe Illustrator or any other program I use to open it. If I leave the label command out of the ps.map command file, it works fine, so the problem is there. I vaguely recall a thread about this but can't track it down. I've tried 6.0 and last cvs on Mac OSX 10.4.3. Any thoughts?
Ps.map works fine for me until I add a label to the map; then
although the file is written OK, it cannot be opened - it gives a
parsing error in Adobe Illustrator or any other program I use to open
it. If I leave the label command out of the ps.map command file, it
works fine, so the problem is there. I vaguely recall a thread about
this but can't track it down. I've tried 6.0 and last cvs on Mac OSX
10.4.3. Any thoughts?
1. What error message are you getting?
2. Can you provide a small PostScript file which demonstrates the
problem? Or, alternatively, a ps.map script which works in one of the
sample locations (e.g. Spearfish)?
Thanks for your thoughts. I looked into it a bit more, and finally figured out what was wrong. I had a list of 78 sites with name, latitude and longitude. One site name had an open parenthesis but no close parenthesis. Something about this caused a postscript error when I added labels in ps.map. Ps.map ran fine, but Adobe Illustrator gave a message "The operation cannot complete because of an unknown error." When I removed the open parenthesis, it worked fine. I'm not sure whether this counts as a bug or not, but it's certainly unexpected behavior.
Thanks,
Nick Cahill
On Feb 9, 2006, at 12:48 PM, Glynn Clements wrote:
Nick Cahill wrote:
Ps.map works fine for me until I add a label to the map; then
although the file is written OK, it cannot be opened - it gives a
parsing error in Adobe Illustrator or any other program I use to open
it. If I leave the label command out of the ps.map command file, it
works fine, so the problem is there. I vaguely recall a thread about
this but can't track it down. I've tried 6.0 and last cvs on Mac OSX
10.4.3. Any thoughts?
1. What error message are you getting?
2. Can you provide a small PostScript file which demonstrates the
problem? Or, alternatively, a ps.map script which works in one of the
sample locations (e.g. Spearfish)?
Thanks for your thoughts. I looked into it a bit more, and finally
figured out what was wrong. I had a list of 78 sites with name,
latitude and longitude. One site name had an open parenthesis but no
close parenthesis. Something about this caused a postscript error
when I added labels in ps.map. Ps.map ran fine, but Adobe Illustrator
gave a message "The operation cannot complete because of an unknown
error." When I removed the open parenthesis, it worked fine. I'm not
sure whether this counts as a bug or not, but it's certainly
unexpected behavior.
It's a bug.
ps.map feeds the labels directly into the PostScript file unaltered.
If you want to use unmatched () or spanning two lines you need to
have the label as "\(", "\)"
You can edit the .ps file after to do this.
ps.map should really do this for you, but currently it doesn't.
e.g. from a .ps file:
(34) 180.919200 669.694805 MS
(Helvetica-Bold) FN 13.0 SF
(Regional map showing interpolated values for February)
If you have an unmatched ")" in the label, the .ps interpreter will
think it is the end of the text string and the rest is PS commands..
& then crash.