Tag Info

Hot answers tagged

8

Never use undocumented commands without knowing what they do. In particular, \vbox is a primitive command that misses several adjustments minipage or \parbox do in order to be as compatible as possible with the surrounding context. Also the reference point of \vbox is on the bottom line inside it. Here's a better solution. \documentclass{article} ...


7

This modifies multline to do (I think) as you ask. The result looks fairly unreadable to me, but perhaps I'm just not used to reading Russian articles. multline like all AMS alignments grabs the environment body and sets it twice to measure it, this just modifies it so that if it is too wide on that first pass, = is redefined and the measuring pass is ...


5

To have the chapter heading to appear on a page of its own, add a \clearpage in the last optional argument for \titleformat. To have the heading vertically centered, add \vfill before and after the title is typeset: \documentclass[11pt]{report} \usepackage[T1]{fontenc} \usepackage{titlesec} \usepackage{calc} \usepackage{lmodern} \usepackage{lipsum} ...


4

One way is to relax \clearpage, such that is doing nothing when called. Other possibilities (not in here): Redefine the commands \listoftables etc. and remove the \clearpage in there or use etoolbox package in order to patch them or the answer given in the link in LariFaRi's comment. Of course, the content lists will not fit on one page if there are a lot ...


3

Deleting \newcommand*\NewPage{\clearpage\thispagestyle{empty}\null} \NewPage Should have the desired effect (the definition leaving \null at the top of the following page seems to be incorrect in all cases, and certainly is not wanted before a chapter heading)


2

You can just enclose both the equation and the table in a figure environment, and use some labeling that is : \documentclass[a4paper]{article} \usepackage{amsmath} \begin{document} \section{Penman-Monteith} [...] The resulting standard equation for the ASCE-PM method is displayed in figure~\ref{figASCE-PM}. \begin{figure} \begin{equation} [...] ...


2

You can do this using the atbegshi package, together with an \if... statement where you set the \if... equal to true at the start of the option and then to false at the end using \setlist. Here's a MWE. I have used the same continuation message that you used above. \documentclass{book} \usepackage{enumitem} \usepackage{atbegshi} ...


2

EDIT II Here is a fully functional solution. The MWE example is yours. My code puts the watermarks on pages 2,4,5,6 and 7 and adds hyperlinks back to them at the end of the document. I'll make some comments below. \documentclass{article} \usepackage[contents={Watermarked!},pages=some]{background} \usepackage[colorlinks]{hyperref} \pagenumbering{arabic} ...


2

I'm using version 1.5 (2013) of the listings package. I use lstinputlisting to include the code from the file, and I just put float inside the options of the environment. It works fine. For example, this goes in my preamble: \lstdefinestyle{freefempp}{ language=C++, basicstyle=\footnotesize\ttfamily, commentstyle=\itshape\color{violet}, ...


1

Ah okay, only a few minutes after asking the question, I found the answer (creating the MWE helped). The problem was with the picins package loaded (I think) in the template class. If you load picins, the mdframed environments will no longer break over pages, as per this M(N)WE: \documentclass{article} \usepackage{picins} \usepackage{mdframed} ...


1

I would use a tabbing here. Much easier, not floating and behaves like normal text when it comes to page breaks. When your explanation is getting long, you will need to do a page break anyway. But like this, you are keeping equation an explanation together with nice spacing. If you really want to stay on one page with all of it, just uncomment the two ...


1

Well, with the lack of judgement of a mere user: \documentclass[12pt, a4paper]{article} \makeatletter \newcommand*{\NoBreakPar}{\vspace{\baselineskip}\par\nobreak\@afterheading} \makeatother \begin{document} Let's see the following list:\NoBreakPar \begin{itemize} \item First. \item Second. \item Third. \end{itemize} ...


1

\documentclass[12pt, a4paper]{article} \usepackage{blindtext} \begin{document} \blindtext[3] Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Etiam lobor- tis facilisis sem. Nullam nec mi et neque pharetra sollicitudin. Praesent imperdiet mi nec ante. Donec ullamcorper, felis non sodales commodo, lec- tus velit ultrices augue, a dignissim nibh ...


1

I would use a different tactic that makes the images not interfere with the placement of the text: Place them in the foreground as an overlay using eso-pic. \documentclass[11pt,a4paper,BCOR10mm,DIV11,toc=listof,parskip=full]{scrbook} \usepackage{graphicx,eso-pic} \begin{document} Here is some regular text. \clearpage \mbox{}% Just to put something on ...


1

It occurred to me that \tikz[remember page,overlay] must already wait until the page is laid out in order to work right. Nor will it change the layout since it overlays the existing text. \documentclass{memoir} \usepackage{tikzpagenodes} \newlength{\tempx} \newlength{\tempy} \newcommand*\shybar{\ifvmode\tikz[remember picture,overlay]% start of paragraph ...



Only top voted, non community-wiki answers of a minimum length are eligible