Questions tagged [parbox]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
2 answers
30 views

Imposing similar heights for boxes using \parbox

I am trying to impose similar heights for 2 different boxes. I am trying to use \parbox but this doesn't work very well since the boxes have still different heights : \documentclass{beamer} \...
  • 391
0 votes
2 answers
34 views

How to correct vertical spacing after multiple side-by-side parboxes?

I use a \dated macro to put a date at the end of the line with some text left of it, using two parbox. When the text uses only a single line, the spacing underneath this construct looks fine. But when ...
  • 945
2 votes
1 answer
52 views

parbox inner vertical-align "b" causes unexpected vertical white space

In the following codes, I put something into a lrbox named mybox. Then the content of the box is typeset by a parbox with three inner vertical-align modes - c, t and b. For t and c, the typeset is ...
  • 2,639
2 votes
1 answer
37 views

Tikzposter - Stretching the title box to accommodate a long title

I have a long title for my tikzposter, which I want to keep all on one line for the sake of the poster's spacing. What I have now is this: \centering \settitle{ \parbox{\linewidth}{ \centering \...
  • 21
2 votes
2 answers
165 views

fbox without vspace

I am going to give a definition of a problem as follows. \newcommand{\defproblem}[3]{ \vspace{4mm} \noindent\fbox{ \parbox{0.98\textwidth}{ #1 \\ \textbf{...
  • 243
1 vote
2 answers
33 views

How do you center parbox vertically in a table

I created a table with images in them. However I want the first column to have text and it should be centered vertically and the text should be rotated 90degrees. To do this, I used a parbox however I ...
  • 15
0 votes
0 answers
19 views

Vertical centering using \longtable together with \parbox and in-table equations with enumeration [solved]

I am writing a multipage table using the \longtable package, and it includes equations within the cells of one columns. Since I want to preserve the document equation enumeration for later referencing ...
  • 161
0 votes
1 answer
72 views

tcolorbox overflowing text when using parbox=false

I have the problem that when I add parbox=false to the options of tcolorbox, the text within the box is not breaking properly. Do you have an idea what might be the issue? Here is the code: \...
  • 103
0 votes
1 answer
27 views

Alignment of overflowing rotated \parbox

I am looking to achieve the following within a figure: A main graphics element which occupies the full \linewidth Rotated text labels on the left and on the right, vertically centered with graphics, ...
  • 135
0 votes
3 answers
44 views

On moving a parbox generated by p{width} to the very right in a tabular

Let us focus on the following code: \documentclass{book} \begin{document} \begin{tabular} {|l| r@{}@{\hspace{0.3em}} |l|r|} %-------------------------------------------------------------------- \...
  • 1,503
0 votes
0 answers
32 views

Thesis cover formatting

I need to put on the cover of my work: a picture, the name of the university, and another picture (logo). But the figures are one below the other (I need everything in the same line). I'm trying the ...
0 votes
2 answers
65 views

LaTex - Table formatting (multicolumn, multirow, parbox)

I have created the table below. However, there are some formatting problems that I can't get fixed. \documentclass[9pt,twocolumn]{article} \usepackage{tabularx} \usepackage[format=plain, indention=...
  • 1
0 votes
1 answer
56 views

Height of \parbox can not be assigned with condition?

I want to assign the height of my \parbox with condition, as I did below, but fail. Why and how to deal with it? Code: \documentclass[a4paper]{article} \usepackage{etoolbox} \usepackage{geometry} \...
  • 2,639
0 votes
0 answers
64 views

Unusual Illegal unit of measure (pt inserted) in table involving tabular and subcaption

I have weird Illegal unit of measure (pt inserted) error that I cannot get rid off for some reason. The error occurs in tables that look like the one below (text details changed to xx). I haven't ...
  • 133
0 votes
1 answer
61 views

How to merge cells made by \parbox vertically

\documentclass[a4paper]{article} \usepackage{xcolor,pgf,etoolbox} \usepackage{geometry} \geometry{showframe} \geometry{left=1cm,right=1cm,top=1cm,bottom=1cm} \parindent0pt \begin{document} \fboxsep0pt ...
  • 2,639
0 votes
1 answer
45 views

Width of parbox inside colorbox

I want to insert a colorbox into a margin paragraph. parbox is used to keep the line breaks. What value should I pass to \parbox's width so it doesn't get too wide as it does now? \documentclass{book}...
  • 416
0 votes
1 answer
64 views

How to store/append code for later use

To store some code for later use, I can think of two ways: \appto from etoolbox and \sbox. They both have some problems in use. For \appto, later invoke of a macro will cover the value of the former, ...
  • 2,639
3 votes
1 answer
82 views

tikzcd inside parbox

\documentclass{article} \usepackage{tikz-cd} \begin{document} \parbox{\textwidth}{\[ \begin{tikzcd} a \arrow{r}{} & b \end{tikzcd} \]} \end{document} The MWE above throws a ...
  • 1,986
1 vote
2 answers
107 views

How to make all \parbox with same height

Running the following MWE will get an ugly typeset which I think is for the reason of different heights of all thees\parboxs. My question is: As the contents of all \parbox cannot be foreseen, how to ...
  • 2,639
1 vote
1 answer
55 views

How to insert a margin inside a double frame parbox?

I simply would like to insert a bit of space inside my parbox, but the following mess up with the frames: \documentclass{article} \begin{document} \begin{center} \fbox{ \setlength\fboxsep{...
  • 1,213
0 votes
0 answers
46 views

tabu and extra vertical space for tall equation

Q: Why tabu adds extra vertical space before first line of cell contents if the second line of a paragraph is too tall? MWE below contains three use cases: tabular (from array) approach with p{} ...
  • 253
0 votes
1 answer
76 views

Struggling with parboxes' width and placement in TikZ

I am trying to update my own resume/cv in LaTeX. I haven't needed to typeset anything in several years, so my LaTeX is very, very rusty. I took a look at several "cv" classes I like (limecv, ...
1 vote
2 answers
158 views

What's the difference between [position]] and [inner-pos] parameters in \parbox?

I am trying to understand the documentation of \parbox (documentation link: http://www.emerson.emory.edu/services/latex/latex_147.html). However, I don't understand the difference between [position] ...
0 votes
0 answers
33 views

Parbox figure and linespacing adjustments

I need a table of 5 columns where the last column contains figures. When I use \parbox , the spacing between lines increases and the figures are not aligned under the lat column. How can I fix it ...
1 vote
2 answers
60 views

Make the line down in parbox

Why do I get a line in the middle? \documentclass{article} \begin{document} %%\parbox[alignment][height][inner-alignment]{width}{text} The answer is:\parbox[c][][b]{2cm}{\hrulefill}.\par \end{...
1 vote
2 answers
152 views

\parbox with stretchable height

I am trying to create a framed \parbox that stretches to fill the available space. I have tried \fbox{\parbox[c][0pt plus 1fill][t]{3in}{...Content...}} but the \parbox doesn't seem to stretch at all....
0 votes
1 answer
73 views

What is the distance to right margin in nested aligned and enumerate environments?

I am using the \aligned environment within an \enumerate setup for formatting my assignment submissions. I have tried using the \align*, \flalign*, and \alignat environments but they didn't behave ...
  • 101
1 vote
1 answer
69 views

Why does adding a \label at the beginning of a \parbox affect its layout?

I was surprised to notice that adding a \label at the beginning of a parbox changed the layout of its contents: \documentclass{article} \begin{document} A\parbox[t]{3em}{\tiny B\\C} (no label) A\...
  • 3,934
1 vote
1 answer
72 views

Suppress counting of fbox, parbox, minipage as table

I am running into an issue where either the fbox, parbox, or minipage is being counted as a table. As an example, I have added sample code that is similar to my setup. This code results in the first ...
1 vote
1 answer
119 views

Can I avoid indentation of margin items when using parbox=false in a tcolorbox?

For a book project, examples, theorems, etc. are all styled using tcolorbox. (This part is not really negotiable -- the LaTeX code is generated by PreTeXt.) I've been trying to figure out how to get ...
0 votes
2 answers
304 views

Multi-line explanation including math and text next to equation in Overleaf

I saw two answers1 2 suggesting the use of \parbox in an \align* environment in order to type some long explanation next to an equation progression. I want this explanation to include a math ...
  • 115
1 vote
1 answer
40 views

Extend tabular signature lines to a prior parbox width automatically

My universities thesis style requirements dictate that a declaration page is furnished with information boxes (signature etc.). I can extend the signature lines to the end of the \parbox boundary ...
user avatar
0 votes
1 answer
62 views

Text out of fbox

What I'm trying to do is to put an equation inside an fbox. Here's my MWE: \documentclass[12pt]{article} \usepackage[italian]{babel} \usepackage[utf8x]{inputenc} \usepackage{amsmath, amsthm, amssymb, ...
1 vote
1 answer
63 views

Tikzpictures and parbox inside an enumerate environment, how do I align everything to the top?

I start showing what I got and what I would like to achieve: My code is the following: \begin{enumerate}[(i)] \item \begin{tikzpicture}[scale=0.6,every node/.style={draw=black,circle}] \...
0 votes
0 answers
22 views

Missing number, treated as zero within simple parbox/spacebox macro

I have a macro using parbox, spacebox, and some simpler whitespace. This generates a "Missing number, treated as zero." error for every time I use the macro. It still compiles to a PDF ...
  • 1
0 votes
2 answers
118 views

How to place boxed text next to an image of the same height?

I'd like to mimic the following style: having an image of an author next to a textbox of the same height. However, my attempt is humorously unsettling: It appears that the aspect-ratio of my face ...
  • 103
1 vote
1 answer
51 views

Inconsistent paragraph spacing with \parbox for custom design

I am working on a project that requires generating latex code programmatically from a JSON file, which contains a transcribed conversation. The design of the final goal is non-standard. It requires ...
0 votes
1 answer
229 views

Pagebreak in \parbox

is there a possibility to allow pagebreaks within a \parbox environment? Here's the example \documentclass{article} \pdfpageheight=10cm \begin{document} \centering \parbox{5cm}{ Lorem ipsum dolor sit ...
2 votes
1 answer
51 views

Parbox won't stay vertically centered in some cases

I thought I had finally understood vertical alignment behavior of parboxes, but then this happened: I have this tabularx with parboxes inside and broke my case (in XeLaTeX) down to this minimal ...
1 vote
1 answer
38 views

aligning text level of text and parbox where text is wrapped

I would like this: With the Tex code at the bottom I obtain this: Tex code: \documentclass{article} \usepackage[utf8]{inputenc} \begin{document} Text1 \> \parbox{0.8\textwidth}{bla bla bla bla ...
2 votes
2 answers
266 views

parbox automatic width calculation

Consider the following MWE: \documentclass[letterpaper]{article} \usepackage{amsmath} \begin{document} \noindent $\begin{aligned}[t] \left( \frac{1}{2}-\frac{1}{4} \right) \left( \frac{1}{2}-\frac{3}...
  • 27.9k
5 votes
2 answers
556 views

Why does a parbox of height zero consume vertical space?

Assume we have a document where we have one paragraph of text, followed by two vspace boxes, followed by another paragraph of text. I thought that I could insert a parbox with zero height between the ...
2 votes
1 answer
139 views

How to draw vertical line with exactly the height of a parbox next to it

I am trying to create small sections for a cv where the section name and a vertical line should be next to the content. The section name should be centered and the vertical line should be exactly the ...
  • 303
1 vote
1 answer
41 views

Sideways cell and normal cell don't align properly in tabularx

I'm trying to make a table where the first two columns should have their content rotated 90 degrees (sideways), the third normal (written horizontally), and the last one should have a \multirow with ...
  • 515
0 votes
1 answer
105 views

\textls letterspacing and parbox

I have a hack for fitting as much text as possible in a 2-line parbox using \textls (microtype package). Here is the code: \documentclass{article} \usepackage[latin1]{inputenc} \usepackage[cyr]{...
0 votes
0 answers
334 views

Indents and spacings starting a line are ignored in parbox

When inside a \parbox, indents and spacings (like \indent, \quad, \hspace{}, etc...) are ignored when starting a line. For example, this code: \parbox[t]{10cm}{ \indent indent does not work \\ ...
3 votes
1 answer
333 views

Why does \raggedright not work inside a minipage in this case?

In trying to suppress underfull box warnings in annotations to equations in align environments, I'm experimenting with \raggedright. I've discovered that it works inside a \parbox but not inside a ...
0 votes
0 answers
53 views

Problems with aligning in \parbox and \rule alignment

I'm using the Twenty Seconds Resume/CV: https://www.latextemplates.com/template/twenty-seconds-resumecv https://www.overleaf.com/latex/templates/twenty-seconds-curriculum-vitae/kfgsngtymkfj However I ...
  • 3
0 votes
0 answers
24 views

\raggedleft in conjunction with \\ not working in header

I am really struggling with the last change in my thesis regarding the header. The header is defined in the template I have to use like this: \def\@evenhead{\parbox{\textwidth}{ {\thepage\hfill~\...
2 votes
1 answer
42 views

Help in placing "2 parboxes in a single Row" in Bulleted or numbered Items

I want to make a book which has many instructions for solving mathematical problems and equations. It describes each step for equation solving. There are many steps. Each step is different item. The ...