Questions tagged [parbox]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2
votes
2answers
60 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}...
5
votes
2answers
133 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
1answer
51 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 ...
1
vote
1answer
35 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 ...
0
votes
1answer
46 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
0answers
29 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
1answer
85 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
0answers
24 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 ...
0
votes
0answers
18 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
1answer
35 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 ...
2
votes
2answers
35 views

Using overbrace with parbox in equations

I'm trying to use overbrace with parbox in an equation, but haven't been very successful. Any ideas on how to properly do it? \documentclass[10pt]{beamer} \usetheme[progressbar=frametitle]{...
2
votes
1answer
115 views

Center a \parbox or \minipage vertically

I'm not sure if I understand it correctly, but with pos=c either a parbox or a minipage should vertically align the baseline of the center line with the baseline of the text outside? However, what ...
4
votes
3answers
262 views

How to automatically linebreak an inline math formula?

Here is an example of a parbox that produces both an underfull and an overfull warning: \parbox{100pt}{A set of comparison triplets \(T = \{ (i,j,l) | z_i \;is\; more\; similar\; to\; z_j\; than\; z_l\...
2
votes
0answers
36 views

tcolorbox is measuring the wrong height when a parbox follows

Awhile back, I learned how to measure the y coordinate in my pdf. I've recently run into a combination of parbox, tcolorbox, and XeLaTeX that is giving me bad results. In the following example, \...
0
votes
1answer
24 views

Multi-line rows in a table are too close together

For a scientific paper I use the llncs layout. There I have created a table with tabular. The first column of this table should take half of the text width. The content of this first column can be of ...
0
votes
1answer
45 views

Parbox for longtext

I'm looking for basic way of placing long text into parbox or some other box which will break the page if needed. Please take a look at my code. What is wrong? \documentclass{article} \usepackage[...
-1
votes
1answer
109 views

Recreate Word document to include inside .tex

I would like to include 3 pages of a word document (an Informed Consent for my studies) in my .tex document. I could include each PDF but I would like to know how can I recreate the document in TeX ...
4
votes
1answer
42 views

How to reserve the exact text size for the next frame

how to reserve the exact size of the response text for the next frame (when I use siunitx and animateinline combined). \documentclass{beamer} \usepackage{amsmath,amsthm,amsfonts,amssymb} \usepackage[...
0
votes
1answer
55 views

Two columns of matching text

I'm formatting a translated book. There is a section where there is a poster that consists of two columns of related text. The various paragraphs, or in some cases, groups of paragraphs, match up with ...
0
votes
2answers
80 views

Style questions by using \multirow and \parbox for getting a nicely formatted table

The following situation gives me a lot of headache: 1) I would like to use \parbox to have also block text in the multirow areas. With the code below this doens't work. I tried to combine \parbox and \...
0
votes
0answers
61 views

How to turn off automatic text justification in a \parbox?

The following code produces the result in the picture below. How can I avoid text justification at the line that starts with "Create Challenge"? I have tried to apply what is suggested here but it ...
1
vote
1answer
57 views

Line spacing not working in title created using a parbox

I am having some problems with the line spacing on my title page. My title is placed in a parbox and it was all fine until the title went more than 3 lines and then it became all squished up. Code and ...
-1
votes
1answer
65 views

how to center rotatetext parbox?

the code below puts the text MNIST not at center. I want to center it align it with the text SSIM. I change parbox to different values of cm but nothing change. How ? \begin{figure}[t] \...
0
votes
1answer
27 views

Add margin to new lines in parbox

My table \begin{table*}[!t] \ra{1.3} \caption{Well-known scheduling performance measures.}\label{tab:objectives} \centering \resizebox{\textwidth}{!}{\begin{tabular}{@{}llll@{}} \toprule \...
1
vote
2answers
130 views

How to align text and picture with parbox?

I would like to align the top of the picture with the top of the text using parbox. When I compile the following code with LuaTeX, Version 1.10.0 TeX Live 2019/W32TeX format=lualatex 2020.2.26 ...
0
votes
2answers
72 views

Annoying ghost column after parbox

So I've previously asked a question regarding figures and tikzpictures inside boxes from the TeX macro package insbox. I got a working MWE, but implementing it in my full document made me realise ...
0
votes
0answers
42 views

How to center a caption in Table* spanning multiple columns using \parbox?

I have two tables that must be placed side by side and spanning both columns of an article. To do so, I've written the following code: \begin{table*}[!ht] \parbox{.40\linewidth}{ \hfill{}...
1
vote
2answers
52 views

Section heading with shaded background spanning \textwidth, with uniform baseline

I’m trying to adapt one of the answers to this question so that only the section text, and not the section number, has a coloured background. Unfortunately the use of \parbox seems to result in a non-...
0
votes
0answers
68 views

parbox doesn't span text over two columns

In the document I'm writing I need to use a parbox with long text. The problem is that the text inside the parbox doesn't span over two columns. How to make the text inside continue to the next column ...
1
vote
2answers
144 views

How can I present these DNA sequences within a table using \pbox?

I've been stuck on this issue for a while now. I have a table containing some DNA sequences, tabularx couldn't figure out where to hyphenate the sequence and the table ran out of the margins of the ...
1
vote
0answers
332 views

How to resize a parbox depending on the actual text width? [closed]

Context I'm working on a pseudocode package to write algorithms with multiline support. Then, long lines can be broken and the proper identation is handled accordingly. I do the job with parboxes. ...
0
votes
1answer
39 views

vertical alignment of parbox one below the other

I want to align all the parboxes vertically so that the left corners are are equally offset from the dates which are in the left side \documentclass{article} \usepackage{enumitem} \usepackage{...
2
votes
1answer
48 views

Unwanted space between parbox and following paragraph in custom command

I've created a custom command for CV entries. Unfortunately, the spacing between those entries is different, if there is only one line of text in the parbox. The following image shows the problem. My ...
3
votes
2answers
112 views

Same text alignment inside a parbox as the environment where it is

How \parbox could "inherit" the "alignment mode" used in the environment where it is called? In other words, how can I automate the text alignment setting into a \parbox, in order to take the same ...
3
votes
2answers
113 views

Vertically centered material in fixed height rows in tabular environment

The goal is to obtain a table with fixed height rows, and to place the material inside -certain- cells vertically centered. Looking for a robust and simple way, I have worked on this idea: \...
0
votes
0answers
76 views

adjust padding/width of parbox to make space for logos?

I am using the tikzposter class to create a poster for a conference. For conference posters I've typically included two logos, one on either side of the title box, but in this case the box isn't ...
2
votes
1answer
90 views

Alignment of a section in a parbox itself in a tabular cell

Let's go, Here is the result my .tex file gives me now : Here is the result I want : (see the "2" position on the right side, image obtained by replacing \cellcolor{blue!25} \colorbox{green}{\...
2
votes
1answer
189 views

How to make a parbox with rubber width (like \hfill)

I have two parboxes that live next to each other: \parbox[t]{2cm}{Foo!} \hspace{3em} \parbox[t]{12cm}{Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit, vestibulum ut, placerat ...
2
votes
0answers
511 views

fbox of parbox of textwidth length is too wide

I was implementing the code found in this Q/A How to put a long piece of text in a box? to create a command for a paragraph text inside a framed box. However the box goes too far into the margin ...
1
vote
1answer
78 views

Is it possible to redirect unbalanced braces (`{` and `}`) into a tabular column?

This question is a follow up to my previous question: Is it possible to use > and < to pipe opening and closing braces on each side of a cell's content? To be more specific, what I want is to ...
1
vote
1answer
91 views

Space above parbox too small when it has newlines

I have the following MWE: \documentclass{article} \begin{document} qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq \parbox{\linewidth}{ \centering\large AAA qqq XXX \\ qqq AAA qqq } ...
0
votes
2answers
107 views

Some items in enumerate jump left out of margin

I have a boxed list in latex, and for some reason some items jump out of the box out of the left margin. I cannot figure out what is causing this and already have searched and tried some fixes. The ...
0
votes
2answers
127 views

Why \parbox makes inter-word spacing very wide and how to fix it?

How to keep \parbox and at the same time get rid of excessive spacing between words? \documentclass[varwidth]{standalone} \begin{document} \parbox{40mm} { \everypar{\parshape 2 0mm 40mm 5mm ...
1
vote
1answer
164 views

Adjusting perimeter of colorbox to fit text

Consider this MWE: \documentclass[11pt]{article} \usepackage[left=1.5cm,top=2.5cm,right=3.5cm,bottom=3.2cm,a4paper]{geometry} \usepackage{xcolor} \usepackage{adjustbox} \usepackage{setspace} \...
1
vote
1answer
291 views

Using parbox in two column format

I am trying to put two tables side by side in two column format. But I am getting the error ! Missing number, treated as zero. l l.460 \end{tabular*} } ...
0
votes
2answers
143 views

Framed box with only bottom rules and multiple lines inside a table cell

I want to have a table with cells which have multiple lines and bottom rules. I've tried \begin{tabular}{cc} \renewcommand{\arraystretch}{1.5} Title & \parbox{18em}{\centering A very very very ...
4
votes
3answers
497 views

Empty optional argument or Not giving optional argument at all?

I learnt that \parbox has five arguments, that is: \parbox[<align>][<height>][<inner-align>]{<width>}{<text>}. So I constrcut my own \myparbox in which I add \sloppy\...
3
votes
1answer
777 views

Automatically justify text in \parbox

The left part of the attached figure showes the nomal typeset of \parbox. The first/second lines are fully filled with words, and the rest words are bent to the third line. What interests me is: how ...
5
votes
4answers
197 views

How to remove the last line-feed raised by \foreach

As the following example showes, there are an extra line-feed which is not needed. Is there a way to eliminate? Example: \documentclass{article} \usepackage{tikz} \begin{document} \def\mylist{str1,...
0
votes
1answer
91 views

How to make a macro like \parbox with a style of spread align

I'd like to construct a macro like \parbox, but with a style of spread align, as the option [s] in \makebox. That is to say, when the width of text is less than the defined width(only one line of ...