{line-breaking} is about how (La)TeX breaks paragraphs into lines and how those breaks can be influenced.

learn more… | top users | synonyms (1)

1
vote
1answer
21 views

Large Brackets Make Line Breaks too Small

\documentclass[10pt,letterpaper]{article} \usepackage[utf8]{inputenc} \usepackage{mathtools} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{parskip} ...
3
votes
0answers
21 views

linebreaking of name-year citation style in arxiv version

I was trying to submit a manuscript to the arXiv using the imsart package: see here. I am using the name-year citation style, and it works well in my own tex compiler. However the version that the ...
2
votes
2answers
27 views

Aligning multiple lines in long equations and arranging the line breaks in `\align` environment

I have the following code sample: \begin{align} \pi^{(1)}_{i j} \enspace & = \enspace -\frac{1}{4}\eta^{\lambda \sigma} \left( \eta^{\mu \alpha}\eta^{\nu \beta} + \eta^{\mu \beta}\eta^{\nu ...
2
votes
1answer
13 views

In Longtable, In multirow greater than \textwidth

MWE \documentclass[a4paper,12pt]{book} \usepackage[left=1.5cm,right=1cm,top=3cm,bottom=1.5cm,marginparwidth=5.5cm,marginparsep=1cm,outer=8cm]{geometry} \usepackage{array} \usepackage{longtable} ...
1
vote
1answer
57 views

Integral domain on two lines [duplicate]

Consider the following integral: $$\int_{\text{One line \\ Second line}} \text{Loss}\left(\text{Foo, Bar} \vert \alpha\right)$$ which renders: How can I have One line and Second line on two ...
1
vote
1answer
54 views

Automatic fallback from \fussy to \sloppy

If I activate \sloppy document-wide, will the paragraphs that render well with \fussy be affected? If answer to the above is yes, is it possible to have \fussy by default, but automatically enforce ...
9
votes
1answer
390 views

What is the meaning of \fussy, \sloppy, \emergencystretch, \tolerance, \hbadness?

There are many way to influence line breaking, and avoiding overfulls on long unbreakable pieces of text. I'm puzzled. We are told that using \sloppy document-wide is not good , that an alternative ...
2
votes
1answer
54 views

New line avoiding errors and following WYSIWYM philosophy

I understand that using \\ is not a good idea. It's better to use just the "enter" key or the \par command. Anyway, I don't like what I get. I would like to have a blank line between two pieces of ...
0
votes
0answers
48 views

New line, line breaking, `\\`: a definitive answer [duplicate]

In most basic courses of latex, they say that to separate two block of texts, you need to use \\ at the end of the first one. Anyway, this seems to be a bad practice according to lot of people (see ...
0
votes
0answers
26 views

What is the difference between \\, \par, and blank line [duplicate]

Checking today this topic, they talk about the difference between \\, \par, and even a new line. And that people does not know the difference. And indeed, I don't know it. Can you enlight me? And ...
0
votes
1answer
41 views

unbold title and no line break for a subsection

How can we unbold the title of a subsection and suppress the line break, like it was done in the following image? The answers in the duplicate deal with how to do that for all the subsection. I want ...
1
vote
3answers
81 views

How to force a newline

I want to have a new line after a bold written text. Sadly the following LaTeX code does not work (this is my original section): \section{Analyse des Firefox-Source-Code} Der Source Code von Firefox ...
0
votes
2answers
40 views

List of values does not fit line

Have a look at the code below. The list of values for \alpha and \beta are too long to fit one line and the last values of each list disapears. Therefore I want them to break as soon as the edge of ...
2
votes
1answer
44 views

How to make listings package break TeX code only after control sequences?

Package listings always likes to break TeX code after backslashes. How to make it always break before backslashes? \documentclass{article} \usepackage{listings} \begin{document} ...
2
votes
1answer
28 views

Colorful prebreak and postbreak tokens with listings package

I want to get colorful prebreak and postbreak tokens with listings package, but the following code doesn't work: \documentclass{article} \usepackage{xcolor,listings} \begin{document} ...
2
votes
1answer
26 views

What are the rules for placing & while using the split environment?

I have the following equation: \begin{equation} \left\{\left(a,b\right) \mid \right.\left. a \in A, b \in B\right\} \end{equation} And I want to force specific line breaking and alignment using the ...
5
votes
2answers
62 views

line breaks when using ldots

I have a line in my novel which is not breaking in what I would think to be natural places. It appears to be due to my use of ldots: ``It was fine.'' she said, defensively. ``Just\ldots more and ...
2
votes
1answer
46 views

Break URL in figure caption [duplicate]

I'm trying to break a url that is part of the figure's caption. I used \burl but didn't work. What can I do? This is my main code: \documentclass[11 pt, letterpaper, oneside, openright]{book} ...
4
votes
1answer
139 views

How make LaTeX interpret each line as a new line within an environment?

I have list of file names in a multicol environment. I can use sort commands on them when needed e.g. (sort -u). I would like to temporarily make LaTeX recognize a single-newline (\n) as a new line. ...
2
votes
1answer
20 views

How to left align sub-equations in which some sub-equations are split across multiple lines (with their own alignment)

I have a set of four sub-equations, which I each want numbered and left-aligned. The second and third of these sub-equations are too long for one line so I am using the split environment to manually ...
2
votes
0answers
43 views

R-code linebreaks AND themes in knitr

hpesoj626 provides two great minimal working examples for how to get R-code linebreaks AND code highlighting in knitr. I was wondering if it was possible to use Yihui's knitr themes within either of ...
0
votes
1answer
47 views

Wrong wrap URL in bibitem - LATEX [duplicate]

I need fix wrong wrapped url. I tried a lot of examples but not helped me. Thanks. \documentclass [ing,male,java,dept460]{diploma} \usepackage [czech]{babel} \begin{document} ...
3
votes
1answer
32 views

How do you make a tight box using \begin{framed} and how do you skiplines in it?

I cant fit a tight box using this code: \begin{framed} \begin{flushleft} \# Description of the data \\ summary(training) \end{flushleft} \end{framed} and I dont manage to skip lines. Can anyone ...
3
votes
1answer
95 views

Long word wont go to next line

I'm using polyglossia package in my document and have some parts where I don't want to have hyphynation so I'm using \disablehyphenation command as documented. Now when I'm having very long words in a ...
2
votes
1answer
29 views

How can I effect a line break in a listing's caption defined with \lstname?

I'm using the package listings and defined the caption as \lstname, so it shows the relative path and the filename when I use the input command of the listings package. However, sometimes, the ...
2
votes
1answer
27 views

Column overflow with \category in ACM proceedings template

I'm stuck using the acm_proc_article-sp class. The \category section is significantly overrunning the column width and infringing on the right column. I have been able to fix this by adding a \sloppy, ...
4
votes
1answer
40 views

How to auto linebreak before/after parenthesis in inline math

I read this answer "Allowing line break at ',' in inline math mode" breaks citations I want to change ('s catcode automatically to avoid breaking some packages. ...
3
votes
1answer
50 views

Algorithm return statement does not begin on new line

I have the following code for displaying an algorithm: \begin{algorithm} \caption{Compute index of nearest grid point given particle position (1D)} \label{nearestGridPoint} ...
0
votes
1answer
16 views

Problem about the sizes of the brackets after linebreaks

I have a problem in the brackets of the following code: \begin{align} S = \int d^Dx \left\{ \mathscr{L}_{m=0} - \frac{1}{2}m^2(h_{\mu \nu}h^{\mu \nu} - h^2) - \frac{1}{2}m^2F_{\mu \nu}F^{\mu ...
2
votes
1answer
37 views

Splitting up an expression (that has braces)

I am trying to split up the longest set (the super long expression) here into multiple lines, I've looked at some other similar questions on this forum and tried a few different things but nothing ...
1
vote
1answer
30 views

Underline long url and linebreak

I have a long url which I want to appear blue and underlined. Furthermore it must linebreak if the url is to long for a single line. \documentclass[a4paper,10pt]{article} ...
3
votes
1answer
95 views

New line size. What can I do?

I'm writing my Ph.D. thesis and I'm using a format that a colleague of mine gave me. I noticed a strange situation: there are all around blocks of text that I separate with \\ only. Anyway, on pdf ...
2
votes
1answer
41 views

Automatic wrapping of displayed long formula (e.g., with the same algorithm used for inlined formulae)

Typographers warn against automatic wrapping of long formulae; however, there are cases in which this makes sense. Here is one: \documentclass[twocolumn]{article} ...
3
votes
0answers
41 views

BreakURL package using DVIPS only works on URL and not DOI

I've prepared my bibliography using biblatex, and my DOI addresses are not breaking their lines properly. I know that using pdflatex will solve this issue, I have to compile my document using latex -> ...
5
votes
2answers
54 views

Breaking inline math within longtable or tabular

So, I've got the following code: \documentclass{memoir} \usepackage{longtable} \begin{document} \begin{longtable}{p{0.4in}cp{2.75in}p{1.8in}} Symbol & Unit & Describes & Equivalent ...
2
votes
1answer
42 views

Make added hspace disappear if at a line break

Consider the following example \documentclass[a4paper]{memoir} \pagestyle{showlocs} \usepackage{amsmath,amssymb} \begin{document} \hspace*{8cm} text text text $\{ x\in X \, \vert \, \allowbreak x ...
3
votes
2answers
97 views

Redefining line break (double backslash) for align environment

I am trying to figure out if it is possible to (locally) redefine \\ (double backslash) within amsmath's align environment. On the one hand, I'd like to be able to dynamically insert extra columns, on ...
3
votes
1answer
49 views

Last word of paragraph appears on new page after figure

I use a figure environment without placement specifiers, and it ends up being put on top of a page, with the very last word of the preceding paragraph put just below it. This means that the page with ...
1
vote
0answers
38 views

Insert a line-break in online equation editor [closed]

How do you do a carriage return (line-break) when using the Online LaTeX Equation Editor](http://www.codecogs.com/latex/eqneditor.php)? I have written: \documentclass{article} {a_n^m} \Return ...
2
votes
1answer
22 views

Cannot get line break in section heading in jss article. The section headings are centered

I am unable to get line breaks in my section headings - have tried all of the suggestions above. I am compiling in pdflatex and using the jss format. The section headings are centered for jss ...
1
vote
1answer
59 views

Manual line break in tabular (tabu) breaks the layout of other columns if not using X column parameter

I know this problem has been discussed many times, and the proposed solutions were to use yet nested parboxes inside table cells, but I would like to avoid that. Up to now, I was using my table with ...
7
votes
1answer
147 views

How to prevent a stranded comma on the next line?

In this document, where I am replicating my original document in order to get the issue I am highlighting here, a comma is stranded on the next line: \documentclass[a4paper, 14pt]{extarticle} ...
2
votes
1answer
29 views

Maintaining indentation in a long Ensure-block with algorithmicx-package

I have a long "Ensure-block" in my algorithm. How can I force the second line to be exactly under the first "Text"? \documentclass{article} \usepackage{algorithm} \usepackage[noend]{algpseudocode} ...
7
votes
0answers
52 views

lineno package has different output in pdflatex and lualatex [closed]

Using line label references from the lineno package prevents lines from being broken at explicit hyphens in words adjacent to the label. Consider the following MWE: \documentclass{article} ...
3
votes
1answer
57 views

Line-breaking unformatted URLs that contain no hyphens

Minimal example: \documentclass{article} \begin{document} https://path.to.really.long/url/that/contains/no/dashes/but/instead/a/whole/lot/of/forward/slashes/which/makes/it/exceed/the/page/width ...
5
votes
2answers
70 views

Add optional text that may be invoked by tex to avoid bad boxes

I'm currently writing a very long document and whenever I switch styles (I know, I shouldn't do this as often) I get tons of bad boxes, mainly due to long, unbreakable pieces of math inside a ...
5
votes
2answers
130 views

Include a line break in algorithm-caption while maintaining indentation

I've a question about the alignment of the caption in an algorithm-environment. For instance, the following code-example \documentclass{article} \usepackage{algorithm} ...
3
votes
1answer
58 views

Add line break after every line

When I enter this C = B log(1+SNR) 270.88 = 200 log(1+SNR) The two lines are printed on the same line. I can force a line break by using \\ but this is very annoying. Is there a way to ...
4
votes
1answer
41 views

How can i make (force) a paragraph to be justified and have a specified number of lines

How can i make (force) a paragraph to be justified and have a specified number of lines? Intra-line spacing is not important, but the paragraph should be completely rectangular. Below is a minimal ...
4
votes
1answer
155 views

Equally distribute text among a given amount of lines; automatically adjusting the width

Given some text, I want to centrally align this text on a given amount of lines. For example, \documentclass{article} \begin{document} Nam dui ligula, fringilla a, euismod sodales, sollicitudin vel, ...