How to add multiple differently colored borders around a node?
I want to draw a node to be filled with a table containing data, and it should have (three) differently colored adjacent borders around it. Couldn't find anything in the PGF manual, on the Net, nor on this forum, so I came up with this MWE...
Nesting three tikzpicture environments feels like a BIG amateuristic kludge to me, and if not, how do I get rid of the white space in between the borders?
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{tikz}
begin{document}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=black] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.rood] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.geel,fill=lichtgrijs] at (0,0) {Vliegtuig};
end{tikzpicture}};
end{tikzpicture}};
end{tikzpicture}
end{document}

tikz-pgf nodes border
add a comment |
I want to draw a node to be filled with a table containing data, and it should have (three) differently colored adjacent borders around it. Couldn't find anything in the PGF manual, on the Net, nor on this forum, so I came up with this MWE...
Nesting three tikzpicture environments feels like a BIG amateuristic kludge to me, and if not, how do I get rid of the white space in between the borders?
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{tikz}
begin{document}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=black] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.rood] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.geel,fill=lichtgrijs] at (0,0) {Vliegtuig};
end{tikzpicture}};
end{tikzpicture}};
end{tikzpicture}
end{document}

tikz-pgf nodes border
add a comment |
I want to draw a node to be filled with a table containing data, and it should have (three) differently colored adjacent borders around it. Couldn't find anything in the PGF manual, on the Net, nor on this forum, so I came up with this MWE...
Nesting three tikzpicture environments feels like a BIG amateuristic kludge to me, and if not, how do I get rid of the white space in between the borders?
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{tikz}
begin{document}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=black] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.rood] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.geel,fill=lichtgrijs] at (0,0) {Vliegtuig};
end{tikzpicture}};
end{tikzpicture}};
end{tikzpicture}
end{document}

tikz-pgf nodes border
I want to draw a node to be filled with a table containing data, and it should have (three) differently colored adjacent borders around it. Couldn't find anything in the PGF manual, on the Net, nor on this forum, so I came up with this MWE...
Nesting three tikzpicture environments feels like a BIG amateuristic kludge to me, and if not, how do I get rid of the white space in between the borders?
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{tikz}
begin{document}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=black] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.rood] at (0,0)
{begin{tikzpicture}
node[rectangle,line width=0.5mm,draw=DE.geel,fill=lichtgrijs] at (0,0) {Vliegtuig};
end{tikzpicture}};
end{tikzpicture}};
end{tikzpicture}
end{document}

tikz-pgf nodes border
tikz-pgf nodes border
asked 2 hours ago
Petoetje59Petoetje59
4291615
4291615
add a comment |
add a comment |
3 Answers
3
active
oldest
votes
Like this?

documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
box/.style = {draw=#1, line width=0.5mm,inner sep=0.25mm}
]
node (n1) [box=DE.geel,
fill=lichtgrijs, inner sep=2mm] at (0,0) {Vliegtuig};
node (n2) [box=DE.rood, fit=(n1)] {};
node (n3) [box=black, fit=(n2)] {};
end{tikzpicture}
end{document}
Some Notes:
- never nest
tikzpictureintikzpicture, which may raise unexpected side effects; - the
fitlibrary oftikzis used to get what you want; - you can define node style, which merges all nodes in one, but I'd like first to know whether the illustrated result is what you're looking for :-)
addendum:
here is a three-color node variation. In particular, append after command= option in a node style is used for the middle and the outer colors:
documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
tcb/.style = {% tree color box
draw=DE.geel, fill=lichtgrijs,
line width=0.5mm,inner sep=2mm,
append after command={pgfextra{letLNtikzlastnode
node [draw=DE.rood, line width=0.5mm,
inner sep=0.25mm,fit=(LN)] {};
node [draw, line width=0.5mm,
inner sep=0.75mm,fit=(LN)] {};
}}}
]
node (n1) [tcb] {Vliegtuig};
end{tikzpicture}
end{document}
The result is the same as before.
Yep, that's it! What an incredibly fast reply...
– Petoetje59
2 hours ago
1
@Roboticist, thank you very much!
– Zarko
45 mins ago
@Zarko: Any time, Sir!;)
– Roboticist
44 mins ago
add a comment |
Just for fun:
documentclass{standalone}% to avoid cropping
usepackage{babel}% not needed for MWE
usepackage{tikz}
usetikzlibrary{calc}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
begin{tikzpicture}
begin{scope}[line width=0.5mm]
node[draw=black,inner sep = 1.5mm] (n1) at (0,0) {Vliegtuig};
draw[DE.rood] ($(n1.south west)+(0.75mm,0.75mm)$) rectangle ($(n1.north east)+(-0.75mm,-0.75mm)$);
draw[DE.geel] ($(n1.south west)+(1.25mm,1.25mm)$) rectangle ($(n1.north east)+(-1.25mm,-1.25mm)$);
end{scope}
end{tikzpicture}
end{document}

add a comment |
Without TikZ, only colorboxes:
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{xcolor}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
colorbox{black}{%
colorbox{DE.rood}{%
colorbox{DE.geel}{%
colorbox{lichtgrijs}{Vliegtuig}}}}
end{document}

Would've been the best solution... but unfortunately there appears to be no option to set the border width.
– Petoetje59
48 mins ago
@Petoetje59 You can set the dimensions of the colorboxes. But I have no time now, I'll update my answer asap.
– CarLaTeX
45 mins ago
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%2f477589%2fhow-to-add-multiple-differently-colored-borders-around-a-node%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
Like this?

documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
box/.style = {draw=#1, line width=0.5mm,inner sep=0.25mm}
]
node (n1) [box=DE.geel,
fill=lichtgrijs, inner sep=2mm] at (0,0) {Vliegtuig};
node (n2) [box=DE.rood, fit=(n1)] {};
node (n3) [box=black, fit=(n2)] {};
end{tikzpicture}
end{document}
Some Notes:
- never nest
tikzpictureintikzpicture, which may raise unexpected side effects; - the
fitlibrary oftikzis used to get what you want; - you can define node style, which merges all nodes in one, but I'd like first to know whether the illustrated result is what you're looking for :-)
addendum:
here is a three-color node variation. In particular, append after command= option in a node style is used for the middle and the outer colors:
documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
tcb/.style = {% tree color box
draw=DE.geel, fill=lichtgrijs,
line width=0.5mm,inner sep=2mm,
append after command={pgfextra{letLNtikzlastnode
node [draw=DE.rood, line width=0.5mm,
inner sep=0.25mm,fit=(LN)] {};
node [draw, line width=0.5mm,
inner sep=0.75mm,fit=(LN)] {};
}}}
]
node (n1) [tcb] {Vliegtuig};
end{tikzpicture}
end{document}
The result is the same as before.
Yep, that's it! What an incredibly fast reply...
– Petoetje59
2 hours ago
1
@Roboticist, thank you very much!
– Zarko
45 mins ago
@Zarko: Any time, Sir!;)
– Roboticist
44 mins ago
add a comment |
Like this?

documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
box/.style = {draw=#1, line width=0.5mm,inner sep=0.25mm}
]
node (n1) [box=DE.geel,
fill=lichtgrijs, inner sep=2mm] at (0,0) {Vliegtuig};
node (n2) [box=DE.rood, fit=(n1)] {};
node (n3) [box=black, fit=(n2)] {};
end{tikzpicture}
end{document}
Some Notes:
- never nest
tikzpictureintikzpicture, which may raise unexpected side effects; - the
fitlibrary oftikzis used to get what you want; - you can define node style, which merges all nodes in one, but I'd like first to know whether the illustrated result is what you're looking for :-)
addendum:
here is a three-color node variation. In particular, append after command= option in a node style is used for the middle and the outer colors:
documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
tcb/.style = {% tree color box
draw=DE.geel, fill=lichtgrijs,
line width=0.5mm,inner sep=2mm,
append after command={pgfextra{letLNtikzlastnode
node [draw=DE.rood, line width=0.5mm,
inner sep=0.25mm,fit=(LN)] {};
node [draw, line width=0.5mm,
inner sep=0.75mm,fit=(LN)] {};
}}}
]
node (n1) [tcb] {Vliegtuig};
end{tikzpicture}
end{document}
The result is the same as before.
Yep, that's it! What an incredibly fast reply...
– Petoetje59
2 hours ago
1
@Roboticist, thank you very much!
– Zarko
45 mins ago
@Zarko: Any time, Sir!;)
– Roboticist
44 mins ago
add a comment |
Like this?

documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
box/.style = {draw=#1, line width=0.5mm,inner sep=0.25mm}
]
node (n1) [box=DE.geel,
fill=lichtgrijs, inner sep=2mm] at (0,0) {Vliegtuig};
node (n2) [box=DE.rood, fit=(n1)] {};
node (n3) [box=black, fit=(n2)] {};
end{tikzpicture}
end{document}
Some Notes:
- never nest
tikzpictureintikzpicture, which may raise unexpected side effects; - the
fitlibrary oftikzis used to get what you want; - you can define node style, which merges all nodes in one, but I'd like first to know whether the illustrated result is what you're looking for :-)
addendum:
here is a three-color node variation. In particular, append after command= option in a node style is used for the middle and the outer colors:
documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
tcb/.style = {% tree color box
draw=DE.geel, fill=lichtgrijs,
line width=0.5mm,inner sep=2mm,
append after command={pgfextra{letLNtikzlastnode
node [draw=DE.rood, line width=0.5mm,
inner sep=0.25mm,fit=(LN)] {};
node [draw, line width=0.5mm,
inner sep=0.75mm,fit=(LN)] {};
}}}
]
node (n1) [tcb] {Vliegtuig};
end{tikzpicture}
end{document}
The result is the same as before.
Like this?

documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
box/.style = {draw=#1, line width=0.5mm,inner sep=0.25mm}
]
node (n1) [box=DE.geel,
fill=lichtgrijs, inner sep=2mm] at (0,0) {Vliegtuig};
node (n2) [box=DE.rood, fit=(n1)] {};
node (n3) [box=black, fit=(n2)] {};
end{tikzpicture}
end{document}
Some Notes:
- never nest
tikzpictureintikzpicture, which may raise unexpected side effects; - the
fitlibrary oftikzis used to get what you want; - you can define node style, which merges all nodes in one, but I'd like first to know whether the illustrated result is what you're looking for :-)
addendum:
here is a three-color node variation. In particular, append after command= option in a node style is used for the middle and the outer colors:
documentclass[dutch]{article}
usepackage{babel}
usepackage{tikz}
usetikzlibrary{fit}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0} % Rood in Duitse vlag
definecolor{DE.geel}{RGB}{255,207,0} % Geel in Duitse vlag
begin{document}
begin{tikzpicture}[
tcb/.style = {% tree color box
draw=DE.geel, fill=lichtgrijs,
line width=0.5mm,inner sep=2mm,
append after command={pgfextra{letLNtikzlastnode
node [draw=DE.rood, line width=0.5mm,
inner sep=0.25mm,fit=(LN)] {};
node [draw, line width=0.5mm,
inner sep=0.75mm,fit=(LN)] {};
}}}
]
node (n1) [tcb] {Vliegtuig};
end{tikzpicture}
end{document}
The result is the same as before.
edited 46 mins ago
Roboticist
1,65721231
1,65721231
answered 2 hours ago
ZarkoZarko
126k867164
126k867164
Yep, that's it! What an incredibly fast reply...
– Petoetje59
2 hours ago
1
@Roboticist, thank you very much!
– Zarko
45 mins ago
@Zarko: Any time, Sir!;)
– Roboticist
44 mins ago
add a comment |
Yep, that's it! What an incredibly fast reply...
– Petoetje59
2 hours ago
1
@Roboticist, thank you very much!
– Zarko
45 mins ago
@Zarko: Any time, Sir!;)
– Roboticist
44 mins ago
Yep, that's it! What an incredibly fast reply...
– Petoetje59
2 hours ago
Yep, that's it! What an incredibly fast reply...
– Petoetje59
2 hours ago
1
1
@Roboticist, thank you very much!
– Zarko
45 mins ago
@Roboticist, thank you very much!
– Zarko
45 mins ago
@Zarko: Any time, Sir!
;)– Roboticist
44 mins ago
@Zarko: Any time, Sir!
;)– Roboticist
44 mins ago
add a comment |
Just for fun:
documentclass{standalone}% to avoid cropping
usepackage{babel}% not needed for MWE
usepackage{tikz}
usetikzlibrary{calc}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
begin{tikzpicture}
begin{scope}[line width=0.5mm]
node[draw=black,inner sep = 1.5mm] (n1) at (0,0) {Vliegtuig};
draw[DE.rood] ($(n1.south west)+(0.75mm,0.75mm)$) rectangle ($(n1.north east)+(-0.75mm,-0.75mm)$);
draw[DE.geel] ($(n1.south west)+(1.25mm,1.25mm)$) rectangle ($(n1.north east)+(-1.25mm,-1.25mm)$);
end{scope}
end{tikzpicture}
end{document}

add a comment |
Just for fun:
documentclass{standalone}% to avoid cropping
usepackage{babel}% not needed for MWE
usepackage{tikz}
usetikzlibrary{calc}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
begin{tikzpicture}
begin{scope}[line width=0.5mm]
node[draw=black,inner sep = 1.5mm] (n1) at (0,0) {Vliegtuig};
draw[DE.rood] ($(n1.south west)+(0.75mm,0.75mm)$) rectangle ($(n1.north east)+(-0.75mm,-0.75mm)$);
draw[DE.geel] ($(n1.south west)+(1.25mm,1.25mm)$) rectangle ($(n1.north east)+(-1.25mm,-1.25mm)$);
end{scope}
end{tikzpicture}
end{document}

add a comment |
Just for fun:
documentclass{standalone}% to avoid cropping
usepackage{babel}% not needed for MWE
usepackage{tikz}
usetikzlibrary{calc}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
begin{tikzpicture}
begin{scope}[line width=0.5mm]
node[draw=black,inner sep = 1.5mm] (n1) at (0,0) {Vliegtuig};
draw[DE.rood] ($(n1.south west)+(0.75mm,0.75mm)$) rectangle ($(n1.north east)+(-0.75mm,-0.75mm)$);
draw[DE.geel] ($(n1.south west)+(1.25mm,1.25mm)$) rectangle ($(n1.north east)+(-1.25mm,-1.25mm)$);
end{scope}
end{tikzpicture}
end{document}

Just for fun:
documentclass{standalone}% to avoid cropping
usepackage{babel}% not needed for MWE
usepackage{tikz}
usetikzlibrary{calc}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
begin{tikzpicture}
begin{scope}[line width=0.5mm]
node[draw=black,inner sep = 1.5mm] (n1) at (0,0) {Vliegtuig};
draw[DE.rood] ($(n1.south west)+(0.75mm,0.75mm)$) rectangle ($(n1.north east)+(-0.75mm,-0.75mm)$);
draw[DE.geel] ($(n1.south west)+(1.25mm,1.25mm)$) rectangle ($(n1.north east)+(-1.25mm,-1.25mm)$);
end{scope}
end{tikzpicture}
end{document}

answered 1 hour ago
John KormyloJohn Kormylo
44.7k12569
44.7k12569
add a comment |
add a comment |
Without TikZ, only colorboxes:
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{xcolor}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
colorbox{black}{%
colorbox{DE.rood}{%
colorbox{DE.geel}{%
colorbox{lichtgrijs}{Vliegtuig}}}}
end{document}

Would've been the best solution... but unfortunately there appears to be no option to set the border width.
– Petoetje59
48 mins ago
@Petoetje59 You can set the dimensions of the colorboxes. But I have no time now, I'll update my answer asap.
– CarLaTeX
45 mins ago
add a comment |
Without TikZ, only colorboxes:
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{xcolor}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
colorbox{black}{%
colorbox{DE.rood}{%
colorbox{DE.geel}{%
colorbox{lichtgrijs}{Vliegtuig}}}}
end{document}

Would've been the best solution... but unfortunately there appears to be no option to set the border width.
– Petoetje59
48 mins ago
@Petoetje59 You can set the dimensions of the colorboxes. But I have no time now, I'll update my answer asap.
– CarLaTeX
45 mins ago
add a comment |
Without TikZ, only colorboxes:
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{xcolor}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
colorbox{black}{%
colorbox{DE.rood}{%
colorbox{DE.geel}{%
colorbox{lichtgrijs}{Vliegtuig}}}}
end{document}

Without TikZ, only colorboxes:
documentclass[pdftex,dutch]{article}
usepackage{babel}
usepackage{xcolor}
definecolor{lichtgrijs}{RGB}{232,232,232}
definecolor{DE.rood}{RGB}{222,0,0}
definecolor{DE.geel}{RGB}{255,207,0}
begin{document}
colorbox{black}{%
colorbox{DE.rood}{%
colorbox{DE.geel}{%
colorbox{lichtgrijs}{Vliegtuig}}}}
end{document}

answered 1 hour ago
CarLaTeXCarLaTeX
32.4k551134
32.4k551134
Would've been the best solution... but unfortunately there appears to be no option to set the border width.
– Petoetje59
48 mins ago
@Petoetje59 You can set the dimensions of the colorboxes. But I have no time now, I'll update my answer asap.
– CarLaTeX
45 mins ago
add a comment |
Would've been the best solution... but unfortunately there appears to be no option to set the border width.
– Petoetje59
48 mins ago
@Petoetje59 You can set the dimensions of the colorboxes. But I have no time now, I'll update my answer asap.
– CarLaTeX
45 mins ago
Would've been the best solution... but unfortunately there appears to be no option to set the border width.
– Petoetje59
48 mins ago
Would've been the best solution... but unfortunately there appears to be no option to set the border width.
– Petoetje59
48 mins ago
@Petoetje59 You can set the dimensions of the colorboxes. But I have no time now, I'll update my answer asap.
– CarLaTeX
45 mins ago
@Petoetje59 You can set the dimensions of the colorboxes. But I have no time now, I'll update my answer asap.
– CarLaTeX
45 mins ago
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%2f477589%2fhow-to-add-multiple-differently-colored-borders-around-a-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