3

How do I form a really big, thick arrow with tikz?

In the following, the shaft of the arrow is too short.

\documentclass[12pt]{article}
\usepackage{tikz}
\usetikzlibrary{arrows.meta}

\begin{document}

\begin{tikzpicture}
\draw[->, line width=5mm] (0,0) -- (1,0);
\end{tikzpicture}

\end{document}

Bad big arrow I want an arrow that has quite thick lines for its shaft and head, whose head is larger, and whose shaft is a couple inches long.

I've looked in the manual and here and am now completely befuddled as to how to modify this.

8
  • \begin{tikzpicture}[scale=5] could help
    – user31729
    Commented Jan 4, 2018 at 21:36
  • @Christian Hupfer: OK, that makes the arrow longer. Now how do I make the head larger, too?
    – murray
    Commented Jan 4, 2018 at 21:43
  • \draw (0,0) -- (1,0); makes a line that is 1cm long, as the default unit vector is 1cm, and that length includes the arrow tip. If you want it 2 inches long, \draw (0,0) -- (2in,0);. Commented Jan 4, 2018 at 21:50
  • I'm just not comprehending the interaction among scale, width, and the coordinates.
    – murray
    Commented Jan 4, 2018 at 21:50
  • scale=2 is the same as multiplying all coordinates by 2, so that doesn't change the line width. As mentioned above, a unit length is 1cm, so in your example the arrow (including tip) is 1cm long, with a line that is 5mm wide. Commented Jan 4, 2018 at 22:01

2 Answers 2

7

Change the length in your code to increase shaft length.

\documentclass[12pt]{article}
\usepackage{tikz}
\usetikzlibrary{arrows.meta}

\begin{document}

\begin{tikzpicture}
\draw[->, line width=5mm] (0,0) -- (4,0);
\end{tikzpicture}

\end{document}

enter image description here

To explain some stuff rather shortly that you seem to not understand:

The units TikZ is using (if you don't explicitly specify one) are centimetre. So (0,0) starts at coordinates (0cm, 0cm) and the endpoint (20,0) would be at the coordinates (20cm, 0cm) resulting in a 20 cm long arrow.

The line width doesn't change the length. It only affects the thickness of the arrow.

An additional scale would enlarge the result (like after everything is drawn using the given sizes) by the factor given as argument. So scale=5 would make the result 5 times bigger in all dimensions.

7
  • I want it MUCH bigger. This is for a directional sign in a building!
    – murray
    Commented Jan 4, 2018 at 21:50
  • @murray If you want it bigger, just change the coordinates and line width! \draw [->, line width=5cm] (0,0) -- (20, 0); Commented Jan 4, 2018 at 21:52
  • @TorbjørnT.: No, using second coordinates like (20,0) extends the arrow much longer than the paper width!
    – murray
    Commented Jan 4, 2018 at 21:54
  • @murray That was just an example, my point was that you just have to change the line width and the second coordinate so that you get a sufficiently large arrow. Commented Jan 4, 2018 at 21:58
  • @murray: Are you trolling? If 20 is too long make it shorter by decreasing the number. Commented Jan 4, 2018 at 22:00
4

You need to supply the scale option to the arrow. For example if you want the old arrow with arrows.meta library you can do it via

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{arrows.meta}
\begin{document}
\begin{tikzpicture}
\draw[-{Classical TikZ Rightarrow[scale=5]}, line width=5mm] (0,0) -- (3,0);
\end{tikzpicture}
\end{document}

But this would look ugly. Choose a better arrow head from the TikZ manual section 16.5. The other options are given in Section 16.

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .