Tag Info

New answers tagged

0

I cannot tell if this is quite right without printing and I don't have any letter size paper. However, something like this: \documentclass{article} \usepackage[paper=letterpaper,layoutwidth=8.5in,layoutheight=7in,landscape]{geometry}% this says the paper is letterpaper but the layout should be 8.5x7 \usepackage[newdimens]{labels}% let the package do the ...


1

Stacks make this very easy. The alignment is set with a mode parameter (\stackalignment), the gap is set with an optional stacking argument. The use of \useanchorwidth says to not allow the width of the underset to affect the spacing to the next item. EDITED to use \mathop. \documentclass{article} \usepackage[usestackEOL]{stackengine} ...


4

This doesn't work in subscripts or superscripts (it might be made so): \documentclass{article} \makeatletter \newcommand{\awfullim}{\@ifnextchar_{\@awfullim}{\lim}} \newcommand{\@awfullim}[2]{% #1 is _ \settowidth{\dimen0}{$\lim$}% \settowidth{\dimen2}{$\scriptstyle#2$}% \ifdim\dimen2<\dimen0 \lim_{#2}% \else ...


5

You need the {} to wrap the max(...). Also, it seems that n1 node assigned to \p1 should use \y1. OP's code \y2 causes error result. Code \documentclass[border=.5cm]{standalone} \usepackage{tikz} \usetikzlibrary{positioning} \usetikzlibrary{calc} \begin{document} \begin{tikzpicture} \node at (0,0) [draw] (n1) {node1}; \node at (-1,1) [draw] (n2) ...


2

Code Here is what I would do using the let path operation to access coordinates and max() function from PGF's mathematical engine: \documentclass[border=.5cm]{standalone} \usepackage{tikz} \usetikzlibrary{calc} \begin{document} \begin{tikzpicture} \node at (0,0) [draw] (n1) {node1}; \node at (-1,1) [draw] (n2) {node2}; \node at (1,2) [draw] (n3) ...


0

I have a workaround for you. Let the float object flow into one column, calculate number of lines it takes and add \enlargethispage with negative value to the second column when dealing with *[b] and \vspace* when dealing with *[t], the value is best when related to the \baselineskip dimension. It is not an automatic way, esp. when adding \vspace* inside the ...


1

You can arrange the content inside a tabular or a minipage: \documentclass{memoir} \usepackage{graphicx,float} \newsubfloat{figure} \newcommand{\tabstrut}{\rule{0pt}{\dimexpr.7\baselineskip+6pt}} \begin{document} \begin{figure}[H] \centering \begin{tabular}{c} \subbottom[QMF ...


1

I have copied this from p48 of the subfig package manual, in the FAQ section: 6.9 “I want my sub-floats to be ordered by column rather than by row, how do I do that?” The following example shows a schematic for laying out six sub-floats in column order. The only problem with this approach is that, if the floats and their respective captions ...


5

Basically the same like Gonzalo Medina's answer (who was 1 minute faster), but instead of the \raisebox you can simply play a bit with the value of the \vskip20pt. \documentclass{beamer} \defbeamertemplate{footline}{higher page number} {% \hfill% \usebeamercolor[fg]{page number in head/foot}% \usebeamerfont{page number in head/foot}% ...


6

One option, redefining the footline template in a similar fashion to the one used by the frame number option defined in beamerbaseauxtemplates.sty. You can adjust the desired location by changing the length I used in the part marked with <--- change here: \documentclass{beamer} \usepackage{datetime} \ddmmyyyydate ...


4

This modifies LaTeX's top float positioning so that it puts the top floats in the centre of the page, or at least as close to the centre as possible, if the text flow has a an unbreakable box or math display at the centre the vsplit will not split it at exactly the centre. It's not extensively tested but it works on this page:-). It applies to all top floats ...


3

Using the insbox set of generic macros, it reduces to using the \InsertBoxC command if there is no caption. This command can be used anywhere in a paragraph: at the point of insertion, the macro first ends the line with the following text, then inserts what you want to insert, and ends with the rest of the paragraph. If there is caption is more mysterious ...


3

Something more like this? The White Rabbit will always appear on page 2 in the centre of the page scaled to 37.5% of \textheight, taking 40% total including a little breathing room. Other pages are formatted much as usual: This uses flowfram. This drastically changes the way TeX outputs text and may not suit your purposes depending on the other content ...


0

The float package will do this. Use the [H] option for the float. \documentclass{article} \usepackage{float} \usepackage{tikz} \begin{document} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec varius dapibus metus eget ultrices. Nulla sagittis mauris rutrum, blandit augue eget, laoreet augue. Phasellus enim odio, sagittis in mi sed, ...


3

Transform canvas is a hardcore transformation that doesn't respect any bounding box computation or similar well-behaved updates. Hence it transforms like a boss. Here, we came to the conclusion in the comments that you would like the nodes to respect the inner transformation within the scope. That is done by the transform shape i.e. the shape of the node is ...


5

One option using the layout package to get a diagram showing the relevant parts and their dimensions: \documentclass{article} \usepackage[a5paper,hmargin=2cm]{geometry} \usepackage{layout} \begin{document} \layout \end{document} Or, anothe approach using tikzpagenodes to get a visual demarcation of the relevant areas: \documentclass{article} ...


4

Here is a simple solution via TikZ (as all other solutions...). \documentclass{standalone} \usepackage{tikz} \begin{document} \begin{tikzpicture} \node[circle,draw] (A) at (0,0) {A}; \foreach \name[count=\c,evaluate=\c as \xpos using {-3.5+\c}] in {u,...,z}{ \draw[->] (A) -- (\xpos,-2); \path (A.center) -- (\xpos,-2) node[anchor=base,near ...


6

Option anchor=base moves the reference point of the node from the middle to the base line with the effect, the nodes are aligned along their base lines. Secondly, the lines does not start at the same heights because of the circular shape of node A. Thus the relative positioning near end should refer to A.center instead to get the same vertical component for ...


4

For me the simplest solution would be to use intersections library from TikZ: \documentclass{article} \usepackage{tikz} \usetikzlibrary{intersections} \begin{document} \begin{tikzpicture} \node[circle,draw] (A) at (0,0) {A}; \draw[name path=u,->] (A) -- (-2.5,-2); \draw[name path=v,->] (A) -- (-1.5,-2); \draw[name path=w,->] (A) -- ( -.5,-2); ...


3

The only way (i know about) to get all nodes to one height is to set the label-nodes to this specific y-value. This way the y-position of the label-node is fixed and the lines are drawn using partway coordinate specifications. The following code is an short example how to do this: \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{calc} ...


8

This is very similary to one of the tutorials in the pgf manual. You should specify the text height and depth, preferrably via ex units: \documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture}[text height=1.5ex,text depth=0.25ex] \node[circle,draw] (A) at (0,0) {A}; \draw[->] (A) -- (-2.5,-2) edge[draw=none] node[near ...


0

Experimental; work in progress; unstable when mixing with regular floating Oh yes, this is a typographer's nightmare! I am preparing a general solution to this task, I think I have found a solution (after a decade of trying it, I will tell you my story later), but I am not fully ready to publish/post it yet. I can offer you this solution with several ...


8

Okay, yslant to spin vertical letters, rotate and xslant to lay letters flat, xscale and yscale for forehortening. \tikzset{yz slant style/.style={red, yslant=-tan(\elevation), xscale=cos(\elevation)}} \tikzset{xy slant style/.style={blue, xslant=-tan(\elevation+\anglerot), rotate=-\elevation, yscale=cos(\anglerot)}} \tikzset{xz slant style/.style={orange, ...


5

The documentation of dvitype contains the description of the DVI format in section "Device-independent file format". dvitype can also be used to analyze the DVI file. Example: \documentclass{article} \pagestyle{empty} \begin{document} $E = m c^2$ \end{document} "mc" are set the following way (excerpt from dvitype): 169: fntnum10 current font is cmmi10 ...


4

eso-pic provides hooks into specific page locations: \documentclass{article} \usepackage{geometry,lipsum,xcolor} \geometry{showframe,margin=1in}% Just for this example \usepackage{eso-pic} \begin{document} \AddToShipoutPictureBG*{% \AtPageUpperLeft{\raisebox{-\height}{\color{red}Page upper left}}% \AtPageLowerLeft{\color{blue}Page lower left}% }% ...


12

Here is the tikz method which uses current page.south west anchor to position the text: The \AbsolutePosition places the given text at the offset specified relative to the bottom left margin (whose coordinates are determined via the output of the \layout on the first page of the output. Notes: The showframe package was used just to show the page ...


10

This method allows you to position at any (x,y) location (relative to upper left corner of paper) on the page, and can be issued regardless of where the current location is. The only requirement is that you know what the top and left margins are, which are incorporated in \atxy. It uses the everypage package. If you prefer the origin at a different ...


4

The prime symbols are not too low, they're too small: you're requesting that first level sub/superscripts are 6pt, which is too small next to an 11pt size symbol. Computing 80% of 11pt gives 8.8pt, and the standard first level sub/superscript size for 11pt is 8pt. Of course you need arbitrarily scalable fonts for this to work (\usepackage{lmodern}, for ...


5

You should be able to go \begin{table*}...\end{table*} \begin{figure*}....\end{figure*} (There is no h option for 2-column floats). If you do that and they don't both appear on the same page then presumably that would invalidate some of the constraints on the number of floats, or of the proportion of the page that may be allocated by floats. If you want ...


6

You can simply put the code together in one floating environment, and choose the captions appropriately by using captionof from the caption package. % arara: pdflatex \documentclass[twocolumn]{article} \usepackage{lipsum} \usepackage{caption} \begin{document} \begin{figure*}[!t] \centering Figure code goes here \caption{Figure} table code goes here ...


3

Of course, the subscript can be moved to the symbol, but it still affects the line spacing, because the depth remains too large. The following example compares three variants: with \limits, subscript below, subscript below without space inbetween, default with subscript to the right. \documentclass{article} \usepackage{amsmath} \newcommand*{\lipsum}{ % ...


1

just small variation on Torbjon solution: \documentclass[border=5mm]{standalone} \usepackage{pgfplots} \pgfplotsset{compat=newest} % \pgfplotsset{compat=1.10} \usetikzlibrary{calc,positioning} \usepackage{siunitx} \pgfplotsset{cellmodel/.style={% width=0.4\linewidth, height=0.3\textheight, axis ...


5

Might be easiest to just move the definition of the mes21 and mes31 nodes outside the axis, then they use the coordinate system of the tikzpicture rather than the axis. (I changed the angle to -30.) \documentclass[border=5mm]{standalone} \usepackage{pgfplots} \usetikzlibrary{calc} \usetikzlibrary{positioning} \usepackage{siunitx} ...


2

Since multicols does not allow float environments, this proposal defines a new environment called figurehere. As you can see, the floating property is suppressed and it anchors at where one desires. This environment has been tested on subcaptionbox command from subcaption package (first image) and subfloat command from subfig package (second image). They ...


0

I solved the problem with the needspace package. You mention that all figures are of standard width. If, by chance they are also of standard height, then the solution is very easy: place a \needspace{length} prior to the call to \defineHSpace, where the length is the figure's standard vertical space (including surrounding blank space). In this way, the ...


0

Here's an option using a combination of the mdframed, newfloat, and xparse package (which is loaded by mdframed). The following line: \DeclareFloatingEnvironment[placement={!ht}]{myfloat} declares a new floating environment called myfloat, which has default placement of !ht, and can be overridden. The following lines make a new floating environment that ...


2

If you want the equation number be centred wrt the group of lines, the best is to use the multlined environment, from the mathtools package. Here is an example that shows the difference with split in such a context, with different way of aligning. Btw, with alignat, you don't have to repeat the quad separator between two groups: ...


3

it seems to me that \raisetag should work here. it works with split: \documentclass{article} \usepackage{amsmath} \begin{document} \begin{equation} \begin{split} \text{line 1} &\quad \text{is long, very long, really very long, unbelievably long, really it is such}\\ \text{line 2} &\quad \text{is short} \end{split} ...


3

Set the content using a regular align, adding \nonumber to the first part of the equation: \documentclass{article} \usepackage{amsmath} \begin{document} \begin{align} \text{line 1} &\quad \text{is long, very long, really very long, unbelievably long, really it is such} \nonumber \\ \text{line 2} &\quad \text{is short} \end{align} ...


5

You can place the figures inside a minipage of width \columnwidth (and no indent): \documentclass[a0,portrait]{a0poster} \usepackage{multicol} \columnsep=100pt \columnseprule=3pt \usepackage{subfig} \usepackage{graphicx} \usepackage[font=small,labelfont=bf]{caption} \usepackage{lipsum} \title{Morphological key at Afrilex 2014} % Poster ...


1

\documentclass{article} \usepackage{pst-plot} \begin{document} \psdot(0,0)% Toi see where we are \rput(3,-3){% \psplot[algebraic=true,linewidth=1pt,plotpoints=500]{0}{4.7}{(-x/5)*cos(4*x)}% \psplot[linestyle=dashed,linewidth=1pt]{0}{4.7}{x 5 div}% \psplot[linewidth=1pt,linestyle=dashed]{0}{4.7}{x -5 div}% } \end{document}


6

\documentclass[25pt, a0paper, landscape, margin=0mm, innermargin=15mm, blockverticalspace=15mm, colspace=15mm, subcolspace=8mm]{tikzposter} \usetheme{Desert} \title{Detecting Multi-word Expressions in Typed Text} \author{AdamG} \institute{Graduate Center} \titlegraphic{\includegraphics{example-image}} \makeatletter \renewcommand\TP@maketitle{% ...


2

I think there is no need to explicitly express how happy I was when I saw all the new features in TikZ3 and how unhappy I was when the key feature (for me) stopped to work properly from time to time. My first solution is obvious from the code itself: comment out \addtolength{\hoffset}{-1in} and \addtolength{\voffset}{-1in}. It wasn't that simple to track it ...


3

Here is an alternative using tcolorbox to created the floating box. The first version is a minimalistic approach: \documentclass{article} \usepackage[many]{tcolorbox} \usepackage{lipsum} \newtcolorbox{framefloat}[1][!tb]{arc=0pt,outer arc=0pt,boxrule=0.4pt, colframe=black,colback=white,float=#1} \begin{document} \begin{framefloat} \textbf{Box on top:} ...


2

\documentclass{scrartcl} \usepackage{varwidth} \newsavebox\FBox \newenvironment{framefloat}[1][!htb] {\begin{table}[#1]\centering\begin{lrbox}{\FBox} \varwidth{\dimexpr\linewidth-2\fboxsep-2\fboxrule}} {\endvarwidth\end{lrbox}\fbox{\usebox\FBox}\end{table}} \usepackage{blindtext} \begin{document} \blindtext \begin{framefloat}[t] \blindtext ...



Top 50 recent answers are included