Take the 2-minute tour ×
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.

What's the best way to insert a horizonal dashed line with a scissor symbol to indicate that the paper should be cut with a scissor along this line?

If you have multiple layout alternatives without much code, please post it.

share|improve this question
add comment

3 Answers 3

up vote 25 down vote accepted

Alternatively, you can use the Dingbats symbols from the pifont package. If you do not insist on a dashed line, TikZ can be avoided by using \dotfill.

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{pifont}
\usepackage{lipsum}
\begin{document}

\lipsum[11]

\noindent\dotfill
\ding{33}\dotfill
\raisebox{-0.25\baselineskip}{\ding{34}}\dotfill
\raisebox{-0.50\baselineskip}{\ding{35}}\dotfill

\lipsum[11]

\end{document}

enter image description here

Note, that the size of the dots of \dotfill scales with the font size. The skip after the scissors symbol can be removed with \unskip if you want wo get rid of it. I personally like the following:

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{pifont}
\usepackage{lipsum}

\newcommand{\cuthere}{%
\noindent
\raisebox{-2.8pt}[0pt][0.75\baselineskip]{\small\ding{34}}
\unskip{\tiny\dotfill}
}

\begin{document}

\lipsum[11]

\cuthere

\lipsum[11]

\end{document}

enter image description here

The alignment of the scissors symbol and the dotted rule and the spacing after the cut-line was done manual. On the other hand this approach is really simple.

EDIT (2012/09/10)

Adjust the \dotfill macro to get a dashed line instead of a dotted one. Here I simply used the hyphen symbol as dash:

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{pifont}
\usepackage{lipsum}

\makeatletter
\newcommand{\dashfill}{%
\leavevmode \cleaders \hb@xt@ .50em{\hss -\hss }\hfill \kern \z@
% original \dotfill macro:
% \leavevmode \cleaders \hb@xt@ .44em{\hss .\hss }\hfill \kern \z@
}
\makeatother

\newcommand{\cutheredashed}{%
\noindent
\raisebox{-0.5ex}[0pt][0.6\baselineskip]{\small\ding{34}}
\unskip{\tiny\dashfill}
}

\begin{document}

\lipsum[11]

\cutheredashed

\lipsum[11]

\end{document}

enter image description here

But that's getting a bit hackish now. If you are willing to spend so much effort on a line that will eventually be cut away Heiko's solution is probably cleaner.

share|improve this answer
add comment

Here the cutting lines are set by symbols of package marvosym. Because the cutting line chars contain already three dashes and fixed spaces, using \(c,x)leaders is a bit tricky. There should not be an additional space before or after a cutting line symbol inside the cutting line.

Because the line width is not a multiple of the cutting line symbol, the first line adds the remaining space at the left and right side of the cutting line.

The second line allows the cutting line to get a little outside the text width.

The third uses the other symbol set of package marvosym.

The fourth example horizontally scales the cutting symbols in the middle to fill the available space exactly.

\documentclass{article}
\usepackage{lipsum}
\usepackage{marvosym}
\usepackage{zref-savepos}
\usepackage{graphics}
\begin{document}

\noindent\lipsum[2]

\noindent
\zsaveposx{cut-a}%
\begingroup
  \hsize=\numexpr\zposx{cut-b}-\zposx{cut-a}\relax sp\relax
  \ifnum\hsize>0 %
    \rlap{%
      \sbox0{\Cutline}%
      \sbox2{\Cutright\null\Cutleft}%
      \linewidth=\dimexpr
          \numexpr(\hsize-\wd2-\dimexpr.5\wd0\relax)/\wd0\relax\wd0 %
          +\wd2\relax
      \hbox to \hsize{%
        \hfill
        \hbox to \linewidth{%
          \Cutright\cleaders\copy0\hfill\Cutleft
        }%
        \hfill
      }%
    }%
  \fi
  \hfill
\endgroup
\zsaveposx{cut-b}%

\noindent\lipsum[3]

noindent
\zsaveposx{Cut-a}%
\begingroup
  \hsize=\numexpr\zposx{Cut-b}-\zposx{Cut-a}\relax sp\relax
  \ifnum\hsize>0 %
    \rlap{%
      \sbox0{\Cutline}%
      \sbox2{\Cutright\null\Cutleft}%
      \linewidth=\dimexpr\numexpr(\hsize-\wd2)/\wd0\relax\wd0+\wd2\relax
      \hbox to \hsize{%
        \hss
        \hbox to \linewidth{%
          \Cutright\cleaders\copy0\hfill\Cutleft
        }%
        \hss
      }%
    }%  
  \fi   
  \hfill
\endgroup
\zsaveposx{Cut-b}%

\noindent\lipsum[4]

\noindent
\LeftScissors\cleaders\hbox{\CuttingLine}\hfill\RightScissors

\noindent\lipsum[5]

\newsavebox\kutbox
\noindent
\LeftScissors
\zsaveposx{kut-a}%
\begingroup
  \hsize=\numexpr\zposx{kut-b}-\zposx{kut-a}\relax sp\relax
  \ifnum\hsize>0 %
    \rlap{%
      \sbox\kutbox{\CuttingLine}%
      \linewidth=\numexpr\hsize/\wd\kutbox\relax\wd\kutbox
      \resizebox{\hsize}{\height}{%
        \hbox to \linewidth{\cleaders\copy\kutbox\hfill}%
      }%
    }%  
  \fi   
\endgroup
\hfill   
\zsaveposx{kut-b}%
\RightScissors

\noindent\lipsum[5]
\end{document}

Result

share|improve this answer
add comment

I have done this once before. What I did is something like the one below. There some more scissor symbols with the The Comprehensive LaTeX Symbol List. It is not very good but it does the job with a little tweak here and there.

\documentclass{article}

\usepackage{bbding}
\usepackage{lipsum}
\usepackage{tikz}

\begin{document}

\lipsum[1]

\noindent \ScissorHollowRight \hfill \tikz \draw [dashed] (0,0) -- (11.6,0);

\lipsum[2]

\end{document}

Extract from the output:

output

Update @alexurba gave me an idea with his use of the \dotfill command. We can define a command like \dashfill so that you can still get dashes instead of dots for your cut line. Below is my attempt.

\documentclass{article}

\usepackage[showframe]{geometry}
\usepackage{bbding}
\usepackage{lipsum}
\usepackage{tikz}

\newcommand*{\dashfill}{\leavevmode\cleaders\hbox{-}\hfill\kern0pt}
\newcommand{\cutline}{%
\noindent
\raisebox{-2.8pt}[0pt][0.5\baselineskip]{\ScissorHollowRight}\unskip{\dashfill}
}

\newcommand*{\Dashfill}{\tikz \draw [dashed] (0,0) -- (0.97\textwidth,0);}
\newcommand{\Cutline}{%
\noindent
\raisebox{-4pt}[0pt][0.5\baselineskip]{\small\ScissorHollowRight}\unskip{\Dashfill}
}

\begin{document}

\lipsum[1]

\cutline

\lipsum[2]

\Cutline

\lipsum[3]

\end{document}

Here is the output:

enter image description here

I have included the showframe option to the geometry package to show where the dashed lines stop. At this point, I don't have a way of saying \tikz \draw [dashed] (0,0) -- (end of text width,0); If somebody has an idea may be the command \Cutline can be made better.

Update (September 11, 2012) I am just adding the following code for closure to the TikZ possibilities for this problem. I put two of them here.

\documentclass{article}
\usepackage[showframe,margin=1in]{geometry}
\usepackage{bbding}
\usepackage{lipsum}
\usepackage{tikz}

\newlength{\sometext}
\settowidth{\sometext}{{\small\ScissorHollowRight} }

\newcommand{\Cutline}{%
\noindent
\raisebox{-4pt}[0pt][0.5\baselineskip]{\ScissorHollowRight}\unskip{\tikz \draw[dashed](0,0)--({\linewidth-\sometext},0);}
}

\begin{document}

\lipsum[1]

\Cutline

\lipsum[2]

\end{document}

Below is the other one. You need to run latex twice to set it right.

\documentclass{article}

\usepackage[showframe,margin=0.8in]{geometry}
\usepackage{bbding}
\usepackage{tikz}
\usepackage{lipsum}

\newcounter{dashlinecnt}
\renewcommand*{\thedashlinecnt}{%
  dashline-\the\value{dashlinecnt}%
}
\newcommand*{\dashedlinefill}{%
  \leavevmode
  \stepcounter{dashlinecnt}%
  \tikz[remember picture,overlay,inner sep=0pt]\node(\thedashlinecnt){};%
  \hfill
  \tikz[remember picture,overlay,inner sep=0pt]\draw[dashed](\thedashlinecnt) -- (0,0);%
}

\newcommand{\Cutline}{%
\noindent
\raisebox{-4pt}[0pt][0.5\baselineskip]{\ScissorHollowRight}\unskip{\dashedlinefill}
}

\begin{document}

\lipsum[1]

\Cutline

\lipsum[2]

\end{document}

Acknowledgements The last two pieces of codes came from the answers of Kanappan Sampath and Heiko from my post Make TikZ compute the x-coordinate of the margin.

Finally, I fully agree with alexurba's statement about a lot of fuss about a dashed line that has to be cut anyway. That gave me my fill of laugh this morning. I would prefer my first solution anytime just to get the problem done away with in a matter of seconds. But alexurba's first solution is the least hackish and gets the job done very satisfactorily. Let me just say that this enterprise made me learn a lot about TeX in general.

share|improve this answer
    
It is okay. I should have done it myself. –  hpesoj626 Sep 10 '12 at 4:52
add comment

Your Answer

 
discard

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.