How to adjust arrow head size of arrow-node?Rotate a node but not its content: the case of the ellipse decorationHow to define the default vertical distance between nodes?Numerical conditional within tikz keys?Why do I get an extra white page before my TikZ picture?TikZ: Drawing an arc from an intersection to an intersectionHow to prevent rounded and duplicated tick labels in pgfplots with fixed precision?Drawing rectilinear curves in Tikz, aka an Etch-a-Sketch drawingLine up nested tikz enviroments or how to get rid of themHow to draw a square and its diagonals with arrows?torn paper problem compile
Find the C-factor of a vote
Apply brace expansion in "reverse order"
What's the difference between a deep fryer and a chip pan?
Why tighten down in a criss-cross pattern?
Why do even high-end cameras often still include normal (non-cross-type) AF sensors?
Impossible darts scores
Relationship between woodwinds and brass in a marching band?
How would modern naval warfare have to have developed differently for battleships to still be relevant in the 21st century?
Interaction between Leyline of Anticipation and Teferi, Time Raveler
Inaccessible base class despite friendship
How to draw this center trajectory of rolling ball?
What does "play with your toy’s toys" mean?
Why does the Saturn V have standalone inter-stage rings?
Can there be an UN resolution to remove a country from the UNSC?
How to get cool night-vision without lame drawbacks?
JSON selector class in Python
Does this Wild Magic result affect the sorcerer or just other creatures?
What exactly is the 'online' in OLAP and OLTP?
What did River say when she woke from her proto-comatose state?
Parameterize chained calls to a utility program in Bash
How to remove this component from PCB
Unusual mail headers, evidence of an attempted attack. Have I been pwned?
If I wouldn't want to read the story, is writing it still a good idea?
Count All Possible Unique Combinations of Letters in a Word
How to adjust arrow head size of arrow-node?
Rotate a node but not its content: the case of the ellipse decorationHow to define the default vertical distance between nodes?Numerical conditional within tikz keys?Why do I get an extra white page before my TikZ picture?TikZ: Drawing an arc from an intersection to an intersectionHow to prevent rounded and duplicated tick labels in pgfplots with fixed precision?Drawing rectilinear curves in Tikz, aka an Etch-a-Sketch drawingLine up nested tikz enviroments or how to get rid of themHow to draw a square and its diagonals with arrows?torn paper problem compile
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I am trying to use single arrow
node from shapes.arrows
TikZ library. The problem is with the proper adjustment of the arrow tip span - with the argument single arrow head extend
.
MWE:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=0,minimum width=2cm,minimum height=2cm,single arrow head extend=0.2cm] ;
endtikzpicture
enddocument
tikz-pgf tikz-node tikz-shape
add a comment |
I am trying to use single arrow
node from shapes.arrows
TikZ library. The problem is with the proper adjustment of the arrow tip span - with the argument single arrow head extend
.
MWE:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=0,minimum width=2cm,minimum height=2cm,single arrow head extend=0.2cm] ;
endtikzpicture
enddocument
tikz-pgf tikz-node tikz-shape
add a comment |
I am trying to use single arrow
node from shapes.arrows
TikZ library. The problem is with the proper adjustment of the arrow tip span - with the argument single arrow head extend
.
MWE:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=0,minimum width=2cm,minimum height=2cm,single arrow head extend=0.2cm] ;
endtikzpicture
enddocument
tikz-pgf tikz-node tikz-shape
I am trying to use single arrow
node from shapes.arrows
TikZ library. The problem is with the proper adjustment of the arrow tip span - with the argument single arrow head extend
.
MWE:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=0,minimum width=2cm,minimum height=2cm,single arrow head extend=0.2cm] ;
endtikzpicture
enddocument
tikz-pgf tikz-node tikz-shape
tikz-pgf tikz-node tikz-shape
asked Jun 13 at 8:17
forrestforrest
492210
492210
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
Combining minimum width
with single arrow head extend
seems buggy. Use inner sep
instead to define the inner width:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west] (a) ;
draw[|<->|, purple, ultra thin] (0,0) -- (4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
endtikzpicture
enddocument
Update: the final size of the arrow could still be larger than intended, as caused by the finite line width and default miter
line join option, illustrated below.
documentclass[border=1cm]standalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
tikzsetsamplearrow/.style=single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west,line width=5mm
node [samplearrow, orange!50] (a) ;
node [samplearrow, gray,line join=round] (b) ;
draw[|<->|, purple, ultra thin] (0.5,0) -- ++(4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
draw[|<->|, ultra thin] (0,1) -- ++(0,0.5) node [midway, above, sloped] tiny 5 mm;
draw[|<->|, ultra thin] (0,0) -- (0.5,0) node [pos=0, left, sloped] tiny 5 mm;
draw[<-,orange] (a.before tip) -- ++(-0.2,0) node[left] tiny miter;
endtikzpicture
enddocument
This could be solved by subtracting the line width from both the inner sep
and minimum height
(e.g. inner sep=1cm-0.4pt
for the default case of using a thin
line), and by setting line join
to round
(as illustrated in gray) or bevel
.
If this node is aligned to the rectangular node then it is visible the difference between the sizes of these nodes - it equals one width of the line.
– forrest
Jun 14 at 7:27
1
@forrest Yes, there are actually two reasons why the arrow does not fit the rectangle. One is, as you mentioned, the finite line width (which increases both the width and length of the arrow). The other is the effect of themiter
line join. I'll update the answer with a fat arrow to show the effect of both. The former could be solved by subtracting the line width (0.4pt
for the defaultthin
line), the latter by switching to around
orbevel
line join.
– JJM Driessen
Jun 14 at 8:58
add a comment |
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',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f495590%2fhow-to-adjust-arrow-head-size-of-arrow-node%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Combining minimum width
with single arrow head extend
seems buggy. Use inner sep
instead to define the inner width:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west] (a) ;
draw[|<->|, purple, ultra thin] (0,0) -- (4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
endtikzpicture
enddocument
Update: the final size of the arrow could still be larger than intended, as caused by the finite line width and default miter
line join option, illustrated below.
documentclass[border=1cm]standalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
tikzsetsamplearrow/.style=single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west,line width=5mm
node [samplearrow, orange!50] (a) ;
node [samplearrow, gray,line join=round] (b) ;
draw[|<->|, purple, ultra thin] (0.5,0) -- ++(4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
draw[|<->|, ultra thin] (0,1) -- ++(0,0.5) node [midway, above, sloped] tiny 5 mm;
draw[|<->|, ultra thin] (0,0) -- (0.5,0) node [pos=0, left, sloped] tiny 5 mm;
draw[<-,orange] (a.before tip) -- ++(-0.2,0) node[left] tiny miter;
endtikzpicture
enddocument
This could be solved by subtracting the line width from both the inner sep
and minimum height
(e.g. inner sep=1cm-0.4pt
for the default case of using a thin
line), and by setting line join
to round
(as illustrated in gray) or bevel
.
If this node is aligned to the rectangular node then it is visible the difference between the sizes of these nodes - it equals one width of the line.
– forrest
Jun 14 at 7:27
1
@forrest Yes, there are actually two reasons why the arrow does not fit the rectangle. One is, as you mentioned, the finite line width (which increases both the width and length of the arrow). The other is the effect of themiter
line join. I'll update the answer with a fat arrow to show the effect of both. The former could be solved by subtracting the line width (0.4pt
for the defaultthin
line), the latter by switching to around
orbevel
line join.
– JJM Driessen
Jun 14 at 8:58
add a comment |
Combining minimum width
with single arrow head extend
seems buggy. Use inner sep
instead to define the inner width:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west] (a) ;
draw[|<->|, purple, ultra thin] (0,0) -- (4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
endtikzpicture
enddocument
Update: the final size of the arrow could still be larger than intended, as caused by the finite line width and default miter
line join option, illustrated below.
documentclass[border=1cm]standalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
tikzsetsamplearrow/.style=single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west,line width=5mm
node [samplearrow, orange!50] (a) ;
node [samplearrow, gray,line join=round] (b) ;
draw[|<->|, purple, ultra thin] (0.5,0) -- ++(4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
draw[|<->|, ultra thin] (0,1) -- ++(0,0.5) node [midway, above, sloped] tiny 5 mm;
draw[|<->|, ultra thin] (0,0) -- (0.5,0) node [pos=0, left, sloped] tiny 5 mm;
draw[<-,orange] (a.before tip) -- ++(-0.2,0) node[left] tiny miter;
endtikzpicture
enddocument
This could be solved by subtracting the line width from both the inner sep
and minimum height
(e.g. inner sep=1cm-0.4pt
for the default case of using a thin
line), and by setting line join
to round
(as illustrated in gray) or bevel
.
If this node is aligned to the rectangular node then it is visible the difference between the sizes of these nodes - it equals one width of the line.
– forrest
Jun 14 at 7:27
1
@forrest Yes, there are actually two reasons why the arrow does not fit the rectangle. One is, as you mentioned, the finite line width (which increases both the width and length of the arrow). The other is the effect of themiter
line join. I'll update the answer with a fat arrow to show the effect of both. The former could be solved by subtracting the line width (0.4pt
for the defaultthin
line), the latter by switching to around
orbevel
line join.
– JJM Driessen
Jun 14 at 8:58
add a comment |
Combining minimum width
with single arrow head extend
seems buggy. Use inner sep
instead to define the inner width:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west] (a) ;
draw[|<->|, purple, ultra thin] (0,0) -- (4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
endtikzpicture
enddocument
Update: the final size of the arrow could still be larger than intended, as caused by the finite line width and default miter
line join option, illustrated below.
documentclass[border=1cm]standalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
tikzsetsamplearrow/.style=single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west,line width=5mm
node [samplearrow, orange!50] (a) ;
node [samplearrow, gray,line join=round] (b) ;
draw[|<->|, purple, ultra thin] (0.5,0) -- ++(4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
draw[|<->|, ultra thin] (0,1) -- ++(0,0.5) node [midway, above, sloped] tiny 5 mm;
draw[|<->|, ultra thin] (0,0) -- (0.5,0) node [pos=0, left, sloped] tiny 5 mm;
draw[<-,orange] (a.before tip) -- ++(-0.2,0) node[left] tiny miter;
endtikzpicture
enddocument
This could be solved by subtracting the line width from both the inner sep
and minimum height
(e.g. inner sep=1cm-0.4pt
for the default case of using a thin
line), and by setting line join
to round
(as illustrated in gray) or bevel
.
Combining minimum width
with single arrow head extend
seems buggy. Use inner sep
instead to define the inner width:
documentclassstandalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
node [single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west] (a) ;
draw[|<->|, purple, ultra thin] (0,0) -- (4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
endtikzpicture
enddocument
Update: the final size of the arrow could still be larger than intended, as caused by the finite line width and default miter
line join option, illustrated below.
documentclass[border=1cm]standalone
usepackagetikz
usetikzlibraryshapes.arrows
begindocument
begintikzpicture
tikzsetsamplearrow/.style=single arrow,draw,inner sep=1cm,minimum height=4cm, single arrow head extend=0.8cm,anchor=west,line width=5mm
node [samplearrow, orange!50] (a) ;
node [samplearrow, gray,line join=round] (b) ;
draw[|<->|, purple, ultra thin] (0.5,0) -- ++(4,0) node [midway, above, sloped] tiny 4 cm;
draw[|<->|, red, ultra thin] (0,0) -- (0,1) node [midway, above, sloped] tiny 1 cm;
draw[|<->|, blue, ultra thin] (a.before head) -- ++(0,0.8) node [midway, above, sloped] tiny 0.8 cm;
draw[|<->|, ultra thin] (0,1) -- ++(0,0.5) node [midway, above, sloped] tiny 5 mm;
draw[|<->|, ultra thin] (0,0) -- (0.5,0) node [pos=0, left, sloped] tiny 5 mm;
draw[<-,orange] (a.before tip) -- ++(-0.2,0) node[left] tiny miter;
endtikzpicture
enddocument
This could be solved by subtracting the line width from both the inner sep
and minimum height
(e.g. inner sep=1cm-0.4pt
for the default case of using a thin
line), and by setting line join
to round
(as illustrated in gray) or bevel
.
edited Jun 14 at 9:18
answered Jun 13 at 9:12
JJM DriessenJJM Driessen
676415
676415
If this node is aligned to the rectangular node then it is visible the difference between the sizes of these nodes - it equals one width of the line.
– forrest
Jun 14 at 7:27
1
@forrest Yes, there are actually two reasons why the arrow does not fit the rectangle. One is, as you mentioned, the finite line width (which increases both the width and length of the arrow). The other is the effect of themiter
line join. I'll update the answer with a fat arrow to show the effect of both. The former could be solved by subtracting the line width (0.4pt
for the defaultthin
line), the latter by switching to around
orbevel
line join.
– JJM Driessen
Jun 14 at 8:58
add a comment |
If this node is aligned to the rectangular node then it is visible the difference between the sizes of these nodes - it equals one width of the line.
– forrest
Jun 14 at 7:27
1
@forrest Yes, there are actually two reasons why the arrow does not fit the rectangle. One is, as you mentioned, the finite line width (which increases both the width and length of the arrow). The other is the effect of themiter
line join. I'll update the answer with a fat arrow to show the effect of both. The former could be solved by subtracting the line width (0.4pt
for the defaultthin
line), the latter by switching to around
orbevel
line join.
– JJM Driessen
Jun 14 at 8:58
If this node is aligned to the rectangular node then it is visible the difference between the sizes of these nodes - it equals one width of the line.
– forrest
Jun 14 at 7:27
If this node is aligned to the rectangular node then it is visible the difference between the sizes of these nodes - it equals one width of the line.
– forrest
Jun 14 at 7:27
1
1
@forrest Yes, there are actually two reasons why the arrow does not fit the rectangle. One is, as you mentioned, the finite line width (which increases both the width and length of the arrow). The other is the effect of the
miter
line join. I'll update the answer with a fat arrow to show the effect of both. The former could be solved by subtracting the line width (0.4pt
for the default thin
line), the latter by switching to a round
or bevel
line join.– JJM Driessen
Jun 14 at 8:58
@forrest Yes, there are actually two reasons why the arrow does not fit the rectangle. One is, as you mentioned, the finite line width (which increases both the width and length of the arrow). The other is the effect of the
miter
line join. I'll update the answer with a fat arrow to show the effect of both. The former could be solved by subtracting the line width (0.4pt
for the default thin
line), the latter by switching to a round
or bevel
line join.– JJM Driessen
Jun 14 at 8:58
add a comment |
Thanks for contributing an answer to TeX - LaTeX Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f495590%2fhow-to-adjust-arrow-head-size-of-arrow-node%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown