{geometry} is a package that allows to change the margins of (whole) pages and, conversely, the width and height of the textblock and its positioning on the page.

learn more… | top users | synonyms

28
votes
3answers
6k views

Change paper size in mid-document

My document should be letterpaper and my attachments should be a4paper. I had high hopes for the \newgeometry command from the geometry package, but the documentation says \newgeometry is almost ...
11
votes
2answers
13k views

How can I fix the error “GUI framework cannot be initialized” with TeXnicCenter and MiKTeX?

I don't know what I've done, but all of a sudden I am unable to compile any document which uses the geometry package. Minimal (non)-working example: \documentclass[11pt]{article} ...
128
votes
4answers
24k views

Why are default LaTeX margins so big?

I've read that—unless I know a lot about typesetting—I shouldn't change the margins of a LaTeX document. The default margin size of the article class is really big and it feels like a lot of space is ...
20
votes
2answers
15k views

Different margins for title page

My document class is article with a4paper. The margins that I want for the body are: top: 1 inch bottom: 1 inch right: 0.5 inch left: 1.5 inch The title page should have a 1 inch margin on all four ...
8
votes
1answer
370 views

Automate Fixed Width Page, length > some minimum length, but only as long as needed

I am trying to automate the solution proposed by egreg to How define a fixed width page, but length > some minimum length, but only as long as needed by hooking into \begin{document} and ...
11
votes
2answers
1k views

What's the absolute largest paper size permissible with pdflatex?

I've had occasion to typeset extraordinarily large matrices, which I didn't seriously expect anyone to expect in detail (without a computer) or print, but I needed it to be obvious that they were ...
14
votes
3answers
5k views

Fitting page size to a tikz figure

Sometimes I'm using tikz as a plotting tool, without embedding the figure in a document. In this case, I normally, want to include the resulting PDF in a different TeX file (yes I know I could include ...
18
votes
4answers
7k views

Draw true page border

Is there a way to draw a rectangle around every page? The problem is that my document (a Ph.D. thesis) is in a funny format (16x24cm). So to print it centered on A4 paper (for reviewing) I played ...
8
votes
1answer
275 views

How define a fixed width page, but length > some minimum length, but only as long as needed

This recent question on how to increase the width of the output, and this earlier question on how to increase the length of the output reminded me of something I have been wondering: I would like to ...
20
votes
5answers
3k views

Wrong A4 measurements?

I noticed that the paper size invoked by a4paper is not working right in my examples: \documentclass[a4paper,11pt,oneside]{article} \begin{document} Test \end{document} I checked with Preview.app ...
16
votes
2answers
4k views

How can I get todonotes in the left margin

I want to use the package todonotes. Standard, the package prints the todo's in the right margin, while I want to have them in the left margin. Funny is, that in the manual itself they are placed in ...
6
votes
1answer
2k views

How to determine head height automatically

I'm creating three documents with three different headers, containing images or large banners. Is there a way to determine the head height automatically or even better a way to change the head height ...
14
votes
2answers
2k views

Storing the original document class page layout with geometry

Is it possible, using the geometry package, to store (and restore) the original layout specified by the document class (in my case, the class is report)? Here is some context. I have been editing ...
8
votes
1answer
2k views

Change page layout after first page

currently I'm trying to prepare a letter head with XeLaTeX. The first page of the letter should have a sidebar on the right. For this sidebar, the text width should be shrinked to approx. 80% of its ...
9
votes
1answer
3k views

geometry, fancyhdr: \fancyfoot[C]{\thepage} is not really centered

After switching from the report class to the book class and starting to use the fancyhdr package to control headers/footers, the page numbers in my footers are no longer centered. This is my fancyhdr ...
4
votes
3answers
3k views

Change \headheight for a \pagestyle

I have a document class that auto generates header from some user input. The problem is the first page should have a different page header than the others and the headline can be multi line. So ...
3
votes
2answers
114 views

Displaying layout marks in a document set with different layouts

Is there any package that allows for the display of layout marks within a document where the layout changes several times throughout? I'm using the geometry facilities to issuing \newgeometry commands ...
7
votes
1answer
230 views

How to have headers, section headings, and figures expand into the margin?

I am interested in the following page layout. How to have headers in margins (up to margin) Is it possible to start section headings from margin How to set figures occupy the margins. I can ...
4
votes
1answer
320 views

A5 booklet printing — Title page and TOC are missing

I have a file bookletdemo.tex with the following code \documentclass[12pt]{article} \usepackage[a5paper]{geometry} \usepackage{lipsum} % this package is for creating filler text \author{N.~N} ...
3
votes
1answer
8k views

How can I change the margins in LaTeX? [duplicate]

How do I change the margin of all pages? I want the latex page be .25 in margin around all the pages.
10
votes
4answers
249 views

\newgeometry doesn't work with Turkish babel package

\newgeometry is a nice feature of geometry package. I found out that it doesn't work (together with many other problems) when \usepackage[turkish]{babel} is also used with many errors stating: ...
6
votes
1answer
721 views

Getting layout parameters from the geometry package

The geometry package provides a simple way to set layout parameters. For example, \usepackage[margin=1in]{geometry} will give me a document with 1 inch margins on each side. In particular, it ...
5
votes
1answer
166 views

Showing margins/frames in beamer slides

With a regular article/report/... class, you can use the showframe package to draw outlines of where the various regions of the page lie. I cannot get the same functionality with beamer, however. ...
3
votes
2answers
1k views

Problem with setting correct custom page size with 'geometry' in xelatex

I'm trying to set the page size using the geometry package as shown in the following MWE, compiled with xelatex test.tex: \documentclass[12pt]{article} \usepackage[b5paper,pass]{geometry} ...
7
votes
1answer
456 views

Standard way of handling oversize pages?

In a book project, using \geometry{letterpaper}, there are occasional places where an oversize diagram has to be included — one much wider than a normal page — without being reduced or spread across ...
4
votes
2answers
6k views

Changing oneside and twoside layout

Is there any solution to use different layouts according to the oneside or twoside specification? The first part of my report (abstract, ToC, LoF, LoT) should be in oneside mode and the rest of the ...
2
votes
1answer
9k views

Enumerated list indentation

I noticed that when I use enumerated list environment it produces an extra indentation to the document. So that if I'm using \usepackage[margin=3cm]{geometry} and then the enumerated list, the left ...
1
vote
1answer
63 views

How to show margin distances in mm

I would like to know the distance (in mm) of the margins I just set, and I would like them to be displayed in the document (for debugging purposes, of course). I use the showframe option of the ...
1
vote
1answer
48 views

page margins not respected after A3 page insertion in A4 document

I am inserting an A3 page in an A4 document but the margins are not respected (and neither does a page number appear), after the A3 page. Test code below: ...
20
votes
2answers
2k views

Default margins for geometry package

I want to explicitly specify sizes of my document. For this purposes I use geometry package. I do the following (I found the solution here): \documentclass{article} \usepackage[paperwidth=2394pt, ...
12
votes
1answer
9k views

Defining page margins with \geometry for two-sided documents

How do you set page margins using \geometry for a two-sided document? So far I've used the twoside option in my documentclass, which automatically widens the left/right margin on opposite sides of odd ...
19
votes
5answers
1k views

Different margin on first page

To meet the conditions of our corporate design I need other margins on the first page of each document. The normal page layout is given by \usepackage[left=3cm,right=2cm,bottom=3cm,top=2cm]{geometry} ...
5
votes
1answer
351 views

All the document in only one long and continuous page

Well, may be this is not really useful, but I've thought if it was possible to put all the document in one long page. I mean, if your document is going to be read in a computer, mix all the pages in ...
15
votes
2answers
826 views

Problem with the geometry package reset option

Page 11 of the geometry package manual says that the reset option sets back the layout dimensions and switches to the settings before geometry is loaded. On page 30 there is a slightly different ...
9
votes
1answer
595 views

fancyhdr not centering after changed geometry

I have a document with different page margins, so I have to change geometry settings after fancyhdr loaded. However, the width of header after geometry is not correct. \documentclass[12pt]{article} ...
6
votes
1answer
678 views

Geometry: showframe + landscape

I'm using \usepackage[showframe]{geometry} and I'm seeing that when I use a landscape environment (added by pdflscape package) the frame doesn't seem to be OK. Is this an erratum? Is there any way ...
3
votes
3answers
2k views

Small bug in geometry.sty

Complete Top Left Corner Top Right Corner Bottom Left Corner Bottom Right Corner \documentclass[dvipsnames,dvips,cmyk]{minimal} \usepackage{xcolor,calc} \usepackage[% ...
2
votes
1answer
6k views

How can I set up the left/right margin of the page to 1 inch, the top/bottom one to ½ inch?

I try to set up the left and right margins to 1 inch, top and bottom margins to 0.5 inch. The following is my code: % Setup the margin \usepackage[centering, margin={1in, 0.5in}, ...
10
votes
2answers
4k views

Problem with the header/ footer width

I have recently started using the geometry package to format the margins of my documents. Although, I've noticed that the width of the header/ footer remains the same. How can I correct this? ...
6
votes
1answer
435 views

A perpendicular line to a plane in 3D

I have two line segments identified by two end points each. Two line segments are in the same plane and intersecting at a point. I would like to draw a line (normal of the plane) passing through the ...
5
votes
3answers
8k views

Edit margins in res.cls (How to pass through correct value for “margin”?)

I'm creating a resumé using the res.cls package and need to make the left and bottom margins smaller. I know I can use e.g. \topmargin=-0.5in to decrease the space at the top of the page, but neither ...
4
votes
0answers
950 views

Attempts to manually change \linewidth ignored by LaTeX [closed]

I was going to try to answer the question: How can I change the geometry of a page on the chapter header page only, and return to normal on the next page? It didn't seem like it should be too ...
3
votes
2answers
67 views

Prelim2e marking but centred without tikz

I use preliminary markup on draft versions of documents which specifies the svn repository number, timestamp, url etc. I prefer this to be typeset centred at the bottom of the page below the footer. ...
2
votes
1answer
2k views

Setting different margin sizes in different pages [duplicate]

Possible Duplicate: Change \textwidth and \textheight in mid-document I am currently using geometry package to set margin sizes. I want to set different \topmargin sizes for different ...
2
votes
1answer
1k views

How to define a custom PDF page size without margins and header/footer? KOMAscript

I want to create a PDF file with pdflatex which has a custom page size: \pdfpagewidth=680.6pt \pdfpageheight=441.0pt and which will be used completely for typesetting (no margins, no header or ...
1
vote
2answers
999 views

How to avoid getting cropped marginpar?

I'm using the fixme package to add notes to various parts of my thesis draft. However, if I set the margins using the geometry package, I notice that the fixme notes are not formatted correctly (with ...
0
votes
0answers
66 views

Geometry on last page of document

I would like the geometry of my file to be different on the last page of the document. I have tried something like: \AtEndDocument{\newgeometry{left=0.6in,right=0.6in,top=0.6in,bottom=1.8in}} But ...
8
votes
2answers
1k views

Exact centering of full-page background image

Here's the situation: I have to use memoir (v3.6j), with geometry (v5.6) and LuaTeX, version beta-0.70.1-2011061410 (rev 4277) in an A5 project which, in the final output have to be 3mm larger from ...
5
votes
1answer
170 views

afterpage clashes with restoregeometry from the geometry package

I'm writing my thesis and have used the geometry package to control the size of the text body so that it follows 'good' typesetting practices as described in the KOMA-script documentation. Many of ...
5
votes
3answers
209 views

Non-alternating margins in book class

For a book class, I specify margins like this: \usepackage[top=1.25in, bottom=1.25in, left=1.5in, right=1.25in]{geometry} But left and right appear to behave as inner and outer. I need to have the ...