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

learn more… | top users | synonyms (1)

0
votes
0answers
25 views

Listings package does not break with my own class

I have created a class based on the article class so: \NeedsTeXFormat{LaTeX2e} \LoadClass{article} \RequirePackage{../../mypackage.sty} According to that, I have done following example document: ...
2
votes
1answer
32 views

unexpected linebreak when using `\nameref` in marginpar

I have an unexpected linebreak in my \marginpar and don't know where it comes from. It appears right in the middle of the \nameref... Does anyone see the mistake? ...
2
votes
1answer
34 views

Disallow long words from flowing into margin by breaking early

I sometimes have long words that are unbreakable and end up sticking out into the right margin. I realize that there's nothing magical to be done about this and the only real solution is to break them ...
1
vote
1answer
39 views

Nice line-break in inline math within theorem environment

This is my first question here, I hope it's not bad (please bear with me if it is). I have quite a specific problem concerning inline math and theorem environment. In general, I want to obtain the ...
2
votes
1answer
58 views

linebreak in long URL? Breakurl won't break it

There are several questions on this site (for example here and here) where people are struggling with overfill hboxes when making clickable URLs. I have read and tried the answers there and none of ...
0
votes
0answers
42 views

Avoiding pagebreak after newline in theorem

This might be of relevance: Theorem environment - line break after label pagebreak and amsmath theorem environment issue Avoid page break in theorem Situation I used the information provided ...
1
vote
2answers
39 views

Some lines are formatted differently (overflowing) for a reason I can't tell

In my first attempt to use LaTeX a bit seriously, I formatted my CV using the template in ShareLaTeX. Some parts were confusing and I got some great help from here and finally produced a CV that ...
0
votes
2answers
31 views

How to avoid underfull boxes in itemize?

I am using an itemize as shown in this example: \begin{itemize} \item \textbf{The First}\\ Some text here over fifty lines.... bla blah \item \textbf{The Second}\\ Other text here ...
2
votes
1answer
43 views

How to check if a macro can be followed by a newline

I'm trying to create a class that allows you to define a name using \name{Whatever} This is defined as \newcommand{\name}[1]{\def\gsy@name{#1}} Whatever is passed to this is used in the header, ...
0
votes
0answers
20 views

Prevent line breaks after specific words in general

I am sorry if this is duplicate but I couldn't find it... or, more specifically, I've found something even more general, but I didn't understand a word from it :D Prevent line-breaking after short ...
3
votes
1answer
24 views

Semantic Package: Multiple Lines in Conclusion

I am using the semantic Package and I would like to place line breaks in the conclusion part of an inference rule. For example, I would like to write something like: \inference{A}{B \\ C \\ D} ...
1
vote
2answers
60 views

Long glossary description and line-break for the short form of the acronym

I've been struggling with some long glossary word descriptions that are not breaking correctly. I found a link to a question about hyphens, but it only solves part of a part of my problem. For the ...
0
votes
0answers
25 views

Avoid the insertion of spaces when using newlines in latex source code

I have a problem with some Latex code that I need to write. In this code, I am putting elements into a table using a macro. This Macro also does some magic with the content it is inserting into the ...
1
vote
1answer
40 views

Theorem header and *all* content on separate pages

I have in my paper a theorem-like environment which consists only of an enumerated list. It looks bad if I just type it in vanilla, so I add a $\,$ before the enumerate (see also enter link ...
0
votes
1answer
45 views

How to adding vertical spacing in \raggedright or \RaggedRight

I usually use \\, \par, \newline, etc. to add whitespace to LaTeX. However, when I use raggedRight, the pdflatex spits out a ton of messages saying "There's no line here to end." Ultimately, all ...
2
votes
0answers
52 views

LuaLaTeX vs XeLaTeX hyphenation and line layout [closed]

I am typesetting my journal just for the fun of it. I am using KOMA-script's scrartcl with two columns. I am testing with both LuaLaTeX and XeLaTeX. I haven noticed page count is different between the ...
1
vote
1answer
44 views

Repeating certain signs after linebreak in inline math expressions

I use LaTeX to type my University Maths notes. In that, I often find myself faced with linebreaks in inline math expressions. In such a situation, I usually want to double the sign just before the ...
0
votes
1answer
40 views

Ideal file path line breaking within a cell longtable tabu

I am creating a table which has file name, source and destination file paths, and a short description of each file. The description and flag fields have spaces so the line break can be automatic. ...
3
votes
2answers
43 views

How do I completely suppress paragraph indentation in quoting environment without \noindent?

\documentclass[oneside,12pt]{article} \usepackage{geometry} \usepackage{microtype} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{lmodern} \usepackage{enumitem} ...
1
vote
1answer
24 views

theorem header still not breaking line

The question has been asked before at How can I get a line break in a theorem headline?, but the answers seem not to work for me: \documentclass[a4paper, twoside]{book}%[a4paper,oneside] ...
0
votes
1answer
27 views

wrapfig not breaking lines properly in beamer

I have a very simple situation where wrapfig is not correctly choosing line break positions correctly. Here is the MWE: \documentclass{beamer} \usepackage{wrapfig} \begin{document} \begin{frame} ...
0
votes
0answers
67 views

inline listings line wrapping issues

I am having issues with inline listings line wrapping. As you can see in the linked image, the period ending the sentence is on the next line due to wrapping of the cite-website text. The listings ...
1
vote
1answer
110 views

Linebreak does not work in section headings modified with tikz

I have a problem with long sub/section headings: \\ is not wirking. As I'm new to Latex, I adopted this beautiful template http://www.fluortools.com/misc/LaTeXtemplate and modified it for my needs. ...
1
vote
1answer
36 views

Force equation numbering to the same line of case equation

It seems that the column is so narrow that it can not bear the whole equation: \begin{equation} R(p_i|G) = \begin{cases} ep_{p_i} + (1- UA(p_i|G))\cdot ({r_G - ep_{p_i}}) ...
14
votes
5answers
884 views

Creating a multi-line colored box in LaTeX

I am trying to create a colored box in LaTeX that has two lines. I would like the text to be centered. Ideally, I want to be able to change the text font and the size of the colored box. So, an ...
1
vote
0answers
32 views

colorbox highlighting: overfull hbox

For a current LaTeX-Document, I've done some highlighting using colorboxes around specific words or formulas. This works quite well, although, of course, the colorbox doesn't do line breaks when it is ...
0
votes
1answer
31 views

Automatic line breaks in path{} command?

i use the \path{} command to print out a path to a directory in my *.tex File. I searched a lot around the internet to solve the problem to automatically linebreak the path-url. I found some hints ...
4
votes
2answers
83 views

Problem with too large table

I'm trying to make a large table with latex, but I have a problem with text inside it, it depasses, the page. here the code : \begin{table*} \centering ...
1
vote
0answers
181 views

GitHub-hosted Jupyter notebook auto line breaks / wrapping [closed]

I would like to put a document containing a fair amount of inline math onto GitHub as an IPython Notebook. Because I don't like the typical Markdown sans-serif font, which wouldn't match the Latex ...
4
votes
2answers
52 views

Change color line in hline

Recently I asked a question about how to draw a line under titles but this line should be flexible is a picture is included or not. I am trying to change the color of this line but nothing works? ...
0
votes
2answers
28 views

Linebreak in a longtable

I use the longtable package to create a table that covers multiple pages, but the problem is that the linebreake does not function correctly.This is my code: \documentclass[12pt]{article} ...
1
vote
0answers
28 views

Automatic linebreaks for equations in tabular environment?

I have so far tested the breqn's dmath environment example here but it does not work with tabular in rotating's sidewaystable, resulting into \cr errors in wrong place. So How can you automatically ...
1
vote
1answer
108 views

How to prevent words from running into the right margin?

I'm revising one of the final drafts of my thesis and on several pages there are words running into the right margin. My question is whether rewording the paragraph is the only way to get rid of this ...
0
votes
1answer
36 views

how to let the long web-link automatically break line?

I use the \tt in the latex, however, it can not break line automatically. Then, I add \\ in the link, e.g. \tt{http://tex.stackexchange.com/ \\\\ questions/ask}. Then, in the generated pdf file, it ...
5
votes
1answer
96 views

How to break lines in tables without vertical spacing?

I'm building a table and I need to have line breaks in each cell of one column. I have found the following example: How to add a forced line break inside a table cell Here is the code: ...
1
vote
1answer
62 views

How to add a linebreak in a tikz UML Sequence Diagram instance/thread

I'm writing a UML sequence diagram with tikz package pgf-umlsd. Currently the code looks as follows: \begin{sequencediagram} \newthread{controller}{Special Task Controller} ...
0
votes
1answer
36 views

How can I prevent non-math overflowing into margin when using textsubscript?

I am using \textsubscript for subscripting a non-math data . but it is long enough to cause overflow into the margin. What are the possible solutions?(may be like writing subscript in 2 lines)
0
votes
1answer
40 views

Breaking Typewriter-styled Detokenized Text

The goal is to have snake_cased elements typewriter-styled breaking properly. I am using \detokenize rather than simply \_ because otherwise the snake_casing looks wrong, namely like this: rather ...
0
votes
1answer
31 views

Disallow line break in \cite

How can I disallow line break in \cite? Two bibtex entries are @book{is, author = "Mörður Árnason", title = "Íslensk orðabók", publisher = "Edda", address = ...
0
votes
1answer
16 views

Function throws error only on first call in a section

I'm setting up a template for my homework for this semester in LaTeX, and I'm getting an error that the first time I call a function it fails but every later time in the document it works. Here's the ...
1
vote
0answers
32 views

Reference a picture [duplicate]

I am writing a PhD thesis. Sometimes when I reference to a figure the following problem occurs. In PDF the word Fig.[number of figure] are written in two lines (Fig. and [] are separated). How to ...
4
votes
1answer
34 views

Justified text with predefined line breaks

I want to set a text following the line breaks in a certain edition, and I want it to be justified. I suppose I should use \obeylines, but don't know how to get the lines justified.
1
vote
2answers
75 views

Lines with texttt reach into the page border, how to prevent?

MWE: \documentclass{scrartcl} \RequirePackage[utf8]{inputenc} \RequirePackage[T1]{fontenc} ...
4
votes
0answers
80 views

Dealing with slightly overfull \hbox's

Generally, how do you deal with lines that are slightly overhung, when microtypography is already enabled, and there's no way of hyphenating the hanging word and no desire to put it on the next line, ...
1
vote
1answer
132 views

How to prevent a linebreak before align/equation environment in itemize? [duplicate]

The following code \documentclass{article} \usepackage{amsmath} \begin{document} \begin{itemize} \item \begin{align} a&=b\\ &=d \end{align} \item \begin{equation} a=b\\ =d \end{equation} ...
2
votes
2answers
163 views

Auto-linebreaking in underset

I often find myself writing explanations to passages in (in)equality chains directly under the (in)equality signs, by putting an underset which puts a vertical line starting from the sign and going ...
0
votes
0answers
31 views

Is it possible to revert a line break after an environment?

Most environments seem to automatically break a line after them. This of course makes sense but I am having a case where I would like start writing in the same line where the environment (minted) ...
2
votes
1answer
50 views

Methods to resolve long line overflowing into margin

My document sometimes has lines which slightly overflow into the margin, such as in the below example. I was wondering what different methods could resolve this issue, such as changing spacing between ...
5
votes
1answer
76 views

Clickable URLs: no click possible after the line break

I use \url to make an URL clickable. When the line breaks, the part of the URL after the line break is not clickable. Why, and how to fix it? Demo: \documentclass[11pt,letterpaper]{article} ...
1
vote
2answers
33 views

hyperref : break long lines in pdftitle and other fields

I have a problem with hyperref: how to break long lines in pdf fields : the pdftitle is very long and I want hyperref to begin a new line, just like it does for key-words. I compile with pdflatex, ...