LaTeX forum ⇒ Theses, Books, Title pagesNew Page style in Legrand Orange Book

Classicthesis, Bachelor and Master thesis, PhD, Doctoral degree
mahtlinux
Posts: 3
Joined: Fri Aug 14, 2020 10:59 pm

New Page style in Legrand Orange Book

Postby mahtlinux » Sat Aug 15, 2020 7:20 pm

Hello everyone,
I'm trying to make a new page style work in the Legrand Orange Book. Once I have applied the new style for a range of pages inside a chapter, I'm not able to return to the original Fancy style by including \pagestyle{fancy} and the new Style is also applied to the rest of the book.
Thanks in advance.
Last edited by cgnieder on Sun Aug 23, 2020 7:58 pm, edited 1 time in total.
Reason: Added code markup

rais
Posts: 273
Joined: Sun Nov 16, 2014 8:51 pm

Postby rais » Sun Aug 16, 2020 7:56 pm

and how did you create this new page style of yours?

KR
Rainer

mahtlinux
Posts: 3
Joined: Fri Aug 14, 2020 10:59 pm

Postby mahtlinux » Mon Aug 17, 2020 9:51 am

Hi,
in the structure.tex file I've included this:

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \newlength{\myoddoffset}
  2. \setlength{\myoddoffset}{\marginparwidth}
  3.  
  4. \fancypagestyle{mystyle}{
  5. \fancyhead{}
  6. \renewcommand{\pagecolor}{blue!5!white}
  7. \renewcommand{\headrulewidth}{0pt}
  8. \fancyfootoffset[leh,roh]{\myoddoffset}
  9. \fancyfoot[RO, LE] {\thepage}%
  10. }


Then I've applied it inside a chapter with:

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \newpage
  2. \pagestyle{mystyle}


At the end of the chapter I try to change to the previous style with:

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \newpage
  2. \pagestyle{fancy}


but it remains my style and it is applied to the rest of the book as well.

Thanks for the help.
Last edited by cgnieder on Sun Aug 23, 2020 7:59 pm, edited 1 time in total.
Reason: Added code markup

rais
Posts: 273
Joined: Sun Nov 16, 2014 8:51 pm

Postby rais » Mon Aug 17, 2020 8:05 pm

weird.
Try
Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \newpage
  2. \begingroup
  3. \pagestyle{mystyle}

to switch to your style and
Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \newpage
  2. \endgroup

to switch back to the original page style.

Or if your style is limited to a single page anyway, try
Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \newpage
  2. \thispagestyle{mystyle}

instead.

KR
Rainer

mahtlinux
Posts: 3
Joined: Fri Aug 14, 2020 10:59 pm

Postby mahtlinux » Tue Aug 18, 2020 10:46 am

It works!
Thank you very much.


Return to “Theses, Books, Title pages”

Who is online

Users browsing this forum: No registered users and 2 guests