Spurious space from tdplotsetmaincoordsHow to draw a cube with TikZ where all faces have a distinct color?
It's a yearly task, alright
Why doesn't the EU now just force the UK to choose between referendum and no-deal?
Could the Saturn V actually have launched astronauts around Venus?
How to create the Curved texte?
How difficult is it to simply disable/disengage the MCAS on Boeing 737 Max 8 & 9 Aircraft?
Who is flying the vertibirds?
How to use deus ex machina safely?
Is it normal that my co-workers at a fitness company criticize my food choices?
Should we release the security issues we found in our product as CVE or we can just update those on weekly release notes?
Why do passenger jet manufacturers design their planes with stall prevention systems?
Does Mathematica reuse previous computations?
Employee lack of ownership
Are there verbs that are neither telic, or atelic?
How to write cleanly even if my character uses expletive language?
Python if-else code style for reduced code for rounding floats
Opacity of an object in 2.8
My adviser wants to be the first author
Why do Australian milk farmers need to protest supermarkets' milk price?
If curse and magic is two sides of the same coin, why the former is forbidden?
Existence of subset with given Hausdorff dimension
How to make healing in an exploration game interesting
A link redirect to http instead of https: how critical is it?
Professor being mistaken for a grad student
How to simplify this time periods definition interface?
Spurious space from tdplotsetmaincoords
How to draw a cube with TikZ where all faces have a distinct color?
The MWE below results is spurious space due to the use of tdplotsetmaincoords
:
The red is the bounding box and the gray box is from fbox{}
.
Including an unskipunskip
(commented out in the MWE) does resolve the problem, but wondering if there is a better solution.
Is this a bug or is there a reason for this spacing?
Notes:
- Moving the
tdplotsetmaincoords{70}{115}
to be beforebegin{document}
also resolves the problem, but this won't easily work for me as my figures use thestandalone
class and are included in other documents -- thus I need to have that setting localized with each figure.
References:
- The code for the cube drawing is from How to draw a cube with TikZ where all faces have a distinct color?.
Code:
documentclass{article}
usepackage{tikz,tikz-3dplot}
newcommand*{DrawBoundingBox}[1][]{%
draw [
draw=red, thick,
]
([shift={(-1pt,-1pt)}]current bounding box.south west) rectangle
([shift={(1pt,1pt)}]current bounding box.north east);
}
begin{document}
fboxsep=0pt
fbox{%
%% code from https://tex.stackexchange.com/a/29342/4301
tdplotsetmaincoords{70}{115}%
%unskipunskip% <----- HACK which fixes the problem.
begin{tikzpicture}[scale=4,tdplot_main_coords]
coordinate (O) at (0,0,0);
tdplotsetcoord{P}{1.414213}{54.68636}{45}
draw[fill=gray!50,fill opacity=0.5] (O) -- (Py) -- (Pyz) -- (Pz) -- cycle;
draw[fill=blue,fill opacity=0.5] (O) -- (Px) -- (Pxy) -- (Py) -- cycle;
draw[fill=yellow,fill opacity=0.5] (O) -- (Px) -- (Pxz) -- (Pz) -- cycle;
draw[fill=green,fill opacity=0.5] (Pz) -- (Pyz) -- (P) -- (Pxz) -- cycle;
draw[fill=red,fill opacity=0.5] (Px) -- (Pxy) -- (P) -- (Pxz) -- cycle;
draw[fill=magenta,fill opacity=0.5] (Py) -- (Pxy) -- (P) -- (Pyz) -- cycle;
DrawBoundingBox
end{tikzpicture}%
}%
end{document}
tikz-pgf spacing draw
add a comment |
The MWE below results is spurious space due to the use of tdplotsetmaincoords
:
The red is the bounding box and the gray box is from fbox{}
.
Including an unskipunskip
(commented out in the MWE) does resolve the problem, but wondering if there is a better solution.
Is this a bug or is there a reason for this spacing?
Notes:
- Moving the
tdplotsetmaincoords{70}{115}
to be beforebegin{document}
also resolves the problem, but this won't easily work for me as my figures use thestandalone
class and are included in other documents -- thus I need to have that setting localized with each figure.
References:
- The code for the cube drawing is from How to draw a cube with TikZ where all faces have a distinct color?.
Code:
documentclass{article}
usepackage{tikz,tikz-3dplot}
newcommand*{DrawBoundingBox}[1][]{%
draw [
draw=red, thick,
]
([shift={(-1pt,-1pt)}]current bounding box.south west) rectangle
([shift={(1pt,1pt)}]current bounding box.north east);
}
begin{document}
fboxsep=0pt
fbox{%
%% code from https://tex.stackexchange.com/a/29342/4301
tdplotsetmaincoords{70}{115}%
%unskipunskip% <----- HACK which fixes the problem.
begin{tikzpicture}[scale=4,tdplot_main_coords]
coordinate (O) at (0,0,0);
tdplotsetcoord{P}{1.414213}{54.68636}{45}
draw[fill=gray!50,fill opacity=0.5] (O) -- (Py) -- (Pyz) -- (Pz) -- cycle;
draw[fill=blue,fill opacity=0.5] (O) -- (Px) -- (Pxy) -- (Py) -- cycle;
draw[fill=yellow,fill opacity=0.5] (O) -- (Px) -- (Pxz) -- (Pz) -- cycle;
draw[fill=green,fill opacity=0.5] (Pz) -- (Pyz) -- (P) -- (Pxz) -- cycle;
draw[fill=red,fill opacity=0.5] (Px) -- (Pxy) -- (P) -- (Pxz) -- cycle;
draw[fill=magenta,fill opacity=0.5] (Py) -- (Pxy) -- (P) -- (Pyz) -- cycle;
DrawBoundingBox
end{tikzpicture}%
}%
end{document}
tikz-pgf spacing draw
add a comment |
The MWE below results is spurious space due to the use of tdplotsetmaincoords
:
The red is the bounding box and the gray box is from fbox{}
.
Including an unskipunskip
(commented out in the MWE) does resolve the problem, but wondering if there is a better solution.
Is this a bug or is there a reason for this spacing?
Notes:
- Moving the
tdplotsetmaincoords{70}{115}
to be beforebegin{document}
also resolves the problem, but this won't easily work for me as my figures use thestandalone
class and are included in other documents -- thus I need to have that setting localized with each figure.
References:
- The code for the cube drawing is from How to draw a cube with TikZ where all faces have a distinct color?.
Code:
documentclass{article}
usepackage{tikz,tikz-3dplot}
newcommand*{DrawBoundingBox}[1][]{%
draw [
draw=red, thick,
]
([shift={(-1pt,-1pt)}]current bounding box.south west) rectangle
([shift={(1pt,1pt)}]current bounding box.north east);
}
begin{document}
fboxsep=0pt
fbox{%
%% code from https://tex.stackexchange.com/a/29342/4301
tdplotsetmaincoords{70}{115}%
%unskipunskip% <----- HACK which fixes the problem.
begin{tikzpicture}[scale=4,tdplot_main_coords]
coordinate (O) at (0,0,0);
tdplotsetcoord{P}{1.414213}{54.68636}{45}
draw[fill=gray!50,fill opacity=0.5] (O) -- (Py) -- (Pyz) -- (Pz) -- cycle;
draw[fill=blue,fill opacity=0.5] (O) -- (Px) -- (Pxy) -- (Py) -- cycle;
draw[fill=yellow,fill opacity=0.5] (O) -- (Px) -- (Pxz) -- (Pz) -- cycle;
draw[fill=green,fill opacity=0.5] (Pz) -- (Pyz) -- (P) -- (Pxz) -- cycle;
draw[fill=red,fill opacity=0.5] (Px) -- (Pxy) -- (P) -- (Pxz) -- cycle;
draw[fill=magenta,fill opacity=0.5] (Py) -- (Pxy) -- (P) -- (Pyz) -- cycle;
DrawBoundingBox
end{tikzpicture}%
}%
end{document}
tikz-pgf spacing draw
The MWE below results is spurious space due to the use of tdplotsetmaincoords
:
The red is the bounding box and the gray box is from fbox{}
.
Including an unskipunskip
(commented out in the MWE) does resolve the problem, but wondering if there is a better solution.
Is this a bug or is there a reason for this spacing?
Notes:
- Moving the
tdplotsetmaincoords{70}{115}
to be beforebegin{document}
also resolves the problem, but this won't easily work for me as my figures use thestandalone
class and are included in other documents -- thus I need to have that setting localized with each figure.
References:
- The code for the cube drawing is from How to draw a cube with TikZ where all faces have a distinct color?.
Code:
documentclass{article}
usepackage{tikz,tikz-3dplot}
newcommand*{DrawBoundingBox}[1][]{%
draw [
draw=red, thick,
]
([shift={(-1pt,-1pt)}]current bounding box.south west) rectangle
([shift={(1pt,1pt)}]current bounding box.north east);
}
begin{document}
fboxsep=0pt
fbox{%
%% code from https://tex.stackexchange.com/a/29342/4301
tdplotsetmaincoords{70}{115}%
%unskipunskip% <----- HACK which fixes the problem.
begin{tikzpicture}[scale=4,tdplot_main_coords]
coordinate (O) at (0,0,0);
tdplotsetcoord{P}{1.414213}{54.68636}{45}
draw[fill=gray!50,fill opacity=0.5] (O) -- (Py) -- (Pyz) -- (Pz) -- cycle;
draw[fill=blue,fill opacity=0.5] (O) -- (Px) -- (Pxy) -- (Py) -- cycle;
draw[fill=yellow,fill opacity=0.5] (O) -- (Px) -- (Pxz) -- (Pz) -- cycle;
draw[fill=green,fill opacity=0.5] (Pz) -- (Pyz) -- (P) -- (Pxz) -- cycle;
draw[fill=red,fill opacity=0.5] (Px) -- (Pxy) -- (P) -- (Pxz) -- cycle;
draw[fill=magenta,fill opacity=0.5] (Py) -- (Pxy) -- (P) -- (Pyz) -- cycle;
DrawBoundingBox
end{tikzpicture}%
}%
end{document}
tikz-pgf spacing draw
tikz-pgf spacing draw
asked 4 mins ago
Peter GrillPeter Grill
166k25442756
166k25442756
add a comment |
add a comment |
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
});
}
});
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%2f479734%2fspurious-space-from-tdplotsetmaincoords%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
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%2f479734%2fspurious-space-from-tdplotsetmaincoords%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