Why does overlay work only on the first tcolorbox?how to draw a bicolor tcolorbox without frame?tcolorbox with title on the left sidetcolorbox overlay app does not worktcolorbox `interior titled code app` does not workWhy some commands in tcolorbox do not work?tcolorbox breakable raster does not work if a cell breakstcolorbox, tabularx: first line with a multicolumn does not work in tcolorbox environmentoverlay for lowerpart of a breakable tcolorboxtcolorbox overlay in caption formatBeamer, tcolorbox, and fade overlayWhy does the former work but the latter doesn't?Tcolorbox: Outer style doesn't work

How can I raise concerns with a new DM about XP splitting?

Calculating the number of days between 2 dates in Excel

Is there an Impartial Brexit Deal comparison site?

The One-Electron Universe postulate is true - what simple change can I make to change the whole universe?

Female=gender counterpart?

What does the "3am" section means in manpages?

Is there a problem with hiding "forgot password" until it's needed?

How do ultrasonic sensors differentiate between transmitted and received signals?

Could solar power be utilized and substitute coal in the 19th century?

Can a Gentile theist be saved?

Can a malicious addon access internet history and such in chrome/firefox?

Reply ‘no position’ while the job posting is still there (‘HiWi’ position in Germany)

Is there an wasy way to program in Tikz something like the one in the image?

Can the harmonic series explain the origin of the major scale?

Resetting two CD4017 counters simultaneously, only one resets

Have I saved too much for retirement so far?

Can I rely on these GitHub repository files?

How will losing mobility of one hand affect my career as a programmer?

Latex for-and in equation

A workplace installs custom certificates on personal devices, can this be used to decrypt HTTPS traffic?

How to deal with or prevent idle in the test team?

Indicating multiple different modes of speech (fantasy language or telepathy)

Simulating a probability of 1 of 2^N with less than N random bits

Giant Toughroad SLR 2 for 200 miles in two days, will it make it?



Why does overlay work only on the first tcolorbox?


how to draw a bicolor tcolorbox without frame?tcolorbox with title on the left sidetcolorbox overlay app does not worktcolorbox `interior titled code app` does not workWhy some commands in tcolorbox do not work?tcolorbox breakable raster does not work if a cell breakstcolorbox, tabularx: first line with a multicolumn does not work in tcolorbox environmentoverlay for lowerpart of a breakable tcolorboxtcolorbox overlay in caption formatBeamer, tcolorbox, and fade overlayWhy does the former work but the latter doesn't?Tcolorbox: Outer style doesn't work













10















I'm trying to create a customized tcolorbox with some TikZ code in the overlay option.



But it works only the first time I use my new box. What am I doing wrong?



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth, yshift=-tcbtextheight-2ex]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here










share|improve this question






















  • If you add the code for the first box twice, you get two identical boxes. (Most likely I do not understand the question.)

    – marmot
    Mar 16 at 19:13











  • @marmot I don't get the marmot on the second box!

    – CarLaTeX
    Mar 16 at 19:15











  • beginmybox We love TiemphkZlings! endmybox beginmybox We love TiemphkZlings! endmybox works fine, the problem seem to be related to the content of the box

    – samcarter
    Mar 16 at 19:17







  • 3





    @CarLaTeX The marmot was probably in its burrow behind the tcolorbox :)

    – samcarter
    Mar 16 at 19:27






  • 1





    @marmot You're right I made a big mistake!

    – CarLaTeX
    Mar 16 at 19:56















10















I'm trying to create a customized tcolorbox with some TikZ code in the overlay option.



But it works only the first time I use my new box. What am I doing wrong?



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth, yshift=-tcbtextheight-2ex]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here










share|improve this question






















  • If you add the code for the first box twice, you get two identical boxes. (Most likely I do not understand the question.)

    – marmot
    Mar 16 at 19:13











  • @marmot I don't get the marmot on the second box!

    – CarLaTeX
    Mar 16 at 19:15











  • beginmybox We love TiemphkZlings! endmybox beginmybox We love TiemphkZlings! endmybox works fine, the problem seem to be related to the content of the box

    – samcarter
    Mar 16 at 19:17







  • 3





    @CarLaTeX The marmot was probably in its burrow behind the tcolorbox :)

    – samcarter
    Mar 16 at 19:27






  • 1





    @marmot You're right I made a big mistake!

    – CarLaTeX
    Mar 16 at 19:56













10












10








10


3






I'm trying to create a customized tcolorbox with some TikZ code in the overlay option.



But it works only the first time I use my new box. What am I doing wrong?



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth, yshift=-tcbtextheight-2ex]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here










share|improve this question














I'm trying to create a customized tcolorbox with some TikZ code in the overlay option.



But it works only the first time I use my new box. What am I doing wrong?



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[xshift=.5linewidth, yshift=-tcbtextheight-2ex]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here







tcolorbox






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Mar 16 at 19:11









CarLaTeXCarLaTeX

34k551140




34k551140












  • If you add the code for the first box twice, you get two identical boxes. (Most likely I do not understand the question.)

    – marmot
    Mar 16 at 19:13











  • @marmot I don't get the marmot on the second box!

    – CarLaTeX
    Mar 16 at 19:15











  • beginmybox We love TiemphkZlings! endmybox beginmybox We love TiemphkZlings! endmybox works fine, the problem seem to be related to the content of the box

    – samcarter
    Mar 16 at 19:17







  • 3





    @CarLaTeX The marmot was probably in its burrow behind the tcolorbox :)

    – samcarter
    Mar 16 at 19:27






  • 1





    @marmot You're right I made a big mistake!

    – CarLaTeX
    Mar 16 at 19:56

















  • If you add the code for the first box twice, you get two identical boxes. (Most likely I do not understand the question.)

    – marmot
    Mar 16 at 19:13











  • @marmot I don't get the marmot on the second box!

    – CarLaTeX
    Mar 16 at 19:15











  • beginmybox We love TiemphkZlings! endmybox beginmybox We love TiemphkZlings! endmybox works fine, the problem seem to be related to the content of the box

    – samcarter
    Mar 16 at 19:17







  • 3





    @CarLaTeX The marmot was probably in its burrow behind the tcolorbox :)

    – samcarter
    Mar 16 at 19:27






  • 1





    @marmot You're right I made a big mistake!

    – CarLaTeX
    Mar 16 at 19:56
















If you add the code for the first box twice, you get two identical boxes. (Most likely I do not understand the question.)

– marmot
Mar 16 at 19:13





If you add the code for the first box twice, you get two identical boxes. (Most likely I do not understand the question.)

– marmot
Mar 16 at 19:13













@marmot I don't get the marmot on the second box!

– CarLaTeX
Mar 16 at 19:15





@marmot I don't get the marmot on the second box!

– CarLaTeX
Mar 16 at 19:15













beginmybox We love TiemphkZlings! endmybox beginmybox We love TiemphkZlings! endmybox works fine, the problem seem to be related to the content of the box

– samcarter
Mar 16 at 19:17






beginmybox We love TiemphkZlings! endmybox beginmybox We love TiemphkZlings! endmybox works fine, the problem seem to be related to the content of the box

– samcarter
Mar 16 at 19:17





3




3





@CarLaTeX The marmot was probably in its burrow behind the tcolorbox :)

– samcarter
Mar 16 at 19:27





@CarLaTeX The marmot was probably in its burrow behind the tcolorbox :)

– samcarter
Mar 16 at 19:27




1




1





@marmot You're right I made a big mistake!

– CarLaTeX
Mar 16 at 19:56





@marmot You're right I made a big mistake!

– CarLaTeX
Mar 16 at 19:56










1 Answer
1






active

oldest

votes


















11














Oh no! No marmot on the second box! This has to be rectified! (As mentioned by @samcarter, the marmot got clipped away. But one can shift her or him back to visible region.)



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



Some other tikzlings joined the party.



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
koala[shift=([yshift=-7ex,xshift=-5em]frame.north)]
mouse[shift=([yshift=-7ex,xshift=5em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
koala[shift=([yshift=-4ex,xshift=-5em]frame.south)]
mouse[shift=([yshift=-4ex,xshift=5em]frame.south)]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



And a cheesebox tends to attract mice (with important input by @samcarter in the chat).



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmousebox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
underlay=%
begintcbclipinterior
fill [yellow]
(interior.south west) rectangle (interior.north east);
path let p1=($(interior.north east)-(interior.south west)$)
in [/utils/exec=pgfmathtruncatemacroNX1+x1*1pt/3cm
pgfmathtruncatemacroNY1+y1*1pt/2cmxdefNXNX
xdefNYNY];
foreach X in 1,...,NX
foreach Y in 1,...,NY
foreach x/y/r in 0.4/0.6/0.3,
0.5/1.3/0.2,%
1.5/0.5/0.4,%
1.5/0.5/0.4,%
2.1/1.5/0.3,%
2.5/0.8/0.2,%
3.3/1.1/0.3
shade[ball color=yellow!80!orange,opacity=0.2]
(x+(X-1)*3,y+(Y-1)*2) circle (r);

endtcbclipinterior,
,
%colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
foreach Y in -5,0,5
beginscope[shift=([yshift=-9ex,xshift=Y em]frame.north)]
path[fill=gray!50]
(0.5, 1.8) .. controls (0.5, 1.58) and (0.2, 1.25) .. (0, 1.16) .. controls (-0.2, 1.25) and (-0.5, 1.58) .. (-0.5, 1.8) .. controls (-0.34, 2.3) and (0.34, 2.3) .. (0.5, 1.8) -- cycle;
path[fill=gray!50!black] (0, 1.248) circle (0.09);
foreach X in 10,20,33%
fill[gray!50!black] (0,1.2) + (X:0.08) to[out=X,in=180-X] ++(X-20:0.3) --++(0,0.01) to[out=180-X,in=X] cycle (0,1.2) + (180-X:0.08) to[out=180-X,in=X] ++(200-X:0.3) --++(0,0.01) to[out=X,in=180-X] cycle;

endscope

clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
foreach Y in -5,0,5
mouse[shift=([yshift=-9ex,xshift=Y em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
foreach X in -5,0,5

mouse[shift=([yshift=-4ex,xshift=X em]frame.south)]
endscope


begindocument
beginmousebox
We love cheese!
endmousebox
beginmousebox
blindtext
endmousebox
enddocument


enter image description here






share|improve this answer

























  • Hm. Are there four marmots standing of each other? Or is this some sort of magical sawing trick?

    – Ulrike Fischer
    Mar 16 at 19:24






  • 2





    You should shuffle the bottom parts.

    – Ulrike Fischer
    Mar 16 at 19:28












  • @UlrikeFischer I am not that cruel.

    – marmot
    Mar 16 at 19:28






  • 1





    +1: Can you explain what the mistake from the OP was?

    – Dr. Manuel Kuehner
    Mar 16 at 19:37






  • 1





    @Dr.ManuelKuehner She forgot whiskers and teeth. ;-)

    – marmot
    Mar 16 at 19:41










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%2f479831%2fwhy-does-overlay-work-only-on-the-first-tcolorbox%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









11














Oh no! No marmot on the second box! This has to be rectified! (As mentioned by @samcarter, the marmot got clipped away. But one can shift her or him back to visible region.)



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



Some other tikzlings joined the party.



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
koala[shift=([yshift=-7ex,xshift=-5em]frame.north)]
mouse[shift=([yshift=-7ex,xshift=5em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
koala[shift=([yshift=-4ex,xshift=-5em]frame.south)]
mouse[shift=([yshift=-4ex,xshift=5em]frame.south)]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



And a cheesebox tends to attract mice (with important input by @samcarter in the chat).



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmousebox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
underlay=%
begintcbclipinterior
fill [yellow]
(interior.south west) rectangle (interior.north east);
path let p1=($(interior.north east)-(interior.south west)$)
in [/utils/exec=pgfmathtruncatemacroNX1+x1*1pt/3cm
pgfmathtruncatemacroNY1+y1*1pt/2cmxdefNXNX
xdefNYNY];
foreach X in 1,...,NX
foreach Y in 1,...,NY
foreach x/y/r in 0.4/0.6/0.3,
0.5/1.3/0.2,%
1.5/0.5/0.4,%
1.5/0.5/0.4,%
2.1/1.5/0.3,%
2.5/0.8/0.2,%
3.3/1.1/0.3
shade[ball color=yellow!80!orange,opacity=0.2]
(x+(X-1)*3,y+(Y-1)*2) circle (r);

endtcbclipinterior,
,
%colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
foreach Y in -5,0,5
beginscope[shift=([yshift=-9ex,xshift=Y em]frame.north)]
path[fill=gray!50]
(0.5, 1.8) .. controls (0.5, 1.58) and (0.2, 1.25) .. (0, 1.16) .. controls (-0.2, 1.25) and (-0.5, 1.58) .. (-0.5, 1.8) .. controls (-0.34, 2.3) and (0.34, 2.3) .. (0.5, 1.8) -- cycle;
path[fill=gray!50!black] (0, 1.248) circle (0.09);
foreach X in 10,20,33%
fill[gray!50!black] (0,1.2) + (X:0.08) to[out=X,in=180-X] ++(X-20:0.3) --++(0,0.01) to[out=180-X,in=X] cycle (0,1.2) + (180-X:0.08) to[out=180-X,in=X] ++(200-X:0.3) --++(0,0.01) to[out=X,in=180-X] cycle;

endscope

clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
foreach Y in -5,0,5
mouse[shift=([yshift=-9ex,xshift=Y em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
foreach X in -5,0,5

mouse[shift=([yshift=-4ex,xshift=X em]frame.south)]
endscope


begindocument
beginmousebox
We love cheese!
endmousebox
beginmousebox
blindtext
endmousebox
enddocument


enter image description here






share|improve this answer

























  • Hm. Are there four marmots standing of each other? Or is this some sort of magical sawing trick?

    – Ulrike Fischer
    Mar 16 at 19:24






  • 2





    You should shuffle the bottom parts.

    – Ulrike Fischer
    Mar 16 at 19:28












  • @UlrikeFischer I am not that cruel.

    – marmot
    Mar 16 at 19:28






  • 1





    +1: Can you explain what the mistake from the OP was?

    – Dr. Manuel Kuehner
    Mar 16 at 19:37






  • 1





    @Dr.ManuelKuehner She forgot whiskers and teeth. ;-)

    – marmot
    Mar 16 at 19:41















11














Oh no! No marmot on the second box! This has to be rectified! (As mentioned by @samcarter, the marmot got clipped away. But one can shift her or him back to visible region.)



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



Some other tikzlings joined the party.



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
koala[shift=([yshift=-7ex,xshift=-5em]frame.north)]
mouse[shift=([yshift=-7ex,xshift=5em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
koala[shift=([yshift=-4ex,xshift=-5em]frame.south)]
mouse[shift=([yshift=-4ex,xshift=5em]frame.south)]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



And a cheesebox tends to attract mice (with important input by @samcarter in the chat).



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmousebox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
underlay=%
begintcbclipinterior
fill [yellow]
(interior.south west) rectangle (interior.north east);
path let p1=($(interior.north east)-(interior.south west)$)
in [/utils/exec=pgfmathtruncatemacroNX1+x1*1pt/3cm
pgfmathtruncatemacroNY1+y1*1pt/2cmxdefNXNX
xdefNYNY];
foreach X in 1,...,NX
foreach Y in 1,...,NY
foreach x/y/r in 0.4/0.6/0.3,
0.5/1.3/0.2,%
1.5/0.5/0.4,%
1.5/0.5/0.4,%
2.1/1.5/0.3,%
2.5/0.8/0.2,%
3.3/1.1/0.3
shade[ball color=yellow!80!orange,opacity=0.2]
(x+(X-1)*3,y+(Y-1)*2) circle (r);

endtcbclipinterior,
,
%colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
foreach Y in -5,0,5
beginscope[shift=([yshift=-9ex,xshift=Y em]frame.north)]
path[fill=gray!50]
(0.5, 1.8) .. controls (0.5, 1.58) and (0.2, 1.25) .. (0, 1.16) .. controls (-0.2, 1.25) and (-0.5, 1.58) .. (-0.5, 1.8) .. controls (-0.34, 2.3) and (0.34, 2.3) .. (0.5, 1.8) -- cycle;
path[fill=gray!50!black] (0, 1.248) circle (0.09);
foreach X in 10,20,33%
fill[gray!50!black] (0,1.2) + (X:0.08) to[out=X,in=180-X] ++(X-20:0.3) --++(0,0.01) to[out=180-X,in=X] cycle (0,1.2) + (180-X:0.08) to[out=180-X,in=X] ++(200-X:0.3) --++(0,0.01) to[out=X,in=180-X] cycle;

endscope

clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
foreach Y in -5,0,5
mouse[shift=([yshift=-9ex,xshift=Y em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
foreach X in -5,0,5

mouse[shift=([yshift=-4ex,xshift=X em]frame.south)]
endscope


begindocument
beginmousebox
We love cheese!
endmousebox
beginmousebox
blindtext
endmousebox
enddocument


enter image description here






share|improve this answer

























  • Hm. Are there four marmots standing of each other? Or is this some sort of magical sawing trick?

    – Ulrike Fischer
    Mar 16 at 19:24






  • 2





    You should shuffle the bottom parts.

    – Ulrike Fischer
    Mar 16 at 19:28












  • @UlrikeFischer I am not that cruel.

    – marmot
    Mar 16 at 19:28






  • 1





    +1: Can you explain what the mistake from the OP was?

    – Dr. Manuel Kuehner
    Mar 16 at 19:37






  • 1





    @Dr.ManuelKuehner She forgot whiskers and teeth. ;-)

    – marmot
    Mar 16 at 19:41













11












11








11







Oh no! No marmot on the second box! This has to be rectified! (As mentioned by @samcarter, the marmot got clipped away. But one can shift her or him back to visible region.)



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



Some other tikzlings joined the party.



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
koala[shift=([yshift=-7ex,xshift=-5em]frame.north)]
mouse[shift=([yshift=-7ex,xshift=5em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
koala[shift=([yshift=-4ex,xshift=-5em]frame.south)]
mouse[shift=([yshift=-4ex,xshift=5em]frame.south)]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



And a cheesebox tends to attract mice (with important input by @samcarter in the chat).



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmousebox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
underlay=%
begintcbclipinterior
fill [yellow]
(interior.south west) rectangle (interior.north east);
path let p1=($(interior.north east)-(interior.south west)$)
in [/utils/exec=pgfmathtruncatemacroNX1+x1*1pt/3cm
pgfmathtruncatemacroNY1+y1*1pt/2cmxdefNXNX
xdefNYNY];
foreach X in 1,...,NX
foreach Y in 1,...,NY
foreach x/y/r in 0.4/0.6/0.3,
0.5/1.3/0.2,%
1.5/0.5/0.4,%
1.5/0.5/0.4,%
2.1/1.5/0.3,%
2.5/0.8/0.2,%
3.3/1.1/0.3
shade[ball color=yellow!80!orange,opacity=0.2]
(x+(X-1)*3,y+(Y-1)*2) circle (r);

endtcbclipinterior,
,
%colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
foreach Y in -5,0,5
beginscope[shift=([yshift=-9ex,xshift=Y em]frame.north)]
path[fill=gray!50]
(0.5, 1.8) .. controls (0.5, 1.58) and (0.2, 1.25) .. (0, 1.16) .. controls (-0.2, 1.25) and (-0.5, 1.58) .. (-0.5, 1.8) .. controls (-0.34, 2.3) and (0.34, 2.3) .. (0.5, 1.8) -- cycle;
path[fill=gray!50!black] (0, 1.248) circle (0.09);
foreach X in 10,20,33%
fill[gray!50!black] (0,1.2) + (X:0.08) to[out=X,in=180-X] ++(X-20:0.3) --++(0,0.01) to[out=180-X,in=X] cycle (0,1.2) + (180-X:0.08) to[out=180-X,in=X] ++(200-X:0.3) --++(0,0.01) to[out=X,in=180-X] cycle;

endscope

clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
foreach Y in -5,0,5
mouse[shift=([yshift=-9ex,xshift=Y em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
foreach X in -5,0,5

mouse[shift=([yshift=-4ex,xshift=X em]frame.south)]
endscope


begindocument
beginmousebox
We love cheese!
endmousebox
beginmousebox
blindtext
endmousebox
enddocument


enter image description here






share|improve this answer















Oh no! No marmot on the second box! This has to be rectified! (As mentioned by @samcarter, the marmot got clipped away. But one can shift her or him back to visible region.)



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



Some other tikzlings joined the party.



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmybox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-7ex]frame.north),whiskers,teeth]
koala[shift=([yshift=-7ex,xshift=-5em]frame.north)]
mouse[shift=([yshift=-7ex,xshift=5em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
marmot[shift=([yshift=-4ex]frame.south),whiskers,teeth]
koala[shift=([yshift=-4ex,xshift=-5em]frame.south)]
mouse[shift=([yshift=-4ex,xshift=5em]frame.south)]
endscope


begindocument
beginmybox
We love TiemphkZlings!
endmybox
beginmybox
blindtext
endmybox
enddocument


enter image description here



And a cheesebox tends to attract mice (with important input by @samcarter in the chat).



documentclassbook
usepackagetikzlings
usepackagemwe

usepackage[most]tcolorbox

newtcolorboxmousebox[1][]%
enhanced,
before skip=30ex,
after skip=10ex,
underlay=%
begintcbclipinterior
fill [yellow]
(interior.south west) rectangle (interior.north east);
path let p1=($(interior.north east)-(interior.south west)$)
in [/utils/exec=pgfmathtruncatemacroNX1+x1*1pt/3cm
pgfmathtruncatemacroNY1+y1*1pt/2cmxdefNXNX
xdefNYNY];
foreach X in 1,...,NX
foreach Y in 1,...,NY
foreach x/y/r in 0.4/0.6/0.3,
0.5/1.3/0.2,%
1.5/0.5/0.4,%
1.5/0.5/0.4,%
2.1/1.5/0.3,%
2.5/0.8/0.2,%
3.3/1.1/0.3
shade[ball color=yellow!80!orange,opacity=0.2]
(x+(X-1)*3,y+(Y-1)*2) circle (r);

endtcbclipinterior,
,
%colback=yellow,
frame hidden,% from https://tex.stackexchange.com/a/247509/101651
% from https://tex.stackexchange.com/a/431760/101651:
overlay=%
beginscope
foreach Y in -5,0,5
beginscope[shift=([yshift=-9ex,xshift=Y em]frame.north)]
path[fill=gray!50]
(0.5, 1.8) .. controls (0.5, 1.58) and (0.2, 1.25) .. (0, 1.16) .. controls (-0.2, 1.25) and (-0.5, 1.58) .. (-0.5, 1.8) .. controls (-0.34, 2.3) and (0.34, 2.3) .. (0.5, 1.8) -- cycle;
path[fill=gray!50!black] (0, 1.248) circle (0.09);
foreach X in 10,20,33%
fill[gray!50!black] (0,1.2) + (X:0.08) to[out=X,in=180-X] ++(X-20:0.3) --++(0,0.01) to[out=180-X,in=X] cycle (0,1.2) + (180-X:0.08) to[out=180-X,in=X] ++(200-X:0.3) --++(0,0.01) to[out=X,in=180-X] cycle;

endscope

clip (frame.north west) -- (frame.north east) -- ++(0,+10ex) --
++(-linewidth,0) -- cycle;
foreach Y in -5,0,5
mouse[shift=([yshift=-9ex,xshift=Y em]frame.north)]
endscope
beginscope
clip (frame.south west) -- (frame.south east) -- ++(0,-10ex) --
++(-linewidth,0) -- cycle;
foreach X in -5,0,5

mouse[shift=([yshift=-4ex,xshift=X em]frame.south)]
endscope


begindocument
beginmousebox
We love cheese!
endmousebox
beginmousebox
blindtext
endmousebox
enddocument


enter image description here







share|improve this answer














share|improve this answer



share|improve this answer








edited Mar 16 at 22:48

























answered Mar 16 at 19:20









marmotmarmot

111k5140264




111k5140264












  • Hm. Are there four marmots standing of each other? Or is this some sort of magical sawing trick?

    – Ulrike Fischer
    Mar 16 at 19:24






  • 2





    You should shuffle the bottom parts.

    – Ulrike Fischer
    Mar 16 at 19:28












  • @UlrikeFischer I am not that cruel.

    – marmot
    Mar 16 at 19:28






  • 1





    +1: Can you explain what the mistake from the OP was?

    – Dr. Manuel Kuehner
    Mar 16 at 19:37






  • 1





    @Dr.ManuelKuehner She forgot whiskers and teeth. ;-)

    – marmot
    Mar 16 at 19:41

















  • Hm. Are there four marmots standing of each other? Or is this some sort of magical sawing trick?

    – Ulrike Fischer
    Mar 16 at 19:24






  • 2





    You should shuffle the bottom parts.

    – Ulrike Fischer
    Mar 16 at 19:28












  • @UlrikeFischer I am not that cruel.

    – marmot
    Mar 16 at 19:28






  • 1





    +1: Can you explain what the mistake from the OP was?

    – Dr. Manuel Kuehner
    Mar 16 at 19:37






  • 1





    @Dr.ManuelKuehner She forgot whiskers and teeth. ;-)

    – marmot
    Mar 16 at 19:41
















Hm. Are there four marmots standing of each other? Or is this some sort of magical sawing trick?

– Ulrike Fischer
Mar 16 at 19:24





Hm. Are there four marmots standing of each other? Or is this some sort of magical sawing trick?

– Ulrike Fischer
Mar 16 at 19:24




2




2





You should shuffle the bottom parts.

– Ulrike Fischer
Mar 16 at 19:28






You should shuffle the bottom parts.

– Ulrike Fischer
Mar 16 at 19:28














@UlrikeFischer I am not that cruel.

– marmot
Mar 16 at 19:28





@UlrikeFischer I am not that cruel.

– marmot
Mar 16 at 19:28




1




1





+1: Can you explain what the mistake from the OP was?

– Dr. Manuel Kuehner
Mar 16 at 19:37





+1: Can you explain what the mistake from the OP was?

– Dr. Manuel Kuehner
Mar 16 at 19:37




1




1





@Dr.ManuelKuehner She forgot whiskers and teeth. ;-)

– marmot
Mar 16 at 19:41





@Dr.ManuelKuehner She forgot whiskers and teeth. ;-)

– marmot
Mar 16 at 19:41

















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%2f479831%2fwhy-does-overlay-work-only-on-the-first-tcolorbox%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

Moe incest case Sentencing See also References Navigation menu"'Australian Josef Fritzl' fathered four children by daughter""Small town recoils in horror at 'Australian Fritzl' incest case""Victorian rape allegations echo Fritzl case - Just In (Australian Broadcasting Corporation)""Incest father jailed for 22 years""'Australian Fritzl' sentenced to 22 years in prison for abusing daughter for three decades""RSJ v The Queen"

Who is our nearest planetary neighbor, on average?Santa Claus flies to the South PoleSeven Spheres of Unequal Mass, a weighing problem with a twistDescribe a large integerFast Mental Calculation of $7.5^7$Math in Space (without the help of celebrities)Find the value of $bigstar$: Puzzle 8 - InequalityWho drinks beer while running anyway?A Crucial DeliveryRanking And AverageHow long will my money last at roulette?

Daza language Contents Vocabulary Phonology References External links Navigation menudaza1242Daza"Dazaga"eeee178086576