TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What is the equivalent of the pstricks command \psecurve in tikz?

The yellow line is the \psecurve. It's basically the same as the \pscurve: the curve is defined by all the named points, but is not drawn to the end points.




enter image description here

share|improve this question

You can use my style between style (from TikZ: Thick curve segment in a curve):

enter image description here

  style between/.style n args={3}{
    postaction={initcounter, decorate,
      decoration={show path construction, curveto code={
          \pgfmathtruncatemacro{\min}{#1 - 1}
          \ifthenelse{\thepos < #2 \AND \thepos > \min}{
            (\tikzinputsegmentfirst) .. controls
               (\tikzinputsegmentsupporta) and (\tikzinputsegmentsupportb)
            .. (\tikzinputsegmentlast);
\begin{tikzpicture}[line join=round]
  \draw[line width=5pt,<->]
  (0,0) to[out=70,in=180] (2,3) to[out=0,in=180] (4,-3)
  to [out=0,in=0] (2,5) to[out=180,in=100] (1,0);

  \path [style between={2}{4}{line width=1.5pt,yellow}]
  (0,0) to[out=70,in=180] (2,3) to[out=0,in=180] (4,-3)
  to [out=0,in=0] (2,5) to[out=180,in=100] (1,0);
share|improve this answer
Could you explain how this works at all? – A.Ellett Feb 19 '13 at 0:33
@A.Ellett Look at the show path construction decoration into the pgf manual. – Paul Gaborit Feb 19 '13 at 0:38
That's what I've been doing. It still looks like magic to me. – A.Ellett Feb 19 '13 at 0:43
The default arrow head of TikZ is not as sharp as that of PSTricks. (But it is not the point here) – kiss my armpit Feb 19 '13 at 2:09
@GarbageCollector TikZ \neq PSTricks. You may use >=stealth... – Paul Gaborit Feb 19 '13 at 7:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.