Comments (5)
Questions:
- is the behaviour the same for recto & verso pages? Yes
- what happens when chapter becomes too long to safely print on a single page in ANY case?
- can we find any similar issues in prince forum
from pressbooks-book.
When the chapter becomes too long to safely print on a single page in any case, we see similar behaviour:
on the opening page of a chapter, running feet = two lines, with the threshold for the first line appearing to be ~35 characters. The second line continues for another ~35 characters max. The cutoff always happens at the end of a word, not in the middle of a word. The total character count included in my (McLuhan) example here is 67:
on subsequent pages in a chapter, running feet = two lines, with seemingly double the threshold for included characters (character count here is 135):
Curiously, for too-long chapter titles, the page number disappears on recto pages but appears on verso pages. This is true regardless of whether the page is an opening page for a chapter or a subsequent page:
That being said, there are no observable differences between recto and verso pages with chapter titles that are not too long to print in full.
I haven't been able to find similar issues in prince forum.
from pressbooks-book.
This came up for a different user (https://pressbooks.zendesk.com/agent/tickets/13657 for internal reference) using Christie theme and trying McLuhan too. Running feet have a different wrap length on the first pages of chapters and Parts vs. in other pages in a PDF export.
In this case, a workaround is omitting running content from the first page of each chapter or Part. This can be done using a PDF editor to construct a final PDF from two export files (one with running content and one without) or possibly by using CSS.
If an author wants to include running content on every page, in a theme where running content appears in running feet, I don't know of a workaround that allows for exporting the running feet with the same wrap length throughout the book.
from pressbooks-book.
Talked with @greatislander about this. This is being caused by a mixin that sets content to blank for every page position on the first page of content. He'll add some notes.
from pressbooks-book.
Basically what appears to be happening is this:
A book theme might show running content at the top outside of a page except on the first page of a chapter. This would be achieved with the following CSS:
@page chapter:left {
@top-left {
content: "My Running Content";
}
}
@page chapter:right {
@top-right {
content: "My Running Content";
}
}
So far so good. However, the first page a chapter will have this running content in the top left or right (depending on recto-verso rules) so we need override it like this:
@page:chapter:first {
@top-right {
content: '';
}
@top-left {
content: '';
}
}
Then we can explicitly add rules after the blank reset to show whatever content we want on the first page (which will usually be different and usually is only in the footer, but varies from theme to theme.
Here's the code in Buckram that does this: https://github.com/pressbooks/buckram/blob/27504fc3322278b33ea751772f282bfeda34a5ff/assets/styles/components/structure/_blank.scss#L11-L86
But, there's a problem. Because are setting all these areas to have a blank string as content, it appears that we're preventing any overflow into other areas.
So for this issue, the content is set to appear in @bottom-right
but unlike other pages in the chapter, it is constrained to @bottom-right
because @bottom-center
already has content (a blank string).
I think the fix for this is quite straightforward, though. Rather then setting content to ''
I think the blank
mixins can be updated to use content: unset
(the unset
keyword basically tells the rendering engine to remove any styles that have been applied to this property). So instead of the @bottom-center
having a blank string it would have nothing and the layout would work as expected. I'm opening a Buckram PR for thisβ you can test it in McLuhan by copying the _blank.scss
file from my Buckram PR into packages/buckram/assets/styles/components/structure/
.
from pressbooks-book.
Related Issues (20)
- Insufficient color contrast for table captions HOT 1
- Update or remove soberwp/intervention dependency
- Media attachment page interface options misleading HOT 2
- Reduce screen size of footer navigation at large magnification
- export to epub HOT 3
- /h5p-listing/ not including the [h5p id="1"] HOT 6
- Unwanted info warnings from EPUBCheck when TTF font files are used
- With the new "Display CTA" setting in the network settings, the webbook shows a javascript error in the Firefox console if "Display CTA =0". HOT 2
- Only Super Admins able to embed IFrame from My Open Math Lab (https://www.myopenmath.com/) HOT 2
- Internal links to chapters not following the "Chapter-#" title format result are not clickable in PDF exports HOT 2
- Refactor to be PSR compatible
- Unwanted info warnings for EPUB exports when using 'Ancient Greek' HOT 2
- Customize access denied message based on user's login state HOT 3
- Same-page internal links to not work in webbbook when collapsed headings enabled
- Ontario Commons Licenses missing in webbooks
- Update multiple French translations HOT 8
- No Indent Class not shared to PDFs when paragraph is inside a shaded textbox HOT 2
- Glossary term short code visible in table of contents
- Aria-label for site icon includes book title HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pressbooks-book.