TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I aim at using to types of chapter headings in my document: for preambule and appendix, simple underlined upper case, while for the main chapters, I want to have a full page with "chapter n / Title" on two different lines…

I (almost) managed to do it by defining a new environment "chapterpage" and by passing arguments to \titleformat (from titlesec package) as macros (that are not defined in the same way in global and chapterpage environments.

However, I do not manage to pass the first optional argument to \titleformat following this way :( I need this as I want to use a hang shape in the former layout and a display one in the latter. I suspect it may be solved using the appropriate \protect commands, but I did not manage to fix it!

Here is a minimal example. If it worked, "Chapter 2" and "Bar" should be printed on different lines. Thank you for your help.



\newcommand{\mychapterShape}{hang} % hang is for aligning the number with the title
\newcommand{\mychapterLabel}{\thechapter} %{\relax}

{} % end chapterpage envt 





share|improve this question
up vote 2 down vote accepted

I would define two chapter styles








share|improve this answer
That works… thanks! – Thomas Julou Apr 24 '11 at 21:00
@Thomas: it's common to mark the answer as accepted, or, if you want to wait for possible other answers, to at least mark it as useful. – egreg Apr 24 '11 at 21:06
Done! Please accept my newbie apologizes :) – Thomas Julou Apr 25 '11 at 8:56

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.