Skip to main content

New answers tagged

2 votes
Accepted

Unwanted space in tcbraster

you need before title={\hspace*{-5ex}\makebox[5ex]{#1.}},% with a starred \hspace, to avoid that you loose the negative space in some cases.
Ulrike Fischer's user avatar
1 vote

Unwanted space in tcbraster

I'm not sure what you're doing with titles, because \notblank{#1}{}{} will execute nothing at all. Anyway, removing all unnecessary % and \left–\right commands, I get no issue. You can see that ...
egreg's user avatar
  • 1.1m
0 votes

Unwanted space in tcbraster

Have a look to this solution: \documentclass{article} \usepackage{tcolorbox} \tcbuselibrary{raster} \newtcolorbox{mybox}[1]{% }% \begin{document}% \begin{tcbraster}[% raster left skip=0.05\...
scd's user avatar
  • 764
1 vote

Keep track of theorem number in colored boxes

The tcolorbox package has a library for theorem. See section 18 of the manual. The library has the command \NewTcbTheorem[⟨init options⟩]{⟨name⟩}{⟨display name⟩}{⟨options⟩}{⟨prefix⟩} that define a ...
Alain Remillard's user avatar
4 votes
Accepted

What does \vphantom{dlg} do in the tcolorbox documentation?

The rotated “LIB” is typeset as an overlay, so it reserves no space. In the following example I renamed Thomas Sturm's \mylib to \hislib and redefined \mylib without the \vphantom{dlg}. \documentclass{...
egreg's user avatar
  • 1.1m
5 votes
Accepted

Record some tcolorbox in order to print at the end of each chapter

You can define a dedicated style, such as \tcbset{% first use/.style={ saveto=\jobname_meth-\thetcbcounter.tex, record={% \string\begin{meth}{}{}% \string\input{\jobname_meth-\...
jlab's user avatar
  • 3,911
0 votes

\tcolorboxenvironment with parameters

Define your own specialized command and a suitable style. \documentclass{article} \usepackage{amsthm, thmtools} \usepackage[dvipsnames]{xcolor} \usepackage{tcolorbox} \tcbuselibrary{skins} \...
egreg's user avatar
  • 1.1m
1 vote

\tcolorboxenvironment with parameters

You just need to expand the argument once. You can do this with \ExpandArgs{no}. The n says to leave the first argument of \tcolorboxenvironment alone, and the o says expand the second argument once. \...
mbert's user avatar
  • 4,506
2 votes
Accepted

Nesting two environments

You can use \tcolorboxenvironment. \documentclass{article} \usepackage{amsthm} \usepackage{tcolorbox} \usepackage{lipsum} \newtheoremstyle{mystyle} {0ex} {0ex} {} {} {\bfseries} {} {1....
egreg's user avatar
  • 1.1m
2 votes

Nesting two environments

\documentclass{article} \usepackage{amsthm} \usepackage{tcolorbox} \usepackage{lipsum} \newtheoremstyle{mystyle}{0ex}{0ex}{}{}{\bfseries}{}{1.5ex}{\llap{\thmnumber{#2}\hskip2mm}\thmname{#1}\thmnote{ \...
hair-splitter's user avatar
1 vote
Accepted

tcolorbox in a multicol environment sometimes breaks in the wrong place

Here is a flowfram way to create 3 columns. \documentclass[a4paper,11pt]{article} \renewcommand{\familydefault}{\sfdefault} \usepackage[left=1.5cm,top=1.5cm,right=1.5cm,bottom=1.5cm]{geometry} \...
John Kormylo's user avatar
  • 81.1k
1 vote
Accepted

How to create two or more \tcolorboxenvironment for the same environment?

Your proof environments are not numbered, so I don't know what you mean with your second question about refering to them. But because you should never mix several questions into one, I would recommend ...
cabohah's user avatar
  • 14k
3 votes
Accepted

Fit tcolorbox to table

Since you have a note inside the table I'd use threeparttable, setting no border separators for the tcolorbox: \PassOptionsToPackage{usenames,dvipsnames,svgnames,table,cmyk,x11names}{xcolor} \...
CarLaTeX's user avatar
  • 64.7k
2 votes

Special characters in \lstinline cause an error when used in tcbox

As said in comments, create a suitable box with \NewTotalTCBox: \documentclass{article} \usepackage{listings} \lstdefinestyle{LaTeX-inline}{ language=[LaTeX]TeX, basicstyle=\linespread{1}\...
samcarter_is_at_topanswers.xyz's user avatar

Top 50 recent answers are included