The fullminipage package

Similar documents
Displaying page layout variables

The nccfloats package

The plstx package. Jesse A. Tov This document corresponds to plstx v0.2, dated 2011/03/26.

mnotes annotate documents with margin comments

The supertabular environment

Dashed lines represent \hof f set and \vof f set I 2 /5-,%

Producing proceedings articles with L A TEX2ε

% \lineskip is 1pt for all font sizes. \normallineskip 1pt \def\baselinestretch{1.37}

The mcaption package

The afterpage package

The biblist Style Option

Typesetting lettrines in L A TEX 2ε documents Daniel Flipo

The totpages package

% \lineskip is 1pt for all font sizes. \normallineskip 1pt \def\baselinestretch{1.37}

The layouts package: User manual

PSTricks pst-abspos Herbert Voß

The layouts package: User manual

The NotesPages Package Filling documents, so the total number of pages is a multiple of a given number.

The crush package. Jesse A. Tov This document corresponds to crush v0.2, dated 2011/07/29.

This package allows you to add version control information as a gray watermark on each page of your document.

The showexpl package

The manyfoot package

The xtab package. Peter Wilson herries dot press (at) earthlink dot net 2008/07/26

A Sample L A TEX Document

semproc LaTeX class for seminar proceedings

Page Layout with Crop Marks

A package for rotated objects in L A TEX

The nccfancyhdr package

bizcard: A L A TEX2ε package for business/visiting/calling cards

pgfopts LaTeX package options with pgfkeys

A style option for rotated objects in L A TEX

The showkeys package

The notes.sty package for marking special sections in a document with icons

Tools for Scientific Writing with LAT E X. Johan Carlson

The keyval package. David Carlisle 2014/10/28

Changing the layout with L A TEX

The handout document class

Literate programming with R and L A TEX

The threadcol package

Documented Source Code for flowfram.sty v1.17

The adjustbox Package

The sidenotes package

The abstract package

The tensor package for L A TEX2e

The tikzpagenodes package

The showkeys package

The currency package

The l3galley package Galley code

Latex Page Number Position Bottom Right

The xtab package. Contents. List of Tables. 1 Introduction

newlfm.cls A New Letter, Fax, Memo Document Class for L A TEX2e

The count1to package

Introduction to LAT E X Part 1

The ExSol package. your original text that only contains the exercises, and

The eqlist package. Martin Väth 2002/08/15. Abstract

The dashrule package

Introduction to LAT E X Part 1. marko/latex

LATEX Primer. 1 Introduction (Read Me)

Topics in Two-Dimensional Analytic Geometry

The currency package

Introduction to LAT E X Part 1

The calculation environment

parrun User Guide Massimiliano Dominici 2004/02/06

European Computer Modern font with oldstyle digits

v2.1, dated 2014/03/04.

MATH formulas in PARragraph mode. Typesetting Inference Rules

NCCTOOLS. Release 3.5

The pagenote package

The zref package. Heiko Oberdiek <heiko.oberdiek at googl .com> 2016/05/21 v2.26

The IEEEconf class. Scott Pakin January 15, 2004

For version 2014/01/22 v1.3. John W. Shipman Jason Mattax :45

altfont: Using alternative fonts

The wheretotrim package

How to use styles, lists, columns and table of contents

How to turn on the computer: How to log on to the TC network: How to use the mouse: Essential Computer Skills

The adjustbox Package

HOW TO TYPESET THESES. Using iiscthesis style for LAT E X

Documentation of the UJAC print module's XML tag set.

The ohio-etd template for Electronic Theses and Dissertations at Ohio University

Introduction to Web Page Designing Using HTML

Instructions for Formatting MLA Style Papers in Microsoft Word 2010

8/19/2018. Web Development & Design Foundations with HTML5. Learning Objectives (1 of 2) Learning Objectives (2 of 2)

Fancy paragraph designs with the fancypar package

The moderntimeline package

Documentation for xcomment.sty

The onlyamsmath package

The svn-prov package

The pdfcolparallel package

In this course we will go over the basic functions of Microsoft Word, more advanced functions are omitted from this class and walkthrough.

What is Word? How to Open Word. Intro to Word 2010 by Lodi Memorial Library Developed by Barb Hauck-Mah for ESL Literacy Grant

The xtheorem package

The braids Package: Documentation

Formatting an APA style Paper in Google Docs 1

Exercises in LaTeX IDA on AAU

The hanging package. Contents. 1 Introduction

<body bgcolor=" " fgcolor=" " link=" " vlink=" " alink=" "> These body attributes have now been deprecated, and should not be used in XHTML.

AStyle C/C++ Source Code Formatter Plugin

About Downloads Basics Pictures Reference Help TeXer

Indian T E X Users Group URL:

The termlist package

Transcription:

The fullminipage package Christian Schneider <software(at)chschneider(dot)eu> July 6, 2014 Contents 1 Usage 2 1.1 The Environment............................ 2 1.2 Options................................. 2 2 License 3 3 Bugs, problems, and suggestions 3 4 Implementation 3 This document corresponds to fullminipage v0.1.1, dated 2014/07/06. Copyright 2012,2014 Christian Schneider <software(at)chschneider(dot)eu>, http://chschneider.eu. 1

Abstract This package provides the environment fullminipage, which generates a minipage spanning a new, complete page with page style empty. The environment provides options to set margins around the minipage and configure the background. 1 Usage fullminipage 1.1 The Environment The environment fullminipage generates a new page with page style empty, which is spanned by a minipage. The available horizontal and vertical sizes are \hsize and \vsize, respectively. Caveat: The clearing of the page before/after the fullminipage might not be done correctly in certain circumstances, in particular, multi-column documents. Please refer to the pagebreak option for details. 1.2 Options The environment fullminipage has an optional argument, which accepts a comma-separated list of key = value pairs: left right top bottom alignment bgcolor background pagebreak left margin (default: 0 pt) right margin (default: 0 pt) top margin (default: 0 pt) bottom margin (default: 0 pt). Note that content exceeding the vertical size of the minipage will not be stopped by the bottom margin. The value is rather used to calculate the vertical size of the minipage. the vertical alignment inside the minipage (one of tcb; default: t) color of the background (except for the margins, empty by default). Omitting the value will lead to a black background. A blue background can, for example, be generated with bgcolor=blue. arbitrary macro for the background (empty by default). This allows, for example, to put an image into the background with background=\includegraphics{<file>}. The image will be aligned in the lower left corner of the minipage. Note that background is put on top of the background color defined by bgcolor. macro for clearing page before and after inserting the fullminipage. By default, \newpage will be used in single-column documents and \clearpage, if a multicolumn style is detected. This detection, however, might fail and the user might want to explicitly set pagebreak=\clearpage. Note that \clearpage has the side-effect of flushing all pending floats. 2

2 License fullminipage is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License version 3 as published by the Free Software Foundation, not any later version. fullminipage is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with fullminipage. If not, see <http://www.gnu.org/licenses/>. 3 Bugs, problems, and suggestions Please report bugs and problems or send suggestions for this package to Christian Schneider. 4 Implementation The implementation is briefly described in this section. First of all, we need the keyval package for key = value options. The color package will only be required, if the background color needs to be defined. 1 \RequirePackage{keyval} 2 \RequirePackage{color} Next, the key s are defined: 3 \define@key{fullminipage}{left}{\def\fullminipage@left{#1}} 4 \define@key{fullminipage}{right}{\def\fullminipage@right{#1}} 5 \define@key{fullminipage}{top}{\def\fullminipage@top{#1}} 6 \define@key{fullminipage}{bottom}{\def\fullminipage@bottom{#1}} 7 \define@key{fullminipage}{alignment}{\def\fullminipage@alignment{#1}} 8 \define@key{fullminipage}{bgcolor}[black]{\def\fullminipage@bgcolor{#1}} 9 \define@key{fullminipage}{background}{\def\fullminipage@background{#1}} 10 \define@key{fullminipage}{pagebreak}{\def\fullminipage@pagebreak{#1}} Finally, the environment is defined: 11 \newenvironment{fullminipage}[1][]{% 12 \begingroup The key = value pairs are evaluated and a simple detection for two-column layout is performed. 13 \setkeys{fullminipage}{left=\z@,right=\z@,top=\z@,bottom=\z@,% 14 alignment=t,background={},pagebreak=\newpage}% 15 \@ifundefined{twocolumn@sw}{}% 16 {\twocolumn@sw{\setkeys{fullminipage}{pagebreak=\clearpage}}{}}% 17 \if@twocolumn\setkeys{fullminipage}{pagebreak=\clearpage}\fi% 18 \setkeys{fullminipage}{#1}% A new page is started with pagestyle empty. 19 \fullminipage@pagebreak 20 \thispagestyle{empty}% 3

The top position is calculated and the top (vertical) position adjusted with \vspace*. 21 \@tempdima=-1in 22 \advance\@tempdima by-\voffset 23 \advance\@tempdima by-\topmargin 24 \advance\@tempdima by-\headheight 25 \advance\@tempdima by-\headsep 26 \@tempdimb=\@tempdima 27 \advance\@tempdima by-\parskip 28 \advance\@tempdima by-\topskip 29 \advance\@tempdima by\fullminipage@top 30 \vspace*{\@tempdima}% The bottom position is calculated and the current page size enlarged accordingly with \enlargethispage. 31 \@tempdima=\paperheight 32 \advance\@tempdima by\@tempdimb 33 \advance\@tempdima by-\textheight 34 \advance\@tempdima by-\fullminipage@bottom 35 \enlargethispage{\@tempdima}% The position corresponding to the left margin is calculated. 36 \leftmargin=-1in 37 \advance\leftmargin by-\hoffset 38 \if@twoside 39 \ifodd\value{page}% 40 \advance\leftmargin by-\oddsidemargin 41 \else 42 \advance\leftmargin by-\evensidemargin 43 \fi 44 \else 45 \advance\leftmargin by-\oddsidemargin 46 \fi 47 \advance\leftmargin by\fullminipage@left The length of a line is calculated and the margins are set with \parshape. 48 \linewidth=\paperwidth 49 \advance\linewidth by-\fullminipage@left 50 \advance\linewidth by-\fullminipage@right 51 \parshape \@ne \leftmargin \linewidth Prepare output without extra spaces. 52 \nointerlineskip 53 \noindent The value of \vsize is calculated and set. (If it is set before the \noindent above, it will be overwritten in some cases.) 54 \vsize=\paperheight 55 \advance\vsize by-\fullminipage@top 56 \advance\vsize by-\fullminipage@bottom A zero-sized picture environment containing the background is output and the minipage is started. 57 \begin{picture}(0,0) 58 \@ifundefined{fullminipage@bgcolor}{}{% 59 \put(0,0){\makebox(0,0)[bl]% 4

60 {\color{\fullminipage@bgcolor}{\rule{\linewidth}{\vsize}}}% 61 }% 62 }% 63 \put(0,0){\makebox(0,0)[bl]% 64 {\fullminipage@background}% 65 }% 66 \end{picture}% 67 \begin{minipage}[b][\vsize][\fullminipage@alignment]{\linewidth} 68 }% The minipage is closed and a new page is started. 69 {% 70 \end{minipage}% 71 \parfillskip=\z@ 72 \fullminipage@pagebreak 73 \endgroup 74 } Change History v0.1.0 General: initial public version.... 1 v0.1.1 General: corrected README file; no L A TEX changes.......... 1 Index Numbers written in italic refer to the page where the corresponding entry is described; numbers underlined refer to the code line of the definition; numbers in roman refer to the code lines where the entry is used. Symbols \@ifundefined... 15, 58 \@tempdima..... 21 35 \@tempdimb..... 26, 32 B \begin......... 57, 67 C \clearpage..... 16, 17 \color........... 60 D \define@key...... 3 10 E \end........... 66, 70 \enlargethispage.. 35 \evensidemargin... 42 F \fi........ 17, 43, 46 \fullminipage@alignment.......... 7, 67 \fullminipage@background.......... 9, 64 \fullminipage@bgcolor.......... 8, 60 \fullminipage@bottom....... 6, 34, 56 \fullminipage@left........ 3, 47, 49 \fullminipage@pagebreak....... 10, 19, 72 \fullminipage@right.......... 4, 50 \fullminipage@top........ 5, 29, 55 H \headheight....... 24 \headsep......... 25 \hoffset......... 37 I \if@twocolumn..... 17 \if@twoside....... 38 \ifodd........... 39 L \leftmargin.. 36, 37, 40, 42, 45, 47, 51 \linewidth 48 51, 60, 67 M \makebox....... 59, 63 N \newenvironment... 11 \newpage......... 14 \noindent........ 53 \nointerlineskip.. 52 O \oddsidemargin.. 40, 45 5

P \paperheight.... 31, 54 \paperwidth....... 48 \parfillskip...... 71 \parshape........ 51 \parskip......... 27 \put........... 59, 63 R \RequirePackage.. 1, 2 \rule............ 60 S \setkeys.... 13, 16 18 T \textheight....... 33 \thispagestyle.... 20 \topmargin....... 23 \topskip......... 28 \twocolumn@sw..... 16 V \value........... 39 \voffset......... 22 \vsize.... 54 56, 60, 67 \vspace.......... 30 Z \z@........... 13, 71 6