i want 2 lines to stay together... How do i do it?
This apparently doesn't work.
\mbox{ First Line \\
Second Line}
cat test.tex\documentclass[11pt,twoside,a4paper]{article}%
latex test.texThis is pdfTeX, Version 3.141592653-2.6-1.40.26 (TeX Live 2024) (preloaded format=latex)
xdvi test.dvi
i want 2 lines to stay together... How do i do it?
This apparently doesn't work.
\mbox{ First Line \\
Second Line}
___________________________
in Comp.Text.Tex ... i only see CTAN (update) announcements
can i ask LaTeX questions?
i want 2 lines to stay together... How do i do it?
This apparently doesn't work.
-a-a-a-a-a-a-a-a-a-a-a \mbox{ First Line \\
-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a Second Line}
___________________________
in Comp.Text.Tex-a-a ...-a i only see CTAN (update) announcements
-a-a-a-a-a-a-a-a-a-a-a can i ask-a-a LaTeX-a questions?
Look up the environment minipage.Or in this case perhaps parbox
Jeff Barnett wrote:
Look up the environment minipage.
Or in this case perhaps parbox
i want 2 lines to stay together... How do i do it?
This apparently doesn't work.
-a-a-a-a-a-a-a-a-a-a-a \mbox{ First Line \\
-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a Second Line}
On 19/07/2024 06:31, HenHanna wrote:
i want 2 lines to stay together... How do i do it?
This apparently doesn't work.
-a-a-a-a-a-a-a-a-a-a-a \mbox{ First Line \\
-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a-a Second Line}
That's because \\ is for prematurely ending a line, not for combining them.
It's also used (differently) in tabular setting to signal the end of a row.
Can you explain what you want to do, with a worked example?
"want 2 lines to stay together" doesn't give enough information.
i want 2 lines to stay together... How do i do it?
I don't think crossposting to 5 groups two of which not in English will
help.
el
On 19/07/2024 07:31, HenHanna wrote:
i want 2 lines to stay together... How do i do it?
[...]
On 7/25/2024 8:37 AM, Eberhard W Lisse wrote:
I don't think crossposting to 5 groups two of which not in English will
help.
el
On 19/07/2024 07:31, HenHanna wrote:
i want 2 lines to stay together... How do i do it?
[...]
if i want 2 words to stay together... First~Second
(and/or \mbox{...} )
Shouldn't there be an easy way to do that for 2 lines?
On tor, 2024/07/18 at 22:31:29 -0700, HenHanna wrote:
i want 2 lines to stay together... How do i do it?
This apparently doesn't work.
\mbox{ First Line \\
Second Line}
WFM.
cat test.tex\documentclass[11pt,twoside,a4paper]{article}%
\begin{document}
\mbox{ Line1 \\
Line2 }
\end{document}
latex test.texThis is pdfTeX, Version 3.141592653-2.6-1.40.26 (TeX Live 2024) (preloaded format=latex)
restricted \write18 enabled.
entering extended mode
(./test.tex
LaTeX2e <2024-06-01> patch level 2
L3 programming layer <2024-05-27> (/usr/local/texlive/2024/texmf-dist/tex/latex/base/article.cls
Document Class: article 2024/02/08 v1.4n Standard LaTeX document class (/usr/local/texlive/2024/texmf-dist/tex/latex/base/size11.clo)) (/usr/local/texlive/2024/texmf-dist/tex/latex/l3backend/l3backend-dvips.def) (./test.aux)
[1] (./test.aux) )
Output written on test.dvi (1 page, 256 bytes).
Transcript written on test.log.
xdvi test.dvi
Shows "Line1 Line2" on the page.
https://tex.stackexchange.com/questions/146909/what-does-mbox-do
| Sysop: | Amessyroom |
|---|---|
| Location: | Fayetteville, NC |
| Users: | 65 |
| Nodes: | 6 (0 / 6) |
| Uptime: | 00:46:53 |
| Calls: | 862 |
| Files: | 1,311 |
| D/L today: |
10 files (20,373K bytes) |
| Messages: | 264,186 |