8000 "Chapter [ref]" does not typeset well in python · Issue #50 · UBC-DSCI/introduction-to-datascience-python · GitHub
[go: up one dir, main page]

Skip to content

"Chapter [ref]" does not typeset well in python #50

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
trevorcampbell opened this issue Dec 17, 2022 · 4 comments · Fixed by #255
Closed

"Chapter [ref]" does not typeset well in python #50

trevorcampbell opened this issue Dec 17, 2022 · 4 comments · Fixed by #255
Labels
1st edition Planned for inclusion in 1st print edition bug Something isn't working

Comments

@trevorcampbell
Copy link
Contributor
trevorcampbell commented Dec 17, 2022

In the R version of the book, it typesets as "Chapter X" which is fine.

In python, it typesets as "Chapter [name of chapter]", e.g. "Chapter Python and Pandas", which doesn't read well.

We should just fix this by moving the word "Chapter" after the section reference. So now the text will read something like

"we will show in the Python and Pandas chapter, ..." (with a hyperlink)

@trevorcampbell trevorcampbell added the bug Something isn't working label Dec 17, 2022
@trevorcampbell
Copy link
Contributor Author

I will fix this in Chapters 1 and 2 as part of my polish pass before the semester in #48 and #49

but we should keep this issue open until we go through globally and fix

This was referenced Dec 24, 2022
@trevorcampbell
Copy link
Contributor Author
trevorcampbell commented Jan 4, 2023

Update -- I believe #44 changes how chapters are typeset to include numbers, so we will need to check whether our most recent edits break chapter links again and may need to revert back to the old style.

Scratch that, the original issue persists, so we should keep changing to the new wording.

@trevorcampbell trevorcampbell added needs-investigation Further information is requested and removed needs-investigation Further information is requested labels Jan 4, 2023
@trevorcampbell
Copy link
Contributor Author
trevorcampbell commented Sep 12, 2023

Right now we use {ref}[reference name], but if we do {numref}[reference name] we should be able to go back to the original numerical chapter referencing.

However, we need to check how that typesets in PDF (and how the original {ref}... typesets too)

In HTML, doing {numref} typesets like "In Section X.Y, ..." -- "chapter" would be preferred over "section", although not for subsection refs. I wonder if we can configure that

@trevorcampbell trevorcampbell added the 1st edition Planned for inclusion in 1st print edition label Sep 17, 2023
@trevorcampbell
Copy link
Contributor Author

We can do

{numref}`Chapter %s <ref-name-here>`

To typeset chapter refs in the same way as in the R book.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1st edition Planned for inclusion in 1st print edition bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant
0