Input words within a figure using tikz [duplicate]
This question already has an answer here:
TikZ Adding Text
1 answer
I want to draw this using tikz package of latex.
I already write down the code for that. But the problem is that how could I input the sentence Happing Now within the picture.
My code is
begin{frame}{Frame Title}
begin{figure}
centering
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5) to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{frame}
tikz-pgf overleaf
marked as duplicate by hpekristiansen, Stefan Pinnow, Sebastiano, Henri Menke
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 13 '18 at 1:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
add a comment |
This question already has an answer here:
TikZ Adding Text
1 answer
I want to draw this using tikz package of latex.
I already write down the code for that. But the problem is that how could I input the sentence Happing Now within the picture.
My code is
begin{frame}{Frame Title}
begin{figure}
centering
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5) to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{frame}
tikz-pgf overleaf
marked as duplicate by hpekristiansen, Stefan Pinnow, Sebastiano, Henri Menke
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 13 '18 at 1:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
1
palce anode
at the starting point of the arrow. Read A very minimal introduction to TikZ for more.
– nidhin
Dec 12 '18 at 18:50
please show us mwe (minimal working example), which produce your arrows.
– Zarko
Dec 12 '18 at 18:52
draw[thick][->] (2,1.5) node[anchor=east]{Happing Now} to (4,0.5);
– hpekristiansen
Dec 12 '18 at 18:56
@hpekristiansen: The possible duplicate question is about placing text at arbitrary positions, which would be used in this case as well (but would require specifying the coordinate twice). However, I think that that is different than this case as this is about placing text relative to a particulardraw
.
– Peter Grill
Dec 12 '18 at 19:07
add a comment |
This question already has an answer here:
TikZ Adding Text
1 answer
I want to draw this using tikz package of latex.
I already write down the code for that. But the problem is that how could I input the sentence Happing Now within the picture.
My code is
begin{frame}{Frame Title}
begin{figure}
centering
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5) to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{frame}
tikz-pgf overleaf
This question already has an answer here:
TikZ Adding Text
1 answer
I want to draw this using tikz package of latex.
I already write down the code for that. But the problem is that how could I input the sentence Happing Now within the picture.
My code is
begin{frame}{Frame Title}
begin{figure}
centering
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5) to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{frame}
This question already has an answer here:
TikZ Adding Text
1 answer
tikz-pgf overleaf
tikz-pgf overleaf
edited Dec 12 '18 at 18:52
nidhin
3,342927
3,342927
asked Dec 12 '18 at 18:45
Encipher
1925
1925
marked as duplicate by hpekristiansen, Stefan Pinnow, Sebastiano, Henri Menke
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 13 '18 at 1:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
marked as duplicate by hpekristiansen, Stefan Pinnow, Sebastiano, Henri Menke
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 13 '18 at 1:21
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
1
palce anode
at the starting point of the arrow. Read A very minimal introduction to TikZ for more.
– nidhin
Dec 12 '18 at 18:50
please show us mwe (minimal working example), which produce your arrows.
– Zarko
Dec 12 '18 at 18:52
draw[thick][->] (2,1.5) node[anchor=east]{Happing Now} to (4,0.5);
– hpekristiansen
Dec 12 '18 at 18:56
@hpekristiansen: The possible duplicate question is about placing text at arbitrary positions, which would be used in this case as well (but would require specifying the coordinate twice). However, I think that that is different than this case as this is about placing text relative to a particulardraw
.
– Peter Grill
Dec 12 '18 at 19:07
add a comment |
1
palce anode
at the starting point of the arrow. Read A very minimal introduction to TikZ for more.
– nidhin
Dec 12 '18 at 18:50
please show us mwe (minimal working example), which produce your arrows.
– Zarko
Dec 12 '18 at 18:52
draw[thick][->] (2,1.5) node[anchor=east]{Happing Now} to (4,0.5);
– hpekristiansen
Dec 12 '18 at 18:56
@hpekristiansen: The possible duplicate question is about placing text at arbitrary positions, which would be used in this case as well (but would require specifying the coordinate twice). However, I think that that is different than this case as this is about placing text relative to a particulardraw
.
– Peter Grill
Dec 12 '18 at 19:07
1
1
palce a
node
at the starting point of the arrow. Read A very minimal introduction to TikZ for more.– nidhin
Dec 12 '18 at 18:50
palce a
node
at the starting point of the arrow. Read A very minimal introduction to TikZ for more.– nidhin
Dec 12 '18 at 18:50
please show us mwe (minimal working example), which produce your arrows.
– Zarko
Dec 12 '18 at 18:52
please show us mwe (minimal working example), which produce your arrows.
– Zarko
Dec 12 '18 at 18:52
draw[thick][->] (2,1.5) node[anchor=east]{Happing Now} to (4,0.5);
– hpekristiansen
Dec 12 '18 at 18:56
draw[thick][->] (2,1.5) node[anchor=east]{Happing Now} to (4,0.5);
– hpekristiansen
Dec 12 '18 at 18:56
@hpekristiansen: The possible duplicate question is about placing text at arbitrary positions, which would be used in this case as well (but would require specifying the coordinate twice). However, I think that that is different than this case as this is about placing text relative to a particular
draw
.– Peter Grill
Dec 12 '18 at 19:07
@hpekristiansen: The possible duplicate question is about placing text at arbitrary positions, which would be used in this case as well (but would require specifying the coordinate twice). However, I think that that is different than this case as this is about placing text relative to a particular
draw
.– Peter Grill
Dec 12 '18 at 19:07
add a comment |
5 Answers
5
active
oldest
votes
You can place a node at the appropriate point, if you replace the to
syntax with a --
:
Notes:
- You don't need to use
for each option.
Code:
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0);
draw[thick, ->] (2,1.5) -- (4,0.5) node [pos=0, anchor=east] {Happening Now};
draw[thick, loosely dotted] (4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
You can put a node at the beginning of the upper arrow.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0) ;
draw[thick, ->] (2,1.5) node [anchor=east] {Happing Now} to (4,0.5);
draw[thick, loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
As suggested by @nidhin:
documentclass[tikz,border=0.5cm]{standalone}
begin{document}
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5)node[left]{Happing now} to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
Using one command as my previous answer. Don't use a to
path if you don't have different angles for in
and out
, just --
or edge
.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}[thick]
path[->] (0,0) edge (4,0) (2,1.5)node[label=left:Happening Now]{} edge (4,0.5) (4,0) edge[loosely dotted,-] (5,0);
end{tikzpicture}
end{document}
add a comment |
based on answer on the your previous question:
documentclass[12pt,a4paper]{article}
usepackage{tikz}
begin{document}
begin{figure}
centering
begin{tikzpicture}[thick]
draw[->] (0,0) edge (4,0)
(2,3) node[left] {Happing Now} -- (4,1);
draw[thick][loosely dotted] (4,0) -- (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{document}
I think you spelled "Happening Now" wrong? :-). There is a a reference to[![enter image description here][1]][1]
in the answer. I think you intended to delete that?
– Peter Grill
Dec 12 '18 at 19:11
@PeterGrill, thank you to pointing me on this mistake. I still have problems with new interface for loading images ... i delete it, hopefully now is all correct.
– Zarko
Dec 12 '18 at 20:04
add a comment |
5 Answers
5
active
oldest
votes
5 Answers
5
active
oldest
votes
active
oldest
votes
active
oldest
votes
You can place a node at the appropriate point, if you replace the to
syntax with a --
:
Notes:
- You don't need to use
for each option.
Code:
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0);
draw[thick, ->] (2,1.5) -- (4,0.5) node [pos=0, anchor=east] {Happening Now};
draw[thick, loosely dotted] (4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
You can place a node at the appropriate point, if you replace the to
syntax with a --
:
Notes:
- You don't need to use
for each option.
Code:
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0);
draw[thick, ->] (2,1.5) -- (4,0.5) node [pos=0, anchor=east] {Happening Now};
draw[thick, loosely dotted] (4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
You can place a node at the appropriate point, if you replace the to
syntax with a --
:
Notes:
- You don't need to use
for each option.
Code:
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0);
draw[thick, ->] (2,1.5) -- (4,0.5) node [pos=0, anchor=east] {Happening Now};
draw[thick, loosely dotted] (4,0) to (5,0);
end{tikzpicture}
end{document}
You can place a node at the appropriate point, if you replace the to
syntax with a --
:
Notes:
- You don't need to use
for each option.
Code:
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0);
draw[thick, ->] (2,1.5) -- (4,0.5) node [pos=0, anchor=east] {Happening Now};
draw[thick, loosely dotted] (4,0) to (5,0);
end{tikzpicture}
end{document}
answered Dec 12 '18 at 18:55
Peter Grill
164k25437748
164k25437748
add a comment |
add a comment |
You can put a node at the beginning of the upper arrow.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0) ;
draw[thick, ->] (2,1.5) node [anchor=east] {Happing Now} to (4,0.5);
draw[thick, loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
You can put a node at the beginning of the upper arrow.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0) ;
draw[thick, ->] (2,1.5) node [anchor=east] {Happing Now} to (4,0.5);
draw[thick, loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
You can put a node at the beginning of the upper arrow.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0) ;
draw[thick, ->] (2,1.5) node [anchor=east] {Happing Now} to (4,0.5);
draw[thick, loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
You can put a node at the beginning of the upper arrow.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}
draw[thick, ->] (0,0) to (4,0) ;
draw[thick, ->] (2,1.5) node [anchor=east] {Happing Now} to (4,0.5);
draw[thick, loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
answered Dec 12 '18 at 18:55
javadr
1,633313
1,633313
add a comment |
add a comment |
As suggested by @nidhin:
documentclass[tikz,border=0.5cm]{standalone}
begin{document}
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5)node[left]{Happing now} to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
As suggested by @nidhin:
documentclass[tikz,border=0.5cm]{standalone}
begin{document}
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5)node[left]{Happing now} to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
add a comment |
As suggested by @nidhin:
documentclass[tikz,border=0.5cm]{standalone}
begin{document}
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5)node[left]{Happing now} to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
As suggested by @nidhin:
documentclass[tikz,border=0.5cm]{standalone}
begin{document}
begin{tikzpicture}
draw[thick][->](0,0) to (4,0);
draw[thick][->](2,1.5)node[left]{Happing now} to (4,0.5);
draw[thick][loosely dotted](4,0) to (5,0);
end{tikzpicture}
end{document}
answered Dec 12 '18 at 18:56
Hafid Boukhoulda
1,9271516
1,9271516
add a comment |
add a comment |
Using one command as my previous answer. Don't use a to
path if you don't have different angles for in
and out
, just --
or edge
.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}[thick]
path[->] (0,0) edge (4,0) (2,1.5)node[label=left:Happening Now]{} edge (4,0.5) (4,0) edge[loosely dotted,-] (5,0);
end{tikzpicture}
end{document}
add a comment |
Using one command as my previous answer. Don't use a to
path if you don't have different angles for in
and out
, just --
or edge
.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}[thick]
path[->] (0,0) edge (4,0) (2,1.5)node[label=left:Happening Now]{} edge (4,0.5) (4,0) edge[loosely dotted,-] (5,0);
end{tikzpicture}
end{document}
add a comment |
Using one command as my previous answer. Don't use a to
path if you don't have different angles for in
and out
, just --
or edge
.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}[thick]
path[->] (0,0) edge (4,0) (2,1.5)node[label=left:Happening Now]{} edge (4,0.5) (4,0) edge[loosely dotted,-] (5,0);
end{tikzpicture}
end{document}
Using one command as my previous answer. Don't use a to
path if you don't have different angles for in
and out
, just --
or edge
.
documentclass{article}
usepackage{tikz}
begin{document}
begin{tikzpicture}[thick]
path[->] (0,0) edge (4,0) (2,1.5)node[label=left:Happening Now]{} edge (4,0.5) (4,0) edge[loosely dotted,-] (5,0);
end{tikzpicture}
end{document}
answered Dec 12 '18 at 19:31
AboAmmar
33.3k22882
33.3k22882
add a comment |
add a comment |
based on answer on the your previous question:
documentclass[12pt,a4paper]{article}
usepackage{tikz}
begin{document}
begin{figure}
centering
begin{tikzpicture}[thick]
draw[->] (0,0) edge (4,0)
(2,3) node[left] {Happing Now} -- (4,1);
draw[thick][loosely dotted] (4,0) -- (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{document}
I think you spelled "Happening Now" wrong? :-). There is a a reference to[![enter image description here][1]][1]
in the answer. I think you intended to delete that?
– Peter Grill
Dec 12 '18 at 19:11
@PeterGrill, thank you to pointing me on this mistake. I still have problems with new interface for loading images ... i delete it, hopefully now is all correct.
– Zarko
Dec 12 '18 at 20:04
add a comment |
based on answer on the your previous question:
documentclass[12pt,a4paper]{article}
usepackage{tikz}
begin{document}
begin{figure}
centering
begin{tikzpicture}[thick]
draw[->] (0,0) edge (4,0)
(2,3) node[left] {Happing Now} -- (4,1);
draw[thick][loosely dotted] (4,0) -- (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{document}
I think you spelled "Happening Now" wrong? :-). There is a a reference to[![enter image description here][1]][1]
in the answer. I think you intended to delete that?
– Peter Grill
Dec 12 '18 at 19:11
@PeterGrill, thank you to pointing me on this mistake. I still have problems with new interface for loading images ... i delete it, hopefully now is all correct.
– Zarko
Dec 12 '18 at 20:04
add a comment |
based on answer on the your previous question:
documentclass[12pt,a4paper]{article}
usepackage{tikz}
begin{document}
begin{figure}
centering
begin{tikzpicture}[thick]
draw[->] (0,0) edge (4,0)
(2,3) node[left] {Happing Now} -- (4,1);
draw[thick][loosely dotted] (4,0) -- (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{document}
based on answer on the your previous question:
documentclass[12pt,a4paper]{article}
usepackage{tikz}
begin{document}
begin{figure}
centering
begin{tikzpicture}[thick]
draw[->] (0,0) edge (4,0)
(2,3) node[left] {Happing Now} -- (4,1);
draw[thick][loosely dotted] (4,0) -- (5,0);
end{tikzpicture}
caption{Timeline}
label{fig:my_label1}
end{figure}
end{document}
edited Dec 12 '18 at 20:13
answered Dec 12 '18 at 18:57
Zarko
121k865158
121k865158
I think you spelled "Happening Now" wrong? :-). There is a a reference to[![enter image description here][1]][1]
in the answer. I think you intended to delete that?
– Peter Grill
Dec 12 '18 at 19:11
@PeterGrill, thank you to pointing me on this mistake. I still have problems with new interface for loading images ... i delete it, hopefully now is all correct.
– Zarko
Dec 12 '18 at 20:04
add a comment |
I think you spelled "Happening Now" wrong? :-). There is a a reference to[![enter image description here][1]][1]
in the answer. I think you intended to delete that?
– Peter Grill
Dec 12 '18 at 19:11
@PeterGrill, thank you to pointing me on this mistake. I still have problems with new interface for loading images ... i delete it, hopefully now is all correct.
– Zarko
Dec 12 '18 at 20:04
I think you spelled "Happening Now" wrong? :-). There is a a reference to
[![enter image description here][1]][1]
in the answer. I think you intended to delete that?– Peter Grill
Dec 12 '18 at 19:11
I think you spelled "Happening Now" wrong? :-). There is a a reference to
[![enter image description here][1]][1]
in the answer. I think you intended to delete that?– Peter Grill
Dec 12 '18 at 19:11
@PeterGrill, thank you to pointing me on this mistake. I still have problems with new interface for loading images ... i delete it, hopefully now is all correct.
– Zarko
Dec 12 '18 at 20:04
@PeterGrill, thank you to pointing me on this mistake. I still have problems with new interface for loading images ... i delete it, hopefully now is all correct.
– Zarko
Dec 12 '18 at 20:04
add a comment |
1
palce a
node
at the starting point of the arrow. Read A very minimal introduction to TikZ for more.– nidhin
Dec 12 '18 at 18:50
please show us mwe (minimal working example), which produce your arrows.
– Zarko
Dec 12 '18 at 18:52
draw[thick][->] (2,1.5) node[anchor=east]{Happing Now} to (4,0.5);
– hpekristiansen
Dec 12 '18 at 18:56
@hpekristiansen: The possible duplicate question is about placing text at arbitrary positions, which would be used in this case as well (but would require specifying the coordinate twice). However, I think that that is different than this case as this is about placing text relative to a particular
draw
.– Peter Grill
Dec 12 '18 at 19:07