another pstricks question

Denis Girou Denis.Girou at idris.fr
Wed Dec 9 22:09:34 CET 1998


-----------------------------------------------------------------------------
This is the PSTricks mailing list, devoted to discussions about computational
graphics in (La)TeX using the PSTricks package from Timothy van Zandt.
For help using this mailing list, see instructions at the end of message.
-----------------------------------------------------------------------------

>>>>> "Gordon.Royle" == Gordon Royle <gordon at bilby.uwaterloo.ca> writes:

    Gordon.Royle> I am trying to do "knot diagrams" where I want to give the impression
    Gordon.Royle> that one strand passes under another.

    Gordon.Royle> 		 |
    Gordon.Royle> 		---
    Gordon.Royle> 		 |

    Gordon.Royle> I know that if I am drawing two separate lines, then I can use "border"
    Gordon.Royle> to give this impression.

    Gordon.Royle> But often I just have a number of points that I join together using
    Gordon.Royle> "psccurve"  and I do not want to draw them as lots of individual
    Gordon.Royle> segments. When I set "border" before psccurve I expected it to
    Gordon.Royle> give the right effect, so that when the curve intersected itself
    Gordon.Royle> the border would "white out" part of the line already drawn. But
    Gordon.Royle> this does not seem to happen; instead I get perfect crossings.

    Gordon.Royle> \pspicture(-5,-5)(5,5)
    Gordon.Royle> \psset{border=0.25cm}
    Gordon.Royle> \psccurve(0,2)(1.73,-1)(0,-4)(-1.73,-1)(0,2)(3.46,2)(1.73,-1)(-1.73,-1)(-3.46,2
    Gordon.Royle> )
    Gordon.Royle> \endpspicture

    Gordon.Royle> Is there any way that i can get the "brush" to obliterate what was there
    Gordon.Royle> earlier?

  Well, this is rather an interesting question and drawing "knots" a useful 
feature for some specialized persons. I'm afraid that it would be a rather
difficult problem... From what I know in the TeX world, only Xy-pic has a
package for "Knots and links". Results seems rather impressive, but usage
seems not very simple (I never try to use it and only read it documentation).

  I see nothing in the current features of PSTricks which can help to solve
the problem you submit. "border" can't do something useful here. Just change
bordercolor to red, for instance, to see how it work : a large line of the
border color is first drawn along the defined path, then the "normal" one is
redrawn above it. Of course, this is not the desired effect, and work only to
erase parts of objects previously drawn...

  The PostScript code is only:

gsave 7.11317 2 mul CLW add SLW 1. setgray stroke grestore
gsave 0.8 SLW 0. setgray 0 setlinecap stroke grestore

  So, unfortunately I see no solution to this problem...

D.G.

-----------------------------------------------------------------------------
The list interface (subscription, information, access to the archives) is on:
http://www.tug.org/cgi-bin/lwgate/pstricks
Otherway to unsubscribe, send mail to pstricks-request at mail.tug.org
with a blank subject and in body the line unsubscribe <email-address>
-----------------------------------------------------------------------------



More information about the PSTricks mailing list