draw border around edge of symbol
up vote
4
down vote
favorite
Is it possible to draw a (coloured) border around the edge of a LaTeX symbol?
For instance, I would like to draw a black border around the edge of
a bigstar
. So, something like this
Below a very short MWE
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5]
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
I searched for solutions, but I only get squared frames around basically anything, but not what I'm after. Any idea? Cheers
tikz-pgf draw
add a comment |
up vote
4
down vote
favorite
Is it possible to draw a (coloured) border around the edge of a LaTeX symbol?
For instance, I would like to draw a black border around the edge of
a bigstar
. So, something like this
Below a very short MWE
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5]
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
I searched for solutions, but I only get squared frames around basically anything, but not what I'm after. Any idea? Cheers
tikz-pgf draw
add a comment |
up vote
4
down vote
favorite
up vote
4
down vote
favorite
Is it possible to draw a (coloured) border around the edge of a LaTeX symbol?
For instance, I would like to draw a black border around the edge of
a bigstar
. So, something like this
Below a very short MWE
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5]
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
I searched for solutions, but I only get squared frames around basically anything, but not what I'm after. Any idea? Cheers
tikz-pgf draw
Is it possible to draw a (coloured) border around the edge of a LaTeX symbol?
For instance, I would like to draw a black border around the edge of
a bigstar
. So, something like this
Below a very short MWE
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5]
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
I searched for solutions, but I only get squared frames around basically anything, but not what I'm after. Any idea? Cheers
tikz-pgf draw
tikz-pgf draw
asked 2 hours ago
andrea
1057
1057
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
up vote
4
down vote
Basic
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amssymb}
contourlength{0.5pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
contour{orange}{$bigstar$}
end{document}
Miscellaneous
The following example is not impossible but it takes much time and energy with PSTricks, let alone TikZ.
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amsmath}
usepackage{CJK}
contourlength{0.2pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
begin{CJK}{UTF8}{min}
begin{center}
contour{orange}{気持ちは}
end{center}
[
contour{red}{$sqrt{x^2}$},
contour{green}{$not=$},
contour{blue}{$x$}
]
begin{center}
contour{cyan}{言い表しにくいです}
end{center}
end{CJK}
end{document}
add a comment |
up vote
2
down vote
I guess the most simple-minded approach would be to draw the node in black and a bit larger underneath. Notice that you need to add transform shape
for the scale=0.5
to affect the node.
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5,transform shape]
node [black,scale=1.2] at (0,0,0) {$bigstar$};
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
contour
, as suggested in this answer does basically the same. However, TikZ also has star symbols built in. Why not use those?
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usetikzlibrary{shapes.geometric}
begin{document}
begin{tikzpicture}
node [star,draw,fill=yellow,minimum size=5mm,star point ratio=2]{};
end{tikzpicture}
end{document}
The crucial advantage is that you have all sorts of parameters that you can adjust to obtain the star you really want (a so-called super-star ;-), see the pgfmanual on p. 701.
+1. I also wrote the same code., except that I used red instead of black :)
– nidhin
2 hours ago
@nidhin You very recently scooped me in another answer, which I (of course) upvoted, thanks!
– marmot
2 hours ago
1
hehe. Then let us consider it even. :)
– nidhin
2 hours ago
add a comment |
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
4
down vote
Basic
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amssymb}
contourlength{0.5pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
contour{orange}{$bigstar$}
end{document}
Miscellaneous
The following example is not impossible but it takes much time and energy with PSTricks, let alone TikZ.
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amsmath}
usepackage{CJK}
contourlength{0.2pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
begin{CJK}{UTF8}{min}
begin{center}
contour{orange}{気持ちは}
end{center}
[
contour{red}{$sqrt{x^2}$},
contour{green}{$not=$},
contour{blue}{$x$}
]
begin{center}
contour{cyan}{言い表しにくいです}
end{center}
end{CJK}
end{document}
add a comment |
up vote
4
down vote
Basic
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amssymb}
contourlength{0.5pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
contour{orange}{$bigstar$}
end{document}
Miscellaneous
The following example is not impossible but it takes much time and energy with PSTricks, let alone TikZ.
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amsmath}
usepackage{CJK}
contourlength{0.2pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
begin{CJK}{UTF8}{min}
begin{center}
contour{orange}{気持ちは}
end{center}
[
contour{red}{$sqrt{x^2}$},
contour{green}{$not=$},
contour{blue}{$x$}
]
begin{center}
contour{cyan}{言い表しにくいです}
end{center}
end{CJK}
end{document}
add a comment |
up vote
4
down vote
up vote
4
down vote
Basic
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amssymb}
contourlength{0.5pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
contour{orange}{$bigstar$}
end{document}
Miscellaneous
The following example is not impossible but it takes much time and energy with PSTricks, let alone TikZ.
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amsmath}
usepackage{CJK}
contourlength{0.2pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
begin{CJK}{UTF8}{min}
begin{center}
contour{orange}{気持ちは}
end{center}
[
contour{red}{$sqrt{x^2}$},
contour{green}{$not=$},
contour{blue}{$x$}
]
begin{center}
contour{cyan}{言い表しにくいです}
end{center}
end{CJK}
end{document}
Basic
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amssymb}
contourlength{0.5pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
contour{orange}{$bigstar$}
end{document}
Miscellaneous
The following example is not impossible but it takes much time and energy with PSTricks, let alone TikZ.
documentclass[preview,border=12pt,varwidth,dvipsnames]{standalone}
usepackage{contour}
usepackage{xcolor,amsmath}
usepackage{CJK}
contourlength{0.2pt} % thickness
contournumber{10} % number of replication
begin{document}
huge
begin{CJK}{UTF8}{min}
begin{center}
contour{orange}{気持ちは}
end{center}
[
contour{red}{$sqrt{x^2}$},
contour{green}{$not=$},
contour{blue}{$x$}
]
begin{center}
contour{cyan}{言い表しにくいです}
end{center}
end{CJK}
end{document}
edited 2 hours ago
answered 2 hours ago
Artificial Stupidity
4,82111039
4,82111039
add a comment |
add a comment |
up vote
2
down vote
I guess the most simple-minded approach would be to draw the node in black and a bit larger underneath. Notice that you need to add transform shape
for the scale=0.5
to affect the node.
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5,transform shape]
node [black,scale=1.2] at (0,0,0) {$bigstar$};
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
contour
, as suggested in this answer does basically the same. However, TikZ also has star symbols built in. Why not use those?
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usetikzlibrary{shapes.geometric}
begin{document}
begin{tikzpicture}
node [star,draw,fill=yellow,minimum size=5mm,star point ratio=2]{};
end{tikzpicture}
end{document}
The crucial advantage is that you have all sorts of parameters that you can adjust to obtain the star you really want (a so-called super-star ;-), see the pgfmanual on p. 701.
+1. I also wrote the same code., except that I used red instead of black :)
– nidhin
2 hours ago
@nidhin You very recently scooped me in another answer, which I (of course) upvoted, thanks!
– marmot
2 hours ago
1
hehe. Then let us consider it even. :)
– nidhin
2 hours ago
add a comment |
up vote
2
down vote
I guess the most simple-minded approach would be to draw the node in black and a bit larger underneath. Notice that you need to add transform shape
for the scale=0.5
to affect the node.
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5,transform shape]
node [black,scale=1.2] at (0,0,0) {$bigstar$};
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
contour
, as suggested in this answer does basically the same. However, TikZ also has star symbols built in. Why not use those?
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usetikzlibrary{shapes.geometric}
begin{document}
begin{tikzpicture}
node [star,draw,fill=yellow,minimum size=5mm,star point ratio=2]{};
end{tikzpicture}
end{document}
The crucial advantage is that you have all sorts of parameters that you can adjust to obtain the star you really want (a so-called super-star ;-), see the pgfmanual on p. 701.
+1. I also wrote the same code., except that I used red instead of black :)
– nidhin
2 hours ago
@nidhin You very recently scooped me in another answer, which I (of course) upvoted, thanks!
– marmot
2 hours ago
1
hehe. Then let us consider it even. :)
– nidhin
2 hours ago
add a comment |
up vote
2
down vote
up vote
2
down vote
I guess the most simple-minded approach would be to draw the node in black and a bit larger underneath. Notice that you need to add transform shape
for the scale=0.5
to affect the node.
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5,transform shape]
node [black,scale=1.2] at (0,0,0) {$bigstar$};
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
contour
, as suggested in this answer does basically the same. However, TikZ also has star symbols built in. Why not use those?
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usetikzlibrary{shapes.geometric}
begin{document}
begin{tikzpicture}
node [star,draw,fill=yellow,minimum size=5mm,star point ratio=2]{};
end{tikzpicture}
end{document}
The crucial advantage is that you have all sorts of parameters that you can adjust to obtain the star you really want (a so-called super-star ;-), see the pgfmanual on p. 701.
I guess the most simple-minded approach would be to draw the node in black and a bit larger underneath. Notice that you need to add transform shape
for the scale=0.5
to affect the node.
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usepackage{amssymb}
begin{document}
begin{tikzpicture}[scale = 0.5,transform shape]
node [black,scale=1.2] at (0,0,0) {$bigstar$};
node [yellow] at (0,0,0) {$bigstar$};
end{tikzpicture}
end{document}
contour
, as suggested in this answer does basically the same. However, TikZ also has star symbols built in. Why not use those?
documentclass[tikz,border=10pt]{standalone}
usepackage{tikz}
usetikzlibrary{shapes.geometric}
begin{document}
begin{tikzpicture}
node [star,draw,fill=yellow,minimum size=5mm,star point ratio=2]{};
end{tikzpicture}
end{document}
The crucial advantage is that you have all sorts of parameters that you can adjust to obtain the star you really want (a so-called super-star ;-), see the pgfmanual on p. 701.
edited 2 hours ago
answered 2 hours ago
marmot
82.3k492175
82.3k492175
+1. I also wrote the same code., except that I used red instead of black :)
– nidhin
2 hours ago
@nidhin You very recently scooped me in another answer, which I (of course) upvoted, thanks!
– marmot
2 hours ago
1
hehe. Then let us consider it even. :)
– nidhin
2 hours ago
add a comment |
+1. I also wrote the same code., except that I used red instead of black :)
– nidhin
2 hours ago
@nidhin You very recently scooped me in another answer, which I (of course) upvoted, thanks!
– marmot
2 hours ago
1
hehe. Then let us consider it even. :)
– nidhin
2 hours ago
+1. I also wrote the same code., except that I used red instead of black :)
– nidhin
2 hours ago
+1. I also wrote the same code., except that I used red instead of black :)
– nidhin
2 hours ago
@nidhin You very recently scooped me in another answer, which I (of course) upvoted, thanks!
– marmot
2 hours ago
@nidhin You very recently scooped me in another answer, which I (of course) upvoted, thanks!
– marmot
2 hours ago
1
1
hehe. Then let us consider it even. :)
– nidhin
2 hours ago
hehe. Then let us consider it even. :)
– nidhin
2 hours 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.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- 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%2f464360%2fdraw-border-around-edge-of-symbol%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