1

I'm producing a fairly large volume using a customized version of book.cls with four Parts containing several chapters in \mainmatter, followed by a \backmatter that contains only the Bibliography for the whole volume (no appendices or index).

What I'm finding is that the running header of the last chapter & section is running through the \backmatter bibliography? I didn't have that problem with volumes that don't have parts and guess that the \chapter* assignment in the bibliography environment definition supplanted the prior chapter/section, but it seems that the \part is somehow getting in the way.

In a (most likely) related problem, the bookmark set by hyperref shows the \backmatter Bibliography being included (i.e. a chapter within) in the last Part.

Is there a way to test for and reset the depth in the \backmatter definition, both for the header and hyperref?

JSCard
  • 366
  • 1
    Well, modifying classes is to be avoided most times. Without any code at hand I would say \cleardoublepage\markboth{}{} before \backmatter but this is only a guess. I don't think that hyperref has to do with the problem here. Please provide the minimal document that produces this issue! –  Dec 23 '15 at 15:45
  • It's a custom .cls based largely on on book.cls... both \backmatter and \def\ps@headings have been left unchanged so far (customizations are mainly format and layout particulars). – JSCard Dec 23 '15 at 15:58
  • @ChristianHupfer -- seems to me (after double checking) that both book and amsbook have a much too minimal approach to what should be set with \backmatter. i'm putting a note into the ams-latex bugs/requests list to take a look at this, with reference to this question and comment. thanks for the idea. – barbara beeton Dec 23 '15 at 15:58
  • @barbarabeeton: Huh???? I don't know what you're talking about –  Dec 23 '15 at 15:59
  • Thanks @barbarabeeton ... I've been searching all over and have seen a couple references to some such issues with \backmatter without any real solutions or workarounds found. – JSCard Dec 23 '15 at 15:59
  • @ChristianHupfer, the same issue apparently occurs using the stock book.cls as well, which is why I'm having the problem in my customized version. I've seen references to similar problems with \appendix and \backmatter carrying through \markboth when parts are used. – JSCard Dec 23 '15 at 16:03
  • @Scard: Actually, I doubt the usefulness of those \....matter commands in general . Perhaps you can drop them –  Dec 23 '15 at 16:04
  • @ChristianHupfer, too late in the production game to make that kind of structural change, unfortunately... would need too much additional coding to get the volume into the required layout. A number of formatting switches are set in the class based on \if@mainmatter etc. – JSCard Dec 23 '15 at 16:07
  • @Scard: Can you post the smallest possible document that has this issue. I'll see what's possible then –  Dec 23 '15 at 16:08
  • @Scard -- one problem noticed here with amsbook is that in the toc, biblio and index are subsumed under the last part; that's probably what you mean by the hyperref reference. one workaround i've considered is to treat the toclevel of any \chapter* element in the backmatter the same as a part, but i don't have working code. – barbara beeton Dec 23 '15 at 16:22
  • @barbarabeeton, that sounds like the same problem... as a temp workaround, is there some way to insert something into the \backmatter definition that would test if \value{part}>0 and issue a "phantom" part or otherwise increment the part counter in a way that might chuck it back to the same depth?? I don't want to use \part*{} so as not to have any output... – JSCard Dec 23 '15 at 16:29
  • @Scard -- i intend to test possibilities, but don't have a good experimental file at the moment. also, amsbook works differently from book, and that's the one i have to solve the problem for. if i come up with something soon, i will share it, but i've got some other priorities higher on my to-do list at the moment. – barbara beeton Dec 23 '15 at 16:48
  • @barbarabeeton, understandable... I'm working on a dropdead deadline on this one myself... thus my slight panic - trying to find a quick workaround on this and two other smaller issues by tomorrow morning :) – JSCard Dec 23 '15 at 17:11
  • Found a partial workaround for now... actually it's partly using something from another question answered by @ChristianHupfer to fix the bookmark level in the pdf at least (added \ifnum \value{part}>\m@ne \renewcommand{\toclevel@chapter}{-1} \fi to the \backmatter definition), and just set frontmatter and backmatter pagestyle to plain... does what I need for now at least. I'll work on something more robust once thsi current deadline passes... now on to "chapter authors" and separate lists for authors and contributing authors on the titlepage... – JSCard Dec 23 '15 at 20:28
  • how do you add your bibliography? can you add a MWE? – touhami Dec 23 '15 at 21:01
  • @Scard: To which answer by me do you refer? –  Dec 23 '15 at 21:15
  • 1
  • using book.cls I don't have problem of heading, well your question is not clear for me. 2) for bookmarks you can try `\backmatter
  • \bookmarksetup{startatroot}frombookmark` package.

    – touhami Dec 24 '15 at 07:46
  • @ChristianHupfer, it was an answer to Change bookmark depth – JSCard Dec 31 '15 at 02:27
  • @touhami, I'll see if I can put up an MWE soon... a bit swamped at the moment with post-holiday catch up work. The issue seems to only appear if there are parts set in the mainmatter structure, in which any chapters in backmatter retain the header/footer marks of the last mainmatter content. As a secondary issue, hyperref then also places them hierarchically within the last part set instead of as a base-level bookmark. \backmatter should, one would think, be resetting that hierarchy but doesn't. – JSCard Dec 31 '15 at 02:35