LaTeX forum ⇒ Theses, Books, Title pagesMake page numbers on bottom in landscape page Topic is solved

Classicthesis, Bachelor and Master thesis, PhD, Doctoral degree
byn
Posts: 56
Joined: Fri Jun 10, 2022 12:27 pm

Make page numbers on bottom in landscape page

Postby byn » Thu Dec 08, 2022 3:30 am

I would like to know how to make the page number in a landscape page go to the bottom of the page. The link to the minimum working example of my code is here on the link below; https://drive.google.com/file/d/1fO0s9Z ... share_link

The picture of the landscape page is shown here below;

Recommended reading 2021:

LaTeXguide.org • LaTeX-Cookbook.net
LaTeX Beginner's Guide LaTeX Cookbook
byn
Posts: 56
Joined: Fri Jun 10, 2022 12:27 pm

Make page numbers on bottom in landscape page

Postby byn » Thu Dec 08, 2022 3:38 am

This is the output of the page numbering

page-number.JPG
page-number.JPG (113.32 KiB) Viewed 536 times


the whole file output is here below

main-landscape-page-number.pdf
(892.03 KiB) Downloaded 9 times

User avatar
Stefan Kottwitz
Site Admin
Posts: 9933
Joined: Mon Mar 10, 2008 9:44 pm

Make page numbers on bottom in landscape page  Topic is solved

Postby Stefan Kottwitz » Fri Dec 09, 2022 11:12 pm

A solution from John Kormylo here, is add to your preamble:

\usepackage{everypage}
\newcommand{\Lpagenumber}{\ifdim\textwidth=\linewidth\else\bgroup
  \dimendef\margin=0 %use \margin instead of \dimen0
  \ifodd\value{page}\margin=\oddsidemargin
  \else\margin=\evensidemargin
  \fi
  \raisebox{\dimexpr -\topmargin-\headheight-\headsep-0.5\linewidth}[0pt][0pt]{%
    \rlap{\hspace{\dimexpr \margin+\textheight+\footskip}%
    \llap{\rotatebox{90}{\thepage}}}}%
\egroup\fi}
\AddEverypageHook{\Lpagenumber}%


Stefan
LaTeX.org admin

byn
Posts: 56
Joined: Fri Jun 10, 2022 12:27 pm

Make page numbers on bottom in landscape page

Postby byn » Sat Dec 10, 2022 9:18 am

Works well!


Return to “Theses, Books, Title pages”

Who is online

Users browsing this forum: No registered users and 2 guests