{boxes} are the units used by (La)TeX to construct a page by pasting them together horizontally or vertically. A single character from a font is a box, as are the lines of type and the eventual page.

learn more… | top users | synonyms

9
votes
1answer
469 views

Make fireworks with only text

For the holidays, I wanted to follow up to the question about making fireworks with tikz (How can we display fireworks?): How can we make fireworks with only text? I have made a crude attempt below. ...
6
votes
1answer
134 views

Recursion of unknown origin: TeX capacity exceeded, sorry [input stack size=10000]

For some reason, there's a recursive definition in this MWE. Who can find where it goes wrong? \documentclass{article} \usepackage{xcolor} \usepackage{titlesec} \usepackage{tcolorbox} ...
4
votes
1answer
35 views

How to get a centered colored box

I want to create a centered colored parbox, but although I defined boarders using package geometry, the parbox has a greater margin left than right. Thanks for help ...
10
votes
2answers
112 views

Is \c_empty_box intended to be used instead of \mbox{}

At a first glance, I understood \c_empty_box as a replacement of \mbox{} but the following MWE (that points out a weird behavior of \c_empty_box: it is replaced by "æ") gives me serious doubts. ...
5
votes
3answers
105 views

How to make a fixed height-width box with custom padding

I am new to latex, I am trying to include output of TI84 calculator in my document. It is supposed to look like this: Following is what I am able to make. My output's height and width arrange ...
4
votes
2answers
44 views

Uneven spacing between parbox

I have uneven vertical space between two parboxes and between a parbox and beginning of a new text paragraph. How to fix these? Here is a minimum working example. \documentclass{article} ...
7
votes
1answer
84 views

how to use fbox in align mode

I'm trying to highlight the diagonal elements of a matrix by using fbox but I failed. I've searched for the problem, some ppl suggest using tikz. I don't want to use it, so I decided to use fbox{}. ...
2
votes
1answer
97 views

Measure distance from text to bottom margin

I'm making some boxes for providing answers. The box macro takes the height of the box as an argument. I need to measure the remaining space from the line the box starts at, to the bottom of the page. ...
274
votes
7answers
69k views

Remove ugly borders around clickable cross-references and hyperlinks

I know that I can use hyperref to make cross-references and hyperlinks clickable. That makes the clickable areas outlined in fluorescent green, however. How can I make the green boxes go away?
8
votes
2answers
95 views

Is there a way to set a parbox to a minimum height?

I'm looking for a way to make it so that my \parboxes keep a minimum height, similar to CSS min-height, e.g. \mhparbox{\textwidth}{3cm}{...} would ensure that whatever text appears in place of ..., ...
2
votes
1answer
38 views

How to make gradient ellipse title box with border?

I am using the tcolorbox package, and I want to use a gradient ellipse title box with border on the titlepage. It is possible somehow or I have to use another package to manage this?
2
votes
1answer
52 views

TikZ mdframed environment: close box at end of page and continue on next

I used the Excursus environment as a template to create my own box like this: \usepackage[style=1,leftmargin=0pt,rightmargin=0pt,framemethod=TikZ]{mdframed} \newenvironment{boxtype1}{% ...
0
votes
1answer
41 views

Boxes within boxes and line numbering

How can I create framed boxes with two columns, where there is a line numbering on every row where there is something written? (if hard or possible then a number for every line in general) Something ...
4
votes
1answer
153 views

Homework Problem Sheet Template

Could someone make this picture of Homework Problem Sheet Template in sample code in LaTeX with the same font size by the way i already add tow pictures in the front of document to make it more cute ...
115
votes
1answer
21k views

What are the different kinds of boxes in (La)TeX?

I've seen hbox, vbox, mbox, parbox and others used in various code samples. What are the different kinds of box in (La)Tex? Which are suitable for use in LaTeX, as opposed to plain TeX?
9
votes
4answers
1k views

Stretching a framebox over the whole page

Does anyone know how to stretch a (framed) box down to the end of the page? In effect something like \documentclass{scrartcl} \begin{document} sometext ...
8
votes
1answer
199 views

Reuse an image resp. a box in TikZ but have side-effects only once

I have a huge document (a pool of exercise problems) with lots of \input statements (one file per subexercise). In order to not get lost in this mess and easily open files from the PDF, I include a ...
6
votes
3answers
179 views

How to make more than two fancy gradient stripes in tcolorbox?

I use the following fancy tcolorbox definition: \newtcolorbox{mybox}{colframe=black!80,colback=black!10,sharpish corners, skin=bicolor,interior style={left color=black!5,right ...
5
votes
1answer
66 views

Accessing child contents of LaTeX boxes (append/concatenate TeX box material)?

This is somewhat similar to Reading the contents of a box, but with a specifically plain Latex example; I somewhat solved the question while writing the post, so I'll formulate the question like this: ...
56
votes
4answers
2k views

How can I visualize boxes?

This question led to a new package: lua-visual-debug Some of you may know the Web Developer Toolbar for Firefox that can outline the block level elements of a page like this: Is there a way to ...
6
votes
1answer
102 views

box all equations of align environment, but not the equation numbers

I want to box (like \boxed{} of package amsmath or \Aboxed{} of package mathtools) the entire block of equations from an align (or eqnarray) environment, but not the equation labels. How can I do ...
1
vote
1answer
57 views

Make box in math mode with current math font

The commands $\mathcal{\mbox{$M$}}$ and \mbox{$\mathcal{M}$} produce different output. I would like a replacement for \mbox that creates a box preserving all features of the current font in math ...
4
votes
1answer
73 views

How to modify colbacktitle, coltext in a tcolorbox with AAUsidebar theme?

I'd like to produce a presentation with beamer. I use the AAUsidebar theme. I want to use my own boxes that I defined with \newtcolorbox. But, I can't not modify the background colour of the title ...
1
vote
1answer
35 views

Boxed equation on the right and its verbatim on the left

How to write a verbatim form of an equation on the left and its output form on the right inside a box?
4
votes
2answers
175 views

How can I draw a box around this?

MWE: \documentclass[11pt,a4paper]{article} \usepackage[utf8]{inputenc} \usepackage[english]{babel} \usepackage{amsmath} \usepackage[margin=3cm]{geometry} \begin{document} \paragraph*{Problem 1} This ...
0
votes
0answers
28 views

Lines with `shorten >` don't count towards image size [duplicate]

I use the technique mentioned here to extend a line through two points: using shorten > and shorten < with negative values. However, the part of the lines that is generated by theses shorten ...
6
votes
1answer
51 views

Why hyperref's \url may be used in preamble within a macro but not within a box?

The following MWE, where a macro involving hyperref's \url is defined in the preamble, works like a charm: \documentclass{article} \usepackage{hyperref} % ...
3
votes
1answer
40 views

Create page break for entire frame without breaking the text flow

I'm including a large, one page box using framed package, with simplest example being: \documentclass{report} \usepackage{framed} \begin{document} Some text ...
2
votes
1answer
76 views

Beamer-Using resizebox changes the position of an item in itemize

I am creating a presentation using beamer. In an itemize environment, I am using resizebox in particular item. When I use it, the position of the bullet changes, as seen in the next image My code ...
2
votes
1answer
23 views

longtabu and rotatebox resulting on too wide table

I'm trying to produce a fixed full-width table, that can potentially span multiple pages. I found that rotating headers with \rotatebox messes up the dimension computation, but I can't find a way to ...
2
votes
1answer
42 views

Building a box for side calculations

I am doing a math assignment, and want to place a box next to my calculations for side calculations. I tried to use the tabular environment, but then there is a huge space besides the box, and the ...
5
votes
2answers
3k views

How to make a textbox with this TikZ code ?

I made this with TikZ : \usetikzlibrary{calc} \def\banlen{3} \xdefinecolor{mycolor}{RGB}{62,96,111} % Neutral Blue \def\bancolor{mycolor} \begin{tikzpicture} \draw (0.25,0.25) rectangle (5,-2); % ...
1
vote
0answers
192 views

How could I use scalebox to rescale a table such that it fits exactly in the usable page width (i.e., between the margins)?

How could I use scalebox to rescale a table such that it fits exactly in the usable page width (i.e., between the margins)? Is there some way in which something such as \hsize could be used as an ...
5
votes
1answer
1k views

How to increase the size around text in \psframebox

when using \psframebox the size between text and corners of the box is really small. Is there a way to increase that? My minimal example: \documentclass[dvips]{article} \usepackage{pst-all} ...
8
votes
2answers
3k views

How do I make one minipage the same size as another?

I'm writing a LaTeX document into which I want to put two boxes, in a row next to each other, which will contain varying length content. I want each box to be the same height, and that height needs ...
6
votes
1answer
3k views

How to control the vertical height of boxes

I would like to create boxes where I can control the height of the boxes. Right now I have used the command. \colorbox{calcclr}\makebox[\textwidth-2\fboxsep][l]{#1}}} This gives me a box that ...
3
votes
1answer
5k views

Problem with positioning a figure environment inside \resizebox

I'm writing a document including figures exported from Inkscape (in pdf+latex format). These figures use a figure environment containing all the text labels and a \includegraphics macro that imports ...
2
votes
1answer
480 views

How to put part of a TikZ graphic into a box to measure its size

After adding support for tooltips today in pdfcomment (\pdftooltip) I wanted to make a TikZ example with tooltip annotations. Within \pdftooltip the annotated element is set into a box to measure the ...
1
vote
1answer
294 views

Change size of whole set of elements

I am trying to include some gnuplot-generated figures using the epslatex terminal, which creates an .eps file and a .tex file. The way to include these figures in the document is writing ...
3
votes
1answer
87 views

Controlling height of box

I am currently using the code \newsavebox{\FVerbB} \newenvironment{code} {\VerbatimEnvironment \hspace{-0.25cm} \begin{lrbox}{\FVerbB} \hspace{-0.29cm} \begin{BVerbatim}} {\end{BVerbatim} ...
6
votes
2answers
138 views

Unify the size of two tables

How can I unify the table size and the font size for these two tables \documentclass{article} \usepackage{graphicx} \begin{document} % Table 1 \begin{table}[h] \resizebox{\textwidth}{!}{% ...
5
votes
1answer
123 views

Bounding box is larger than expected when drawing in 3D

This is a semi-duplicate of this question I think, but the answers provided there don't seem to work for me with 3D pictures. I'm inputting a tikz picture into a beamer poster, but I think that part ...
5
votes
0answers
895 views

Fitting TikZ picture in beamer: Difference between using \resizebox and \adjustbox? [closed]

\documentclass[10pt]{beamer} \usepackage{amsmath} \usepackage{amssymb} \usepackage[english]{babel} \usepackage{color} \usepackage{float} \usepackage[T1]{fontenc} ...
2
votes
1answer
62 views

Increasing the size of \square?

Beginner here! All I want to do is make a couple of boxes on my document. I'm currently using this: \makebox[10pt][l]{$\square$}\raisebox{.15ex}{\hspace{0.4em}$\texttt{1}$} but I need to make the ...
7
votes
2answers
417 views

Measure the column width of a table

Is there a way to determine the width of the first column in a tabular enviroment? I've thought about using a savebox but that would only give me the size of the text (and in one cell only), not the ...
5
votes
3answers
146 views

How could a verbatimtab environment in a figure environment be resized (perhaps using the package adjustbox)?

How could a verbatimtab environment in a figure environment be resized (perhaps using the package adjustbox)? I have some code something like the following: \begin{figure}[htb] \centering ...
3
votes
2answers
53 views

Automatically add \vfill for breakable tcolorbox

I'm using tcolorbox with nested tcolorboxes, the upper level ones being breakable. Here is an example. \documentclass{article} \usepackage{lipsum} \usepackage{tcolorbox} ...
3
votes
1answer
48 views

Boxes with two different border widths

I'm making a box with text inside. For it I use the package mdframed. Essentially I want a box with the left border width 2pt and the rest of the borders width 1pt. What I've got so far: ...
8
votes
2answers
543 views

Making the text fit in a specific space in Latex

I'm trying to fit my text in a specific space, as it's a Graph explanation. I would like to make something like the graph below: Is it possible to make the text fit in that space? LaTex does it by ...
3
votes
1answer
188 views

How to make an empty box

I am making a sheet where people can fill in answers of various types. For this I would like to make some boxes of certain width and height. How can this best be done? I use \fbox when I want to box a ...