各种乳胶问题
我必须赶紧学习 Latex,现在正在尝试修复一份报告。 大多数事情都很好,但我有一些问题。
- 摘要有很多填充。 这使得摘要中断并最终变成两页。 如何通过删除填充而不使文本变小来使其适合一页?
- 我有一张长桌子,我用的是longtable。 但表格很宽,所以我使用 p{Xmm} 使其适合页面。 效果很好。 但是列中的所有文本都将使用整个列宽度,这是我不想要的。
- 我使用 \setlength{\parskip}{Xmm} 来获得段落之间的一些间距。 效果很好。 但随后这些部分将会有很大的间距。 有没有办法只设置底部间距?
然后我还有一个关于 Latex 的问题。 为什么标准如此可怕? 我是说。 您是否希望表格在内容太宽时不会自动中断? 您是否希望段落之间的间距为 0? 我不明白...
谢谢!
I had to learn Latex in a hurry and am now trying to fix a report. Most of the things works fine, but I have some problems.
- The abstract has very much padding. This makes the abstract break and end up in two pages. How do I make it fit on one page, by removing padding, not making the text smaller?
- I have a long table, which I use longtable for. But the table is wide so I use p{Xmm} to make it fit the page. That works fine. But then all text in the columns will use the whole column width, which I don't want.
- I use \setlength{\parskip}{Xmm} to get some spacing between paragraphs. That works fine. But then the sections will get lots of spacing. Is there any way to only set the bottom spacing?
Then I have another question about Latex. Why are the standards so terrible? I mean. Do you ever want a table not to break automatically if the contents it too wide? And do you ever want there to be 0 spacing between paragraphs? I don't get it...
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
LaTeX 的默认设置一点也不糟糕。 您需要接受 LaTeX 是一个排版系统——而不是文字处理器。 从排版的角度来看,表格根本是不可破坏的。 就算破了,又该如何破呢? 排版系统将要求您(并且它应该这样做!)告诉自己它应该如何表现。 此外,如果段落之间没有间距(您正在编写段落,而不是插入换行符,是吗?),您使用的文档类不会这样做:这是一种完全可以接受的格式化段落以使用缩进的方式第一段行,段落之间没有额外的空间。 我随机挑选了两本散文书,都是这样的格式。 说真的,LaTeX 使用的标准(尤其是使用 KOMAScript 时)比我所见过的使用 Word 或类似工具创建的任何标准都更加更加清晰,并且更加美观。 如果你习惯了 LaTeX 输出,Word 看起来就像垃圾。 它根本不能正确处理间距。
另外,学习 LaTeX 并不是一蹴而就的事情。 如果您赶时间,我建议您使用文字处理器。 或者,获得所需的时间。
至于你的问题:
\enlargethispage
。tabular
您可能希望将p
列设置为\raggedright
\parskip
,则会修改段落后添加的空间量。The defaults of LaTeX aren't terrible at all. You need to accept that LaTeX is a typesetting system -- not a word processor. From a typesetting view a table isn't breakable at all. Even if it breaks, how should it break? A typesetting system will require you (and it should do so!) to tell yourself how it should behave. Furthermore, if there is no spacing between paragraphs (you are writing paragraphs, not inserting line breaks, are you?) you are using a document class that doesn't do that: it's a perfectly acceptable way of formatting paragraphs to use indents of the first paragraph line without additional space between the paragraphs. I just picked two random prose books and both format this way. Seriously, the standards LaTeX uses (especially when using KOMAScript) are much saner and way better looking than anything I've seen created with Word or similar. If you're used to LaTeX output Word looks like crap. It doesn't deal properly with spacing at all.
Also, learning LaTeX is nothing to be done in a hurry. If you are in a hurry I suggest using a word processor instead. Alternatively, get the required time.
As for your questions:
\enlargethispage
.tabular
you might want to make thep
column\raggedright
\parskip
you modify the amount of space that is added after a paragraph.选择标准 LaTeX 类中的默认值是为了利用当时可用的最佳阅读人体工程学数据。 (例如,单列文档中的页边距令人惊讶的宽的原因是,好的读者可以在不扫眼睛的情况下阅读大约 60--65 个字符。)
通常,如果没有充分的理由,您应该不愿意覆盖默认值。 当然,如果规则来自高层,你就无能为力。
顺便说一句——许多“我如何控制 X?”的答案 类型问题是“使用可以从 CTAN 下载的 Xcontrol 包”。
The defaults in the standard LaTeX classes were chosen to take advantage of the best reading-ergonomic data that was available at the time. (The reason for the surprisingly wide margins in single column documents is that good readers can take in about 60--65 characters without having to scan their eyes, for instance.)
Generally you should be reluctant to override the defaults without a good reason. 'Course, if the rules come from on high, you can't do anything about that.
BTW-- The answer to a lot of "How do I control X?" type questions is "Use package Xcontrol which you can download from CTAN".
当您插入
\raggedright
时,它会重新定义\\
表示“文本行结束”而不是“表格行结束”。 您可以使用\tabularnewline
代替。When you insert
\raggedright
, it redefines\\
to mean "text line end" rather than "tabular row end". You can use\tabularnewline
instead.抱歉,如果我不清楚。 这就是我的报告的结构。 我使用 Article 是因为我不希望这些部分从 0 开始。
关于第二个问题。 这是我的意思的屏幕截图。 正如您所看到的,文本使用了 100% 的宽度。 所以有些单词之间有一些空格。
如果我还有其他不清楚的地方。 请问。
sorry if I was unclear. This is the structure of my report. I use article because I didn't want the sections to start at 0.
About question number two. Here's a screenshot of what I mean. As you can see the text uses 100% of the width. So there's some spacing between some words.
If I was unclear about something else. Please ask.
我所说的“大量填充”是指即使文本上方和下方有足够的空间,它也会将其包裹起来,使其成为两页。 我自己没有添加任何填充。 摘要页面比其他页面有更多的填充。
{\raggedright}p{3cm} 几乎可以工作...我可以在除最后一列之外的所有列上设置 raggedright。 将其设置在最后一个会产生编译错误。
“您修改段落后添加的空间量”:我愿意吗? {sub}部分是否被视为段落? 因为我在这些下面也有额外的间距。
Latex 是本报告的一项要求。 经过一番尝试后,我明白你真的应该背诵它。 我会的!
正如你所说。 乳胶真的很好看。 为最佳阅读人体工程学指定一个标准是很有意义的。
By "much padding" I mean that even though there's plenty of space above and below the text, it wraps it so it become two pages. I didn't add any padding myself. The abstract pages has more padding than the other pages.
{\raggedright}p{3cm} works, almost... I can set raggedright on all columns but the last. Setting it on the last will give a compile error.
"you modify the amount of space that is added after a paragraph": I do? Is a {sub}section considered as a paragraph? Because I get extra spacing below these too.
Latex was a requirement for this report. I understand after playing around a bit with it that you really should learn it by heart. And I will!
As you say. Latex is really good looking. And to specify a standard to the best reading-ergonomic makes lots of sense.