Bug #549

pstext -Gc not working

Added by Eduardo over 3 years ago. Updated about 3 years ago.

Status:ClosedStart date:2014-04-21
Priority:NormalDue date:
Assignee:Paul% Done:

100%

Category:-
Target version:Candidate for next bugfix release
Affected version:5.x-svn Platform:Linux

Description

If I understood the man page, I can do a pstext with -Gc then do ie. a grdcontour to plot contour lines and, then psclip -Cs to plot the pstext's text. That isn't working.

Also pstext and grdcontour man pages talk about psclip -Ct but that doesn't exist.

Files attached.

clip_test_with_clip-2.sh Magnifier (2.5 KB) Eduardo, 2014-04-21 11:34

test.grd (423 KB) Eduardo, 2014-04-21 11:34

with_clip_2.pdf (150 KB) Eduardo, 2014-04-21 11:35

Associated revisions

Revision 13071
Added by Paul over 3 years ago

Adding new test based on issue #549

History

#1 Updated by Paul over 3 years ago

  • Status changed from New to In Progress

I have added a test based on this (test/pstext/cliptxtbox.sh). I notice ghostview shows some clip boxes but not the PDF.
Also see textclip.sh in the test/pstext dir for an example. Not the same as yours though. In r13071.

#2 Updated by Paul over 3 years ago

I fixed the psclip -Ct reference in pstext man page. Where else? Did not see anything in grdcontour.rst... In r13072.

#3 Updated by Eduardo over 3 years ago

explain_labelinfo.rst

+e
Delay the plotting of the text. This is used to build a clip path
based on the text, then lay down other overlays while that clip path
is in effect, then turning of clipping with psclip -Ct which
finally plots the original text.

#4 Updated by Eduardo over 3 years ago

I can see the clipping in PS file. But the clip is very tight, +c isn't working and +p plots nothing.

#5 Updated by Paul over 3 years ago

Thanks, fixed explain_labelinfo.rst_ in r13074.

#6 Updated by Eduardo over 3 years ago

I've missed explain_symbols.rst and explain_symbols2.rst both have +e sub-option and psclip -Ct.

#7 Updated by Paul over 3 years ago

Thanx, in r13077.

#8 Updated by Paul over 3 years ago

Notes while working on this bug. I added test script pstext/boxtext.sh which shows (at least part of) the problem. Problem 1: The font is set correctly, but then the basemap is annotated with another font size, and by the time psclip comes to finish the plotting the font size has changed. Problem 2: The clipbox is not honored. More specifically: gv does actually show the clip box, but it is offset in x as the x margin of 1 cm is ignored; the y margin of 1 cm is honored, however. Also, gs (hence ps2raster) and Adobe Distiller fail to show the clipbox at all if PDF is produced, but ps2raster shows the clipbox if rasterized to JPG, PNG,etc. Not sure if our PS for clipping is incorrect (but understood by gs unless we ask for PDF) or if there are bugs in gs and Distiller at this point. My PostScript printer also fails to show the clip box hence I lean towards incorrect PS clip implementation by us.

#9 Updated by Eduardo about 3 years ago

RESOLVED

#10 Updated by Paul about 3 years ago

  • Status changed from In Progress to Resolved
  • Assignee set to Paul
  • % Done changed from 0 to 100

Changing to resolved.

#11 Updated by Paul about 3 years ago

  • Status changed from Resolved to Closed

Sorry, meant to close

Also available in: Atom PDF