Place parallel line markers on parallel lines

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite
1












I'm trying to add the > and >> on the two sets of parallel lines and having no luck.



documentclassscrreprt
usepackagetikz

begindocument


begintikzpicture[scale=1,xscale=2]
coordinate (A) at (0,0);
coordinate (B) at (2,2.5);
coordinate (C) at (4,2.5);
coordinate (D) at (2,0);
draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (B)node[midway]SINGLE;
draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (C) -- (D)node[midway]SINGLE;
draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (D)node[midway]DOUBLE;
draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (B) -- (C)node[midway]DOUBLE;
endtikzpicture

enddocument









share|improve this question

























    up vote
    1
    down vote

    favorite
    1












    I'm trying to add the > and >> on the two sets of parallel lines and having no luck.



    documentclassscrreprt
    usepackagetikz

    begindocument


    begintikzpicture[scale=1,xscale=2]
    coordinate (A) at (0,0);
    coordinate (B) at (2,2.5);
    coordinate (C) at (4,2.5);
    coordinate (D) at (2,0);
    draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (B)node[midway]SINGLE;
    draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (C) -- (D)node[midway]SINGLE;
    draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (D)node[midway]DOUBLE;
    draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (B) -- (C)node[midway]DOUBLE;
    endtikzpicture

    enddocument









    share|improve this question























      up vote
      1
      down vote

      favorite
      1









      up vote
      1
      down vote

      favorite
      1






      1





      I'm trying to add the > and >> on the two sets of parallel lines and having no luck.



      documentclassscrreprt
      usepackagetikz

      begindocument


      begintikzpicture[scale=1,xscale=2]
      coordinate (A) at (0,0);
      coordinate (B) at (2,2.5);
      coordinate (C) at (4,2.5);
      coordinate (D) at (2,0);
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (B)node[midway]SINGLE;
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (C) -- (D)node[midway]SINGLE;
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (D)node[midway]DOUBLE;
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (B) -- (C)node[midway]DOUBLE;
      endtikzpicture

      enddocument









      share|improve this question













      I'm trying to add the > and >> on the two sets of parallel lines and having no luck.



      documentclassscrreprt
      usepackagetikz

      begindocument


      begintikzpicture[scale=1,xscale=2]
      coordinate (A) at (0,0);
      coordinate (B) at (2,2.5);
      coordinate (C) at (4,2.5);
      coordinate (D) at (2,0);
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (B)node[midway]SINGLE;
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (C) -- (D)node[midway]SINGLE;
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (A) -- (D)node[midway]DOUBLE;
      draw[<->,thick,shorten >=-60pt,shorten <=-60pt] (B) -- (C)node[midway]DOUBLE;
      endtikzpicture

      enddocument






      tikz-pgf parallel






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked 3 hours ago









      Benjamin Compson

      373




      373




















          2 Answers
          2






          active

          oldest

          votes

















          up vote
          3
          down vote



          accepted










          You can use a decoration to do this. The code below defines two new arrow types ->- and ->>- that do what you want



          enter image description here



          Presumably the arrows stack because these are decorations.



          Here is the code:



          documentclassscrreprt
          usepackagetikz
          usetikzlibrarydecorations.markings
          tikzset%
          ->-/.style=decoration=markings, mark=at position 0.5 with arrow>,
          postaction=decorate,
          ->>-/.style=decoration=markings, mark=at position 0.5 with arrow>>,
          postaction=decorate,


          begindocument


          begintikzpicture[scale=1,xscale=2]
          coordinate (A) at (0,0);
          coordinate (B) at (2,2.5);
          coordinate (C) at (4,2.5);
          coordinate (D) at (2,0);
          draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (A) -- (B);
          draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (D) -- (C);
          draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (A) -- (D);
          draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (B) -- (C);
          endtikzpicture

          enddocument


          Notice that I had to reverse the code for the D-C line. Alternatively, you could use -<- if you add the definition:



          tikzset%
          -<-/.style=decoration=markings, mark=at position 0.5 with arrow<,
          postaction=decorate,






          share|improve this answer




















          • Thank you so much! That works exactly how I wanted.
            – Benjamin Compson
            3 hours ago

















          up vote
          1
          down vote













          Just a complement, an option in tikz Euclide, that has some ad hoc mark statements, decorations also available using scope for the desired marks.



          RESULT:



          enter image description here



          MWE:



          documentclass[tikz,border=20pt]standalone
          usepackagetkz-euclide
          usetikzlibraryarrows.meta
          usetkzobjall

          begindocument
          begintikzpicture
          %Definindo os vertices
          %%The best way to define Axis is using polar notation:
          tkzDefPoint(0,0)A %The reference point
          tkzDefShiftPoint[A](0:5)B% POINT B
          tkzDefShiftPoint[A](40:4)D %POIN D

          %%Find point C colinear at D from AB
          tkzDefPointWith[colinear= at D](A,B) tkzGetPointC

          %%Find point E colinear at C from DB
          tkzDefPointWith[colinear= at C](D,B) tkzGetPointE

          %Drawing modified style lines
          %style only afects commands inside
          tikzsetline style/.append style=<->,>=Stealth[scale=2.2,inset=0pt,angle'=20]
          tkzDrawLine[add=40pt and 40pt](A,B)
          tkzDrawLine[add=40pt and 40pt](D,C)
          tkzDrawLine[add=40pt and 40pt](A,D)
          tkzDrawLine[add=40pt and 40pt](B,C)

          beginscope[decoration=markings,mark=at position .6 with arrow[scale=2]>>;]
          tkzDrawSegments[postaction=decorate,dashed](D,B C,E)
          endscope


          %Drawing and label Points
          tkzDrawPoints[color=blue,fill=blue,size=6pt](A,B,C,D)
          tkzLabelPoints[color=blue,below=5pt,inner sep=0](A,B,C,D)

          %Mark Segments
          tkzMarkSegments[mark=||](A,B D,C)
          tkzMarkSegments[mark=|](B,C A,D)
          endtikzpicture

          enddocument





          share|improve this answer




















            Your Answer







            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "85"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            convertImagesToLinks: false,
            noModals: false,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













             

            draft saved


            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f454577%2fplace-parallel-line-markers-on-parallel-lines%23new-answer', 'question_page');

            );

            Post as a guest






























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            3
            down vote



            accepted










            You can use a decoration to do this. The code below defines two new arrow types ->- and ->>- that do what you want



            enter image description here



            Presumably the arrows stack because these are decorations.



            Here is the code:



            documentclassscrreprt
            usepackagetikz
            usetikzlibrarydecorations.markings
            tikzset%
            ->-/.style=decoration=markings, mark=at position 0.5 with arrow>,
            postaction=decorate,
            ->>-/.style=decoration=markings, mark=at position 0.5 with arrow>>,
            postaction=decorate,


            begindocument


            begintikzpicture[scale=1,xscale=2]
            coordinate (A) at (0,0);
            coordinate (B) at (2,2.5);
            coordinate (C) at (4,2.5);
            coordinate (D) at (2,0);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (A) -- (B);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (D) -- (C);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (A) -- (D);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (B) -- (C);
            endtikzpicture

            enddocument


            Notice that I had to reverse the code for the D-C line. Alternatively, you could use -<- if you add the definition:



            tikzset%
            -<-/.style=decoration=markings, mark=at position 0.5 with arrow<,
            postaction=decorate,






            share|improve this answer




















            • Thank you so much! That works exactly how I wanted.
              – Benjamin Compson
              3 hours ago














            up vote
            3
            down vote



            accepted










            You can use a decoration to do this. The code below defines two new arrow types ->- and ->>- that do what you want



            enter image description here



            Presumably the arrows stack because these are decorations.



            Here is the code:



            documentclassscrreprt
            usepackagetikz
            usetikzlibrarydecorations.markings
            tikzset%
            ->-/.style=decoration=markings, mark=at position 0.5 with arrow>,
            postaction=decorate,
            ->>-/.style=decoration=markings, mark=at position 0.5 with arrow>>,
            postaction=decorate,


            begindocument


            begintikzpicture[scale=1,xscale=2]
            coordinate (A) at (0,0);
            coordinate (B) at (2,2.5);
            coordinate (C) at (4,2.5);
            coordinate (D) at (2,0);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (A) -- (B);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (D) -- (C);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (A) -- (D);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (B) -- (C);
            endtikzpicture

            enddocument


            Notice that I had to reverse the code for the D-C line. Alternatively, you could use -<- if you add the definition:



            tikzset%
            -<-/.style=decoration=markings, mark=at position 0.5 with arrow<,
            postaction=decorate,






            share|improve this answer




















            • Thank you so much! That works exactly how I wanted.
              – Benjamin Compson
              3 hours ago












            up vote
            3
            down vote



            accepted







            up vote
            3
            down vote



            accepted






            You can use a decoration to do this. The code below defines two new arrow types ->- and ->>- that do what you want



            enter image description here



            Presumably the arrows stack because these are decorations.



            Here is the code:



            documentclassscrreprt
            usepackagetikz
            usetikzlibrarydecorations.markings
            tikzset%
            ->-/.style=decoration=markings, mark=at position 0.5 with arrow>,
            postaction=decorate,
            ->>-/.style=decoration=markings, mark=at position 0.5 with arrow>>,
            postaction=decorate,


            begindocument


            begintikzpicture[scale=1,xscale=2]
            coordinate (A) at (0,0);
            coordinate (B) at (2,2.5);
            coordinate (C) at (4,2.5);
            coordinate (D) at (2,0);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (A) -- (B);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (D) -- (C);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (A) -- (D);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (B) -- (C);
            endtikzpicture

            enddocument


            Notice that I had to reverse the code for the D-C line. Alternatively, you could use -<- if you add the definition:



            tikzset%
            -<-/.style=decoration=markings, mark=at position 0.5 with arrow<,
            postaction=decorate,






            share|improve this answer












            You can use a decoration to do this. The code below defines two new arrow types ->- and ->>- that do what you want



            enter image description here



            Presumably the arrows stack because these are decorations.



            Here is the code:



            documentclassscrreprt
            usepackagetikz
            usetikzlibrarydecorations.markings
            tikzset%
            ->-/.style=decoration=markings, mark=at position 0.5 with arrow>,
            postaction=decorate,
            ->>-/.style=decoration=markings, mark=at position 0.5 with arrow>>,
            postaction=decorate,


            begindocument


            begintikzpicture[scale=1,xscale=2]
            coordinate (A) at (0,0);
            coordinate (B) at (2,2.5);
            coordinate (C) at (4,2.5);
            coordinate (D) at (2,0);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (A) -- (B);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->-] (D) -- (C);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (A) -- (D);
            draw[<->,thick,shorten >=-60pt,shorten <=-60pt,->>-] (B) -- (C);
            endtikzpicture

            enddocument


            Notice that I had to reverse the code for the D-C line. Alternatively, you could use -<- if you add the definition:



            tikzset%
            -<-/.style=decoration=markings, mark=at position 0.5 with arrow<,
            postaction=decorate,







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered 3 hours ago









            Andrew

            27.8k34075




            27.8k34075











            • Thank you so much! That works exactly how I wanted.
              – Benjamin Compson
              3 hours ago
















            • Thank you so much! That works exactly how I wanted.
              – Benjamin Compson
              3 hours ago















            Thank you so much! That works exactly how I wanted.
            – Benjamin Compson
            3 hours ago




            Thank you so much! That works exactly how I wanted.
            – Benjamin Compson
            3 hours ago










            up vote
            1
            down vote













            Just a complement, an option in tikz Euclide, that has some ad hoc mark statements, decorations also available using scope for the desired marks.



            RESULT:



            enter image description here



            MWE:



            documentclass[tikz,border=20pt]standalone
            usepackagetkz-euclide
            usetikzlibraryarrows.meta
            usetkzobjall

            begindocument
            begintikzpicture
            %Definindo os vertices
            %%The best way to define Axis is using polar notation:
            tkzDefPoint(0,0)A %The reference point
            tkzDefShiftPoint[A](0:5)B% POINT B
            tkzDefShiftPoint[A](40:4)D %POIN D

            %%Find point C colinear at D from AB
            tkzDefPointWith[colinear= at D](A,B) tkzGetPointC

            %%Find point E colinear at C from DB
            tkzDefPointWith[colinear= at C](D,B) tkzGetPointE

            %Drawing modified style lines
            %style only afects commands inside
            tikzsetline style/.append style=<->,>=Stealth[scale=2.2,inset=0pt,angle'=20]
            tkzDrawLine[add=40pt and 40pt](A,B)
            tkzDrawLine[add=40pt and 40pt](D,C)
            tkzDrawLine[add=40pt and 40pt](A,D)
            tkzDrawLine[add=40pt and 40pt](B,C)

            beginscope[decoration=markings,mark=at position .6 with arrow[scale=2]>>;]
            tkzDrawSegments[postaction=decorate,dashed](D,B C,E)
            endscope


            %Drawing and label Points
            tkzDrawPoints[color=blue,fill=blue,size=6pt](A,B,C,D)
            tkzLabelPoints[color=blue,below=5pt,inner sep=0](A,B,C,D)

            %Mark Segments
            tkzMarkSegments[mark=||](A,B D,C)
            tkzMarkSegments[mark=|](B,C A,D)
            endtikzpicture

            enddocument





            share|improve this answer
























              up vote
              1
              down vote













              Just a complement, an option in tikz Euclide, that has some ad hoc mark statements, decorations also available using scope for the desired marks.



              RESULT:



              enter image description here



              MWE:



              documentclass[tikz,border=20pt]standalone
              usepackagetkz-euclide
              usetikzlibraryarrows.meta
              usetkzobjall

              begindocument
              begintikzpicture
              %Definindo os vertices
              %%The best way to define Axis is using polar notation:
              tkzDefPoint(0,0)A %The reference point
              tkzDefShiftPoint[A](0:5)B% POINT B
              tkzDefShiftPoint[A](40:4)D %POIN D

              %%Find point C colinear at D from AB
              tkzDefPointWith[colinear= at D](A,B) tkzGetPointC

              %%Find point E colinear at C from DB
              tkzDefPointWith[colinear= at C](D,B) tkzGetPointE

              %Drawing modified style lines
              %style only afects commands inside
              tikzsetline style/.append style=<->,>=Stealth[scale=2.2,inset=0pt,angle'=20]
              tkzDrawLine[add=40pt and 40pt](A,B)
              tkzDrawLine[add=40pt and 40pt](D,C)
              tkzDrawLine[add=40pt and 40pt](A,D)
              tkzDrawLine[add=40pt and 40pt](B,C)

              beginscope[decoration=markings,mark=at position .6 with arrow[scale=2]>>;]
              tkzDrawSegments[postaction=decorate,dashed](D,B C,E)
              endscope


              %Drawing and label Points
              tkzDrawPoints[color=blue,fill=blue,size=6pt](A,B,C,D)
              tkzLabelPoints[color=blue,below=5pt,inner sep=0](A,B,C,D)

              %Mark Segments
              tkzMarkSegments[mark=||](A,B D,C)
              tkzMarkSegments[mark=|](B,C A,D)
              endtikzpicture

              enddocument





              share|improve this answer






















                up vote
                1
                down vote










                up vote
                1
                down vote









                Just a complement, an option in tikz Euclide, that has some ad hoc mark statements, decorations also available using scope for the desired marks.



                RESULT:



                enter image description here



                MWE:



                documentclass[tikz,border=20pt]standalone
                usepackagetkz-euclide
                usetikzlibraryarrows.meta
                usetkzobjall

                begindocument
                begintikzpicture
                %Definindo os vertices
                %%The best way to define Axis is using polar notation:
                tkzDefPoint(0,0)A %The reference point
                tkzDefShiftPoint[A](0:5)B% POINT B
                tkzDefShiftPoint[A](40:4)D %POIN D

                %%Find point C colinear at D from AB
                tkzDefPointWith[colinear= at D](A,B) tkzGetPointC

                %%Find point E colinear at C from DB
                tkzDefPointWith[colinear= at C](D,B) tkzGetPointE

                %Drawing modified style lines
                %style only afects commands inside
                tikzsetline style/.append style=<->,>=Stealth[scale=2.2,inset=0pt,angle'=20]
                tkzDrawLine[add=40pt and 40pt](A,B)
                tkzDrawLine[add=40pt and 40pt](D,C)
                tkzDrawLine[add=40pt and 40pt](A,D)
                tkzDrawLine[add=40pt and 40pt](B,C)

                beginscope[decoration=markings,mark=at position .6 with arrow[scale=2]>>;]
                tkzDrawSegments[postaction=decorate,dashed](D,B C,E)
                endscope


                %Drawing and label Points
                tkzDrawPoints[color=blue,fill=blue,size=6pt](A,B,C,D)
                tkzLabelPoints[color=blue,below=5pt,inner sep=0](A,B,C,D)

                %Mark Segments
                tkzMarkSegments[mark=||](A,B D,C)
                tkzMarkSegments[mark=|](B,C A,D)
                endtikzpicture

                enddocument





                share|improve this answer












                Just a complement, an option in tikz Euclide, that has some ad hoc mark statements, decorations also available using scope for the desired marks.



                RESULT:



                enter image description here



                MWE:



                documentclass[tikz,border=20pt]standalone
                usepackagetkz-euclide
                usetikzlibraryarrows.meta
                usetkzobjall

                begindocument
                begintikzpicture
                %Definindo os vertices
                %%The best way to define Axis is using polar notation:
                tkzDefPoint(0,0)A %The reference point
                tkzDefShiftPoint[A](0:5)B% POINT B
                tkzDefShiftPoint[A](40:4)D %POIN D

                %%Find point C colinear at D from AB
                tkzDefPointWith[colinear= at D](A,B) tkzGetPointC

                %%Find point E colinear at C from DB
                tkzDefPointWith[colinear= at C](D,B) tkzGetPointE

                %Drawing modified style lines
                %style only afects commands inside
                tikzsetline style/.append style=<->,>=Stealth[scale=2.2,inset=0pt,angle'=20]
                tkzDrawLine[add=40pt and 40pt](A,B)
                tkzDrawLine[add=40pt and 40pt](D,C)
                tkzDrawLine[add=40pt and 40pt](A,D)
                tkzDrawLine[add=40pt and 40pt](B,C)

                beginscope[decoration=markings,mark=at position .6 with arrow[scale=2]>>;]
                tkzDrawSegments[postaction=decorate,dashed](D,B C,E)
                endscope


                %Drawing and label Points
                tkzDrawPoints[color=blue,fill=blue,size=6pt](A,B,C,D)
                tkzLabelPoints[color=blue,below=5pt,inner sep=0](A,B,C,D)

                %Mark Segments
                tkzMarkSegments[mark=||](A,B D,C)
                tkzMarkSegments[mark=|](B,C A,D)
                endtikzpicture

                enddocument






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered 2 hours ago









                J Leon V.

                7,484529




                7,484529



























                     

                    draft saved


                    draft discarded















































                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f454577%2fplace-parallel-line-markers-on-parallel-lines%23new-answer', 'question_page');

                    );

                    Post as a guest













































































                    Comments

                    Popular posts from this blog

                    Long meetings (6-7 hours a day): Being “babysat” by supervisor

                    Is the Concept of Multiple Fantasy Races Scientifically Flawed? [closed]

                    Confectionery