[GRASS-user] ps.map: rectangle over map border?
Nikos Alexandris
nik at nikosalexandris.net
Tue Mar 12 13:21:11 PDT 2013
Vincent Bain wrote:
> > Not sure to understand your issue, so my answer might be off-target :
Nikos Alexandris wrote:
> Reading the following, I think you do.
> > perhaps you can have a look at the output ps file. If it's only a matter
> > of display order, you can rearrange successive instructions within the
> > file in order to have your background laying over the border.
Hey Vincent, very true -- thank you! Can this be "picked-up" by ps.map?
> FWIW, I tried that in the ps.map script itself, i.e., first the border and
> then the rectangle. Doesn't this affect the display order? Will try later
> to edit the ps file.
I created two ps.map scripts: one containing a border and a rectangle, another
structurally identical, though with border's line- and the rectangle's fill-
colors changed.
Comparing with meld the two PSes shows where the (color) differences are.
This info along with the *beautifully* explained PS instructions, showed the
way ;-)
I just needed to change the very last part of the PS, from:
--%<---
grestore NP
399.7 478.2 M 706.7 478.2 LN
706.7 135.2 LN 399.7 135.2 LN
CP
0.000 1.000 0.000 C
F
0.502 0.502 0.502 C
0.10000000 W
D
0.000 0.000 1.000 C
0.72000000 W
36.5 72.5 507.8 522.8 B D
showpage
--->%--
to
--%<---
grestore
0.000 0.000 1.000 C
0.72000000 W
36.5 72.5 507.8 522.8 B D
NP
399.7 478.2 M 706.7 478.2 LN
706.7 135.2 LN 399.7 135.2 LN
CP
0.000 1.000 0.000 C
F
0.502 0.502 0.502 C
0.10000000 W
D
showpage
--->%--
And it works! With the modified instructions, the green-filled rectangle is
drawn on-top of the blue-line-colored border. Just for the records, the test-
pieces following.
The first one grey-line, black-box:
--%<---
# paper size
paper a4
end
# border around map?
border
color grey
width 0.01i
end
# background for the color-table?
rectangle 77% 90% 142% 14%
fcolor 0:0:0
color grey
width 0.1
end
end
--->%--
Blue line, green fill:
--%<---
# paper size
paper a4
end
# border around map?
border
color blue
width 0.01i
end
# raster map
# raster forest_fuel_classes
# scale 1:5000000
# maploc 0.5 0.5
# text 50% 115% ArcFUEL Forest Fuel Classes, Greece
# fontsize 20
# ref center
# end
# header
# end
# background for the color-table?
rectangle 77% 90% 142% 14%
fcolor 0:255:0
color grey
width 0.1
end
--->%--
Best, Nikos
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 230 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.osgeo.org/pipermail/grass-user/attachments/20130312/8d82176e/attachment.pgp>
More information about the grass-user
mailing list