#page number style not working

1 messages · Page 1 of 1 (latest)

modern socket
#

I use #set page(numbering: "I") before the page where my ToC is, then set the numbering back to "1" after and this is my footer chic-footer(left-side: author, right-side: counter(page).display()),
Anyone has an idea why it uses 1 on the ToC page?

dry copper
#

The solution is the following:

#
locate(loc => {
  numbering(loc.page-numbering(), ..counter(page).at(loc))
})
#

instead of your counter(page).display()

#

hope this helps

#

?render

#set page(numbering: "I")

#locate(loc => {
  numbering(loc.page-numbering(), ..counter(page).at(loc))
})
dry copper
#

see how it works?

full lagoon
#

You give display the numbering you want, and it defaults to "1" 🙂

modern socket
#

I‘ll look at it in a few minutes

full lagoon
#

Err... well... no... according to the docs, it should default to the current element's numbering style... but clearly it doesn't thonk

#

Hm.

#

If this is omitted, displays the counter with the numbering style for the counted element or with the pattern "1.1" if no such style exists.
Does that mean that the counter(page) has no style? Weird.

#

Hm, yeah. Looks like the way I did this in my projects was to literally just move my page numbering from set page into my footer's call to display. 🤷🏻‍♂️

modern socket
#

@dry copper your solution works perfectly

dry copper