Is there a way to group tables and images and show them on the verso (left hand) page only?
I'd like my tables/images on the left and my text on the right.
Thanks!
General ⇒ Force images/tables to verso
Force images/tables to verso
Try the following example:
The relevant code goes between two dashed lines. If you want all the text in the right-hand pages, simply remove the line
Code: Select all
\documentclass[twoside]{article}
%-----------------------------------------------------------------------------
% Put this block in the preamble
% This package defines the \EveryShipout command
\usepackage{everyshi}
% We redefine some parameters to avoid floats on even pages (twosided document)
\EveryShipout{\ifodd\value{page}\gdef\topfraction{0.7}\else\gdef\topfraction{0}\fi}
\EveryShipout{\ifodd\value{page}\gdef\bottomfraction{0.3}\else\gdef\bottomfraction{0}\fi}
\EveryShipout{\ifodd\value{page}\gdef\textfraction{0.2}\else\gdef\textfraction{1}\fi}
\EveryShipout{\ifodd\value{page}\gdef\floatpagefraction{0.5}\else\gdef\floatpagefraction{1}\fi}
\gdef\topfraction{0}\gdef\bottomfraction{0}\gdef\textfraction{1}\gdef\floatpagefraction{1}
%-----------------------------------------------------------------------------
% Only for testing purposes
\usepackage{lipsum} % To generate text
\newcommand{\InsertAFigure}{% To generate figures
\begin{figure}
\centering \fbox{\parbox[][5cm][c]{5cm}{\centering A figure}}
\caption{A figure}
\end{figure}}
\begin{document}
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure \InsertAFigure \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-3] \InsertAFigure
\lipsum[1-10]
\end{document}
Code: Select all
\EveryShipout{\ifodd\value{page}\gdef\textfraction{0.2}\else\gdef\textfraction{1}\fi}
-
- Posts: 2
- Joined: Sat Dec 13, 2008 8:38 pm
Re: Force images/tables to verso
Hi all.
Apologies for dragging up an old post, but the original question is exactly the same one as I'm now trying to solve! The above solution nearly works for me (with the line removed as described) but text still appears on left hand pages when there are no figures. I'd like to be able to have all the text on the right, leaving left pages blank if required.
As an added complication, if its possible I'd like to be able to define some smaller floats to go inline using text wrapping.
Thanks for your help in advance.
Apologies for dragging up an old post, but the original question is exactly the same one as I'm now trying to solve! The above solution nearly works for me (with the line removed as described) but text still appears on left hand pages when there are no figures. I'd like to be able to have all the text on the right, leaving left pages blank if required.
As an added complication, if its possible I'd like to be able to define some smaller floats to go inline using text wrapping.
Thanks for your help in advance.
Force images/tables to verso
Perhaps you may try a more exigent set of parameters:I'd like to be able to have all the text on the right, leaving left pages blank if required.
Code: Select all
\EveryShipout{\ifodd\value{page}\gdef\topfraction{1}\else\gdef\topfraction{0}\fi}
\EveryShipout{\ifodd\value{page}\gdef\bottomfraction{1}\else\gdef\bottomfraction{0}\fi}
\EveryShipout{\ifodd\value{page}\gdef\textfraction{0}\else\gdef\textfraction{1}\fi}
\EveryShipout{\ifodd\value{page}\gdef\floatpagefraction{0}\else\gdef\floatpagefraction{1}\fi}
\gdef\topfraction{0}\gdef\bottomfraction{0}\gdef\textfraction{1}\gdef\floatpagefraction{1}
Code: Select all
\newcommand{\InsertPhantomFigure}{\begin{figure}[p]\phantom{x}\end{figure}}
Don't use the figure or table environment for this. Just directly include graphics with \includegraphics or tables with tabular. You may add captions with the \captionof command defined in the capt-of or caption packages.As an added complication, if its possible I'd like to be able to define some smaller floats to go inline using text wrapping.
The CTAN lion is an artwork by Duane Bibby. Courtesy of www.ctan.org.
-
- Posts: 2
- Joined: Sat Dec 13, 2008 8:38 pm
Re: Force images/tables to verso
Cheers, that does the trick (with the phantom figures). Not ideal I guess, but it works! I was trying to add a pagebreak command into one of the if statements but it didn't seem to work.