In typesetting math in LaTeX, there is inline mode (math inside text) and display mode (separate equations outside text). This tag is used for inline mode. It should also be used for other structures that provide a similar distinction between its usage, like the {listings} package's environment and ...

learn more… | top users | synonyms

3
votes
2answers
263 views

Force paragraph to stay with previous

I am using knitr to create inline sparkline-esque graphics. However, when knitr inserts images that it generates with R, it add a blank line, which forces LaTeX to make a new paragraph. That is, if I ...
1
vote
1answer
175 views

\lstinline break at punctuation

I need listing package (\usepackage{listing}) to break at punctuation namespace::subnamespace::class ^ ^ at either these two locations
2
votes
2answers
1k views

Line spacing with inline formula including fraction

I have a fraction in an inline formula as can be seen in the picture. \dfrac from the amsmath package was used. (This is article class with 14pts and linespread 0.9.) Though the space between the ...
0
votes
1answer
315 views

inlineMath \$…\$ not working but default \(…\) does [closed]

I am having issues getting a custom inlineMath format to work. I have included the MathJax CDN and then using the in-line configuration options. I can get all of the default formats to work $$...$$, ...
4
votes
1answer
131 views

Can LuaTeX do something to alter linebreaks inside math inline automatically?

This is kind of a follow up to this question. Consider the sample code: \documentclass{minimal} \begin{document} A text with an inline equation which is broken in to two parts but is not wanted right ...
13
votes
1answer
1k views

Why do I have overfull \hbox when I use inline math without line breaks

To prevent line break within equation I use following LaTeX command: ${r^2 = x^2 + y^2}$. Unfortunately it gives me Overfull \hbox (12.4459pt too wide) warning. Why LaTeX doesn't move whole ...
17
votes
1answer
13k views

How to rotate text inline?

I used the rotating package to rotate the symbol 90 positive degrees and that worked well. But I also want to rotate it 270 positive degrees and then it ends up hanging down on the line below. How can ...
23
votes
3answers
1k views

maths nested superscripts and subscripts displayed incorrectly inline

I am having a strange bug when using nested superscripts and subscripts in inline math (displaystyle works fine). This behaviour is the same independently of the font used or the compiler (orginally ...
3
votes
1answer
124 views

Aligning a listing environment within a paragraph

I have the following code that displays a listing in a paragraph. However, because there are not so many line of code, I would like to move it to the right and the paragraph be on the left hand side. ...
2
votes
2answers
317 views

inlinelisting adds a space after keywords

I am having problem with lstinline macro. It keeps adding a space after the keyword "Module" - see MWE. How could I convince Latex not to do so? I already tried with including the "." inside the ...
6
votes
1answer
254 views

Include BibTeX contents in a listings block

I am trying to include the literal contents of a BibTeX file in my LaTeX document using the listings package but am running into an issue. As BibTeX does not appear to be natively supported (though ...
1
vote
1answer
585 views

Include a lstlistings keyword in lstlistings caption

I'm writing a small summary for my fellow students about VB in LaTeX. I have to cover the basic loops and found the \lstlistnigs package to be the best for writing colored code. I have already added ...
1
vote
1answer
158 views

How to modfiy spacing for inline math?

I want to reduce spacing between operators in inline math. If I add the follwing lines to the peamble it affects both inline and display math modes. \thinmuskip=0mu \medmuskip=0mu \thickmuskip=0mu ...
4
votes
2answers
474 views

inline equation outside margin

My inline equation falls outside the margin. I was wondering if there is any solution for that? Here is the MWE: \documentclass[12pt,letterpaper]{article} \usepackage[utf8]{inputenc} ...
3
votes
1answer
3k views

How to add vertical space between two lines of tables

\documentclass[11pt]{article} \usepackage{tabu} \usepackage[inline]{enumitem} \begin{document} \section{abc} \begin{enumerate} \item \begin{enumerate*} \item ...
2
votes
1answer
165 views

Insert a photo inline with some text and math environment (align)

I'm trying to get sth like: I've been having problem with the picture-inline-with-text part. A little help please. The wrapfigure package (which is known to be better) doesn't work. Nothing is ...
4
votes
1answer
98 views

Global inline formula breaks configuration

How I can configure inline formula breaks globally without changing original formulas? What package can help me? I saw this post, but the trick with comma does not work. UPDATE The formulas look ...
8
votes
2answers
324 views

How to create an inline list via a macro

I want to create a macro that yields an inline lists. I can easily do this using enumerate* form the the enumitem package, but when I attempt to wrap this in a macro, I get: Extra }, or forgotten ...
10
votes
2answers
848 views

Labelled in-line equation

I searched the internet but I cant find a solution for my problem. I want a numbered and labelled equation inside the text.Something like: The equation a+1=b (2.1) does ... The equation a+1=b ...
8
votes
2answers
2k views

Line-break inside a `\verb'

I have set my text editor to wrap text at 76 columns. When including verbatim text in-line, my text editor did an auto-word-wrap and I ended up with something that looked like: \item Just another ...
6
votes
1answer
130 views

Autofit for inline equations

I am trying to use an inline equation to list bunch o tuples. However, I it does not automatically go to next line. I am doing it manually, but this time it looks ugly. By the way I am writing in a ...
5
votes
2answers
106 views

Tie an inline math environment to be in the same line

How should I put command so that my inline math environment could be together. For example 0<x<1 is break up into two parts, 0< and x<1 in the next line.
7
votes
1answer
237 views

Allow line breaks but not page breaks in inline formulas

It often happens that LaTeX breaks up an inline formula over two lines. However, I find it quite distracting when it breaks an inline formula over multiple pages. For example: ...
9
votes
2answers
461 views

How do I typeset continued fractions in Pringsheim's concise notation?

I would like to obtain the following formatting so as to write continued fractions in my equations without wasting vertical space. What I need is one command named \cFrac which writes one fraction ...
7
votes
1answer
1k views

Avoid line breaks after \lstinline

I'm writing a computer science paper with LaTeX and have a lot of inline code. Now, when this code is followed by a comma and is at the end of line, the line break is inserted before the comma, which ...
2
votes
1answer
2k views

Numbering equations in tabular environment

I wish to number equations in a table, like numbering them in \begin{equation}. ... \end{equation} Since all the equations are written as "inline" equations (for example, $a = b+c$) in ...
0
votes
2answers
299 views

Using hfill to prevent expansion of text in table environment

I am using inline lists (from the enumitem package) within a table (see Comma-separated list environment) Originally, I had an issue where the inline list would expand horizontally to the width of the ...
16
votes
1answer
3k views

Inline TikZ - vertical centering

If I inline a bounded line segment like this: the distance \tikz{ \draw [|-|] (0,0) -- (5ex,0); } overarching the activities how can I make the line appear vertically centered on the line ...
2
votes
2answers
5k views

How to place inline figure

I am trying to create a resume with a picture. So i want the picture to be on the right hand side while the text is written on the left. With a bit of googling, I found wrapfigure package to insert ...
5
votes
1answer
741 views

avoid linebreak in \lstinline if possible

By using \lstinline{mysourcecode} I put some code within my document. I would like to avoid that this code is broken to a new line, if possible. so, if the codeline itself is less long than a full ...
6
votes
1answer
4k views

Embedding sound files into beamer presentation with media9

I'm trying to embed a sound file inline into a beamer so i don't need to carry the sound file around with the pdf. Currently I place sound files into my beamer with the multimedia package and this ...
8
votes
2answers
6k views

How do I keep a string of text together without it doing a line break?

I'm writing up a long paper, in which in prose I have various equations. However, I do not want a line break to occur within the equation - I want the equation to stick together. I want to do this ...
8
votes
2answers
3k views

\lstinline!Foo! vs \lstinline{Foo}

I wonder what is the difference or correct usage of \lstinline!...! and \lstinline{...}? I like better {} because I feel there it's more consistent with other commands but for example in below ...
8
votes
2answers
303 views

Writing specific versions of an operator for display and inline modes

I'm busy answering a question by constructing a new math operator that uses the sum symbol and some TikZ placed on top. My answer as it stands can be found here. It looks (I think) pretty good in ...
10
votes
2answers
187 views

Different symbols in $…$ and align environments

Is there a way to force LaTeX to produce different symbols either in $...$ or \begin{align}...\end{align} environments? For example $ \mymacro $ should lead to A while \begin{align} \mymacro ...
3
votes
3answers
3k views

Numbering side-by-side equations or inline equations

I am trying to produce a two-column table of math equations, where each cell contains its own left-justified, numbered equation. I tried using \begin{equation} \end{equation} inside the tabular ...
5
votes
2answers
473 views

Flexible/automatic alternative to multienum?

I'd like to typeset the items in an enumerate environment side-by-side. Preferably, each item would take up only as much space as necessary, perhaps plus some extra padding, and the next item would be ...
6
votes
1answer
962 views

How to redefine \lstinline to automatically highlight or draw frames around all inline code snippets?

How to redefine \lstinline to automatically highlight or draw frames around all inline code snippets? E.g. using \bh and \eh commands from Highlight text in code listing while also keeping syntax ...
4
votes
1answer
840 views

How to avoid background / frame break in code listings with math / mathescape?

I have lots of C++ sources with LaTeX formulas in the comments. Ideal for using the listings packages to pretty print the source. However, most of the formulas break either, the background or the ...
4
votes
2answers
376 views

Can I draw a small arrow from a word to a space-gap on the same line?

I want to illustrate that the const in the following line can also be moved one word to the right. Maybe I can underline the const and draw a slim arced arrow pointing to the next gap? const int * ...
9
votes
4answers
4k views

Micro-graphics inline in text

Can I insert a graphic in-line in a sentence? Use case: I'm writing a manual that involves navigating the Windows Start Menu. I would like to insert a little graphic of the start menu in-line in ...
5
votes
1answer
497 views

inline math with \ldots

what should be preferred: $x_1,\, x_2,\ldots,\, x_n$ or $x_1$, $x_2$, ..., $x_n$ I'm hesitating for the \ldots versus ...
2
votes
5answers
588 views

inline bracket, similar to a permutation and binomial, but aligned

I'm often experiencing instances, when I need to define a function on two sets in a domain. I'd like to create a command \newcommand{\func}[4]{...}, which makes an inline bracket, that shows how the ...
17
votes
1answer
5k views

Vertical alignment of inline images

Images appearing inline aren't always ideally placed relative to the baseline and risers of the text itself, so I frequently find myself doing manual adjustment, by eye, using \raisebox{}{} with a ...
3
votes
1answer
240 views

How to properly break text with lots of inline formulas?

I have the following document: \documentclass{article} \begin{document} \textbf{Theorem:} $\forall x_0\cdots\forall x_{n+2}( \forall x_{n+3}(x_{n+3}\in x_{n+1}\leftrightarrow ...
1
vote
1answer
144 views

Spacing of characters in a mathematical set, displayed inline in paragraph

I have a mathematical set notation that I want to display inline in a paragraph of text. However, when I write this, the output is not very beautiful: $\{ (w_j,\dots,w_{j+n-1}) | 0 \leq j \leq ...
3
votes
3answers
3k views

Aquamacs + AUCTeX inline preview

I tried to search for the solution, but I couldn't even find references to this problem. I'm trying to use Aquamacs+AUCTeX as my LaTeX editor. One of the major features available in this setting is ...
46
votes
6answers
16k views

Prevent LaTeX to break an inline math equation

I hope this question was not asked before. At least I haven't found it. I have an inline math equation and LaTeX is breaking it into two parts. In this case I'd prefer to have the whole and short ...
16
votes
3answers
3k views

Preferred method for inline code samples

I tend to use the minted package for including code samples within my documents, which produces very nice output. However, because Pygments always produces a verbatim environment there's no way to ...
2
votes
5answers
1k views

How to automatically inline \input commands and bibliography?

I have a document that uses some \input commands and creates the bibliography via an external .bib file and bibtex. Now I have to inline the \input commands (i.e. replace each \input command with ...