Avoiding jumping nodes in a tree with forest and beamerAvoiding jumping frames in beamerExporting animation...

Finding ratio of the area of triangles

Am I using the wrong word all along?

What happens if a wizard reaches level 20 but has no 3rd-level spells that they can use with the Signature Spells feature?

What is Crew Dragon approaching in this picture?

'A' vs 'an' in newspaper article

Auto Insert date into Notepad

How to prepare vegetables for a sandwich that can last for several days in a fridge?

c++ How can I make an algorithm for finding variations of a set without repetition (i.e. n elements, choose k)?

I am on the US no-fly list. What can I do in order to be allowed on flights which go through US airspace?

Connecting top and bottom of adjacent circles

Metadata API deployments are failing in Spring '19

How would an AI self awareness kill switch work?

Eww, those bytes are gross

Obtaining a matrix of complex values from associations giving the real and imaginary parts of each element?

Has the Isbell–Freyd criterion ever been used to check that a category is concretisable?

What's the purpose of these copper coils with resitors inside them in A Yamaha RX-V396RDS amplifier?

Do my Windows system binaries contain sensitive information?

Table enclosed in curly brackets

LTSpice: When running a linear AC simulation, how to view the voltage ratio between two voltages?

What was the population of late Pre-Islamic Arabia and the population of Arabic speakers before Islam?

How large should photos on my blog be?

Do objects in the public view need licencing?

If I delete my router's history can my ISP still provide it to my parents?

ip vs ifconfig commands pros and cons



Avoiding jumping nodes in a tree with forest and beamer


Avoiding jumping frames in beamerExporting animation created with animate packageAvoiding jumping frames in beamerRelating tree nodes in forest to content in a tablesetting all nodes of a tree in italics with forestImprove Tree Aspect [Forest]Decrease distance between nodes in tree using ForestLine angles and spaces in forest treeForest linguistics tree sideways/rotatedAligning nodes at the top with forestGetting straight lines with empty nodes in forestforest tree nodes













2















There is something in the manual about avoiding jumps and it is explained here Avoiding jumping frames in beamer as well. But I have maybe a different situation in trees. Is there a way to avoid the jumps between the two figures in the following code?



documentclass{beamer}

usepackage{forest}

% http://tex.stackexchange.com/questions/167690/presenting-a-forest-tree-from-bottom-to-top-in-beamer
% showing and hiding nodes and edges in forest
tikzset{
invisible/.style={opacity=0,text opacity=0},
visible on/.style={alt=#1{}{invisible}},
alt/.code args={<#1>#2#3}{%
alt<#1>{pgfkeysalso{#2}}{pgfkeysalso{#3}} % pgfkeysalso doesn't change the path
},
}
forestset{
visible on/.style={
for tree={
/tikz/visible on={#1},
edge={/tikz/visible on={#1}}}}}

newcommand{sliste}[1]{%
mbox{%
$leftlanglembox{upshapescshape #1}rightrangle$}%
}

% specification for all trees, "default preamble" appends to existing specification.
% The version with apostrophe replaces it.
forestset{default preamble'={
for tree={align=center,parent anchor=south, child anchor=north,anchor=north,base=bottom},
before drawing tree={
sort by=y,
for min={tree}{baseline}
}
}}


forestset{
declare dimen={child anchor yshift}{0pt},
adjust childrens child anchors/.style={
if n children>=2{
before packing={
tempdima/.max={max_y}{children},
for children={
child anchor yshift=tempdima()-max_y()
},
}
}{}
},
default preamble={
for tree={
edge path'={(!u.parent anchor)--([yshift=forestoption{child anchor yshift}].child anchor)},
adjust childrens child anchors
}
},
}


begin{document}

frame{

begin{forest}
[S
[alt<1>{XP}{NP}]
[alt<1>{YP}{NP}]
[alt<1>{ZP}{NP}]
[ldots, visible on=<1>]
[{alt<1>{H}{V} sliste{ alt<1>{XP}{NP}, alt<1>{YP}{NP}, alt<1>{ZP}{NP}visible<1>{, ldots} }}
[{V sliste{ NP, NP, NP }}, visible on=<1>,no edge]]]
end{forest}

pause

}


end{document}


Edit: The animated gif:
enter image description here










share|improve this question

























  • According to what I find your frame does not jump. Could you please add begin{tikzpicture}[overlay,remember picture] draw[red] (current page.west) -- (current page.east); end{tikzpicture} just before pause, compile 3 times and tell me if you really see a jump.

    – marmot
    6 hours ago











  • Yes, if you hold a piece of paper at NP and check with ZP after advancing to the next slide, you see that ZP starts at a different place from NP.

    – Stefan Müller
    6 hours ago











  • I just played the thing on full screen mode in acroread and have a hard time confirming what you are saying. Apart from the obvious observation that the characters used in the tree have different widths I cannot see any jump. Please consider clarifying which jumps you are talking about.

    – marmot
    6 hours ago











  • It jumps. If you hold a piece of paper at the N of NP that was a ZP on slide 1 you see that the NP does not start at the position of the ZP. Also the tree edges are at different places.

    – Stefan Müller
    5 hours ago











  • All I can say is that I am unable to reproduce this on my TeXLive 2018 installation when I view the result with acroread. You could use convert -density 300 -delay 4 -loop 0 -alpha remove multipage.pdf animated.gif (see tex.stackexchange.com/a/136919/121799) in order to produce an animated gif that you can add to your question.

    – marmot
    5 hours ago
















2















There is something in the manual about avoiding jumps and it is explained here Avoiding jumping frames in beamer as well. But I have maybe a different situation in trees. Is there a way to avoid the jumps between the two figures in the following code?



documentclass{beamer}

usepackage{forest}

% http://tex.stackexchange.com/questions/167690/presenting-a-forest-tree-from-bottom-to-top-in-beamer
% showing and hiding nodes and edges in forest
tikzset{
invisible/.style={opacity=0,text opacity=0},
visible on/.style={alt=#1{}{invisible}},
alt/.code args={<#1>#2#3}{%
alt<#1>{pgfkeysalso{#2}}{pgfkeysalso{#3}} % pgfkeysalso doesn't change the path
},
}
forestset{
visible on/.style={
for tree={
/tikz/visible on={#1},
edge={/tikz/visible on={#1}}}}}

newcommand{sliste}[1]{%
mbox{%
$leftlanglembox{upshapescshape #1}rightrangle$}%
}

% specification for all trees, "default preamble" appends to existing specification.
% The version with apostrophe replaces it.
forestset{default preamble'={
for tree={align=center,parent anchor=south, child anchor=north,anchor=north,base=bottom},
before drawing tree={
sort by=y,
for min={tree}{baseline}
}
}}


forestset{
declare dimen={child anchor yshift}{0pt},
adjust childrens child anchors/.style={
if n children>=2{
before packing={
tempdima/.max={max_y}{children},
for children={
child anchor yshift=tempdima()-max_y()
},
}
}{}
},
default preamble={
for tree={
edge path'={(!u.parent anchor)--([yshift=forestoption{child anchor yshift}].child anchor)},
adjust childrens child anchors
}
},
}


begin{document}

frame{

begin{forest}
[S
[alt<1>{XP}{NP}]
[alt<1>{YP}{NP}]
[alt<1>{ZP}{NP}]
[ldots, visible on=<1>]
[{alt<1>{H}{V} sliste{ alt<1>{XP}{NP}, alt<1>{YP}{NP}, alt<1>{ZP}{NP}visible<1>{, ldots} }}
[{V sliste{ NP, NP, NP }}, visible on=<1>,no edge]]]
end{forest}

pause

}


end{document}


Edit: The animated gif:
enter image description here










share|improve this question

























  • According to what I find your frame does not jump. Could you please add begin{tikzpicture}[overlay,remember picture] draw[red] (current page.west) -- (current page.east); end{tikzpicture} just before pause, compile 3 times and tell me if you really see a jump.

    – marmot
    6 hours ago











  • Yes, if you hold a piece of paper at NP and check with ZP after advancing to the next slide, you see that ZP starts at a different place from NP.

    – Stefan Müller
    6 hours ago











  • I just played the thing on full screen mode in acroread and have a hard time confirming what you are saying. Apart from the obvious observation that the characters used in the tree have different widths I cannot see any jump. Please consider clarifying which jumps you are talking about.

    – marmot
    6 hours ago











  • It jumps. If you hold a piece of paper at the N of NP that was a ZP on slide 1 you see that the NP does not start at the position of the ZP. Also the tree edges are at different places.

    – Stefan Müller
    5 hours ago











  • All I can say is that I am unable to reproduce this on my TeXLive 2018 installation when I view the result with acroread. You could use convert -density 300 -delay 4 -loop 0 -alpha remove multipage.pdf animated.gif (see tex.stackexchange.com/a/136919/121799) in order to produce an animated gif that you can add to your question.

    – marmot
    5 hours ago














2












2








2








There is something in the manual about avoiding jumps and it is explained here Avoiding jumping frames in beamer as well. But I have maybe a different situation in trees. Is there a way to avoid the jumps between the two figures in the following code?



documentclass{beamer}

usepackage{forest}

% http://tex.stackexchange.com/questions/167690/presenting-a-forest-tree-from-bottom-to-top-in-beamer
% showing and hiding nodes and edges in forest
tikzset{
invisible/.style={opacity=0,text opacity=0},
visible on/.style={alt=#1{}{invisible}},
alt/.code args={<#1>#2#3}{%
alt<#1>{pgfkeysalso{#2}}{pgfkeysalso{#3}} % pgfkeysalso doesn't change the path
},
}
forestset{
visible on/.style={
for tree={
/tikz/visible on={#1},
edge={/tikz/visible on={#1}}}}}

newcommand{sliste}[1]{%
mbox{%
$leftlanglembox{upshapescshape #1}rightrangle$}%
}

% specification for all trees, "default preamble" appends to existing specification.
% The version with apostrophe replaces it.
forestset{default preamble'={
for tree={align=center,parent anchor=south, child anchor=north,anchor=north,base=bottom},
before drawing tree={
sort by=y,
for min={tree}{baseline}
}
}}


forestset{
declare dimen={child anchor yshift}{0pt},
adjust childrens child anchors/.style={
if n children>=2{
before packing={
tempdima/.max={max_y}{children},
for children={
child anchor yshift=tempdima()-max_y()
},
}
}{}
},
default preamble={
for tree={
edge path'={(!u.parent anchor)--([yshift=forestoption{child anchor yshift}].child anchor)},
adjust childrens child anchors
}
},
}


begin{document}

frame{

begin{forest}
[S
[alt<1>{XP}{NP}]
[alt<1>{YP}{NP}]
[alt<1>{ZP}{NP}]
[ldots, visible on=<1>]
[{alt<1>{H}{V} sliste{ alt<1>{XP}{NP}, alt<1>{YP}{NP}, alt<1>{ZP}{NP}visible<1>{, ldots} }}
[{V sliste{ NP, NP, NP }}, visible on=<1>,no edge]]]
end{forest}

pause

}


end{document}


Edit: The animated gif:
enter image description here










share|improve this question
















There is something in the manual about avoiding jumps and it is explained here Avoiding jumping frames in beamer as well. But I have maybe a different situation in trees. Is there a way to avoid the jumps between the two figures in the following code?



documentclass{beamer}

usepackage{forest}

% http://tex.stackexchange.com/questions/167690/presenting-a-forest-tree-from-bottom-to-top-in-beamer
% showing and hiding nodes and edges in forest
tikzset{
invisible/.style={opacity=0,text opacity=0},
visible on/.style={alt=#1{}{invisible}},
alt/.code args={<#1>#2#3}{%
alt<#1>{pgfkeysalso{#2}}{pgfkeysalso{#3}} % pgfkeysalso doesn't change the path
},
}
forestset{
visible on/.style={
for tree={
/tikz/visible on={#1},
edge={/tikz/visible on={#1}}}}}

newcommand{sliste}[1]{%
mbox{%
$leftlanglembox{upshapescshape #1}rightrangle$}%
}

% specification for all trees, "default preamble" appends to existing specification.
% The version with apostrophe replaces it.
forestset{default preamble'={
for tree={align=center,parent anchor=south, child anchor=north,anchor=north,base=bottom},
before drawing tree={
sort by=y,
for min={tree}{baseline}
}
}}


forestset{
declare dimen={child anchor yshift}{0pt},
adjust childrens child anchors/.style={
if n children>=2{
before packing={
tempdima/.max={max_y}{children},
for children={
child anchor yshift=tempdima()-max_y()
},
}
}{}
},
default preamble={
for tree={
edge path'={(!u.parent anchor)--([yshift=forestoption{child anchor yshift}].child anchor)},
adjust childrens child anchors
}
},
}


begin{document}

frame{

begin{forest}
[S
[alt<1>{XP}{NP}]
[alt<1>{YP}{NP}]
[alt<1>{ZP}{NP}]
[ldots, visible on=<1>]
[{alt<1>{H}{V} sliste{ alt<1>{XP}{NP}, alt<1>{YP}{NP}, alt<1>{ZP}{NP}visible<1>{, ldots} }}
[{V sliste{ NP, NP, NP }}, visible on=<1>,no edge]]]
end{forest}

pause

}


end{document}


Edit: The animated gif:
enter image description here







beamer forest linguistics






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited 4 hours ago







Stefan Müller

















asked 13 hours ago









Stefan MüllerStefan Müller

3,05421446




3,05421446













  • According to what I find your frame does not jump. Could you please add begin{tikzpicture}[overlay,remember picture] draw[red] (current page.west) -- (current page.east); end{tikzpicture} just before pause, compile 3 times and tell me if you really see a jump.

    – marmot
    6 hours ago











  • Yes, if you hold a piece of paper at NP and check with ZP after advancing to the next slide, you see that ZP starts at a different place from NP.

    – Stefan Müller
    6 hours ago











  • I just played the thing on full screen mode in acroread and have a hard time confirming what you are saying. Apart from the obvious observation that the characters used in the tree have different widths I cannot see any jump. Please consider clarifying which jumps you are talking about.

    – marmot
    6 hours ago











  • It jumps. If you hold a piece of paper at the N of NP that was a ZP on slide 1 you see that the NP does not start at the position of the ZP. Also the tree edges are at different places.

    – Stefan Müller
    5 hours ago











  • All I can say is that I am unable to reproduce this on my TeXLive 2018 installation when I view the result with acroread. You could use convert -density 300 -delay 4 -loop 0 -alpha remove multipage.pdf animated.gif (see tex.stackexchange.com/a/136919/121799) in order to produce an animated gif that you can add to your question.

    – marmot
    5 hours ago



















  • According to what I find your frame does not jump. Could you please add begin{tikzpicture}[overlay,remember picture] draw[red] (current page.west) -- (current page.east); end{tikzpicture} just before pause, compile 3 times and tell me if you really see a jump.

    – marmot
    6 hours ago











  • Yes, if you hold a piece of paper at NP and check with ZP after advancing to the next slide, you see that ZP starts at a different place from NP.

    – Stefan Müller
    6 hours ago











  • I just played the thing on full screen mode in acroread and have a hard time confirming what you are saying. Apart from the obvious observation that the characters used in the tree have different widths I cannot see any jump. Please consider clarifying which jumps you are talking about.

    – marmot
    6 hours ago











  • It jumps. If you hold a piece of paper at the N of NP that was a ZP on slide 1 you see that the NP does not start at the position of the ZP. Also the tree edges are at different places.

    – Stefan Müller
    5 hours ago











  • All I can say is that I am unable to reproduce this on my TeXLive 2018 installation when I view the result with acroread. You could use convert -density 300 -delay 4 -loop 0 -alpha remove multipage.pdf animated.gif (see tex.stackexchange.com/a/136919/121799) in order to produce an animated gif that you can add to your question.

    – marmot
    5 hours ago

















According to what I find your frame does not jump. Could you please add begin{tikzpicture}[overlay,remember picture] draw[red] (current page.west) -- (current page.east); end{tikzpicture} just before pause, compile 3 times and tell me if you really see a jump.

– marmot
6 hours ago





According to what I find your frame does not jump. Could you please add begin{tikzpicture}[overlay,remember picture] draw[red] (current page.west) -- (current page.east); end{tikzpicture} just before pause, compile 3 times and tell me if you really see a jump.

– marmot
6 hours ago













Yes, if you hold a piece of paper at NP and check with ZP after advancing to the next slide, you see that ZP starts at a different place from NP.

– Stefan Müller
6 hours ago





Yes, if you hold a piece of paper at NP and check with ZP after advancing to the next slide, you see that ZP starts at a different place from NP.

– Stefan Müller
6 hours ago













I just played the thing on full screen mode in acroread and have a hard time confirming what you are saying. Apart from the obvious observation that the characters used in the tree have different widths I cannot see any jump. Please consider clarifying which jumps you are talking about.

– marmot
6 hours ago





I just played the thing on full screen mode in acroread and have a hard time confirming what you are saying. Apart from the obvious observation that the characters used in the tree have different widths I cannot see any jump. Please consider clarifying which jumps you are talking about.

– marmot
6 hours ago













It jumps. If you hold a piece of paper at the N of NP that was a ZP on slide 1 you see that the NP does not start at the position of the ZP. Also the tree edges are at different places.

– Stefan Müller
5 hours ago





It jumps. If you hold a piece of paper at the N of NP that was a ZP on slide 1 you see that the NP does not start at the position of the ZP. Also the tree edges are at different places.

– Stefan Müller
5 hours ago













All I can say is that I am unable to reproduce this on my TeXLive 2018 installation when I view the result with acroread. You could use convert -density 300 -delay 4 -loop 0 -alpha remove multipage.pdf animated.gif (see tex.stackexchange.com/a/136919/121799) in order to produce an animated gif that you can add to your question.

– marmot
5 hours ago





All I can say is that I am unable to reproduce this on my TeXLive 2018 installation when I view the result with acroread. You could use convert -density 300 -delay 4 -loop 0 -alpha remove multipage.pdf animated.gif (see tex.stackexchange.com/a/136919/121799) in order to produce an animated gif that you can add to your question.

– marmot
5 hours ago










0






active

oldest

votes











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
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f477532%2favoiding-jumping-nodes-in-a-tree-with-forest-and-beamer%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded




















































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.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f477532%2favoiding-jumping-nodes-in-a-tree-with-forest-and-beamer%23new-answer', 'question_page');
}
);

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







Popular posts from this blog

Installing LyX: “No textclass is found.”LyX installation error- text class not found- 'Reconfigure' or...

(1602) Indiana Índice Designación y nombre Características orbitales Véase...

Universidad Autónoma de Occidente Índice Historia Campus Facultades Programas Académicos Medios de...