Feature: go to text/start reference in epub guide section at first start#156
Conversation
|
This has the potential to skip things like forewards and dedications / other preamble. If people want to skip over it, I think the chapter select screen should be sufficient. I'm not really keen to just auto-skip to chapter 1. Spec: https://idpf.org/epub/20/spec/OPF_2.0.1_draft.htm#Section2.6 |
|
Correct, it would skip the "front matter", including the cover and publisher images (which we don't render anyways). I am used to this behavior from kindle (maybe other readers) and thought it a good solution to skip over those "unnamed" and garbage chapters. I agree it could be confusing and/or not what ppl want. How about a popup with a question, incl a list of chapters that would be skipped? or we could breselect the |
|
@jonasdiemer @daveallie When loading the book for the first time, it could be implemented so that holding down the “Right” button takes you directly to Chapter 1. Those who do not want to skip it will be able to move forward page by page. |
|
After a bit more digging, it looks like the field of ereaders out there generally honor the guide and jump to the start. Given that's where the crowd is, happy to merge this one, will just need a small conflict resolution. |
## Summary - **What is the goal of this PR?** Add chapter selection support to the XTC reader activity, including parsing chapter metadata from XTC files. - **What changes are included?** Implemented XTC chapter parsing and exposure in the XTC library, added a chapter selection activity for XTC, integrated it into XtcReaderActivity, and normalized chapter page indices by shifting them to 0-based. ## Additional Context - The reader uses 0-based page indexing (first page = 0), but the XTC chapter table appears to be 1-based (first page = 1), so chapter start/end pages are shifted down by 1 during parsing.
## Summary * Accept big endian version in XTC files * Recently, two issues (crosspoint-reader#157 and crosspoint-reader#146) have popped up with XTC files with a big endian encoded version. This is read out as 256. * We should be more lax and accept these values.
## Summary * Split XTC file version into major minor bytes * Continue to support both 1.0 and 0.1 ## Additional Context * See crosspoint-reader#146 (comment) for more detail FYI @treetrum @eunchurn
…rosspoint-reader#153) The default version parses a lot of files and takes ~5s on my machine. This adds an option `-g` to run only on files modified/staged in git.
* Swap to updated SDCardManager which uses SdFat * Add exFAT support * Swap to using FsFile everywhere * Use newly exposed `SdMan` macro to get to static instance of SDCardManager * Move a bunch of FsHelpers up to SDCardManager
## Summary * Show previous title for unnamed spines * The spec is a little unclear, but there are plenty of cases where chapters are split up in parts and should show the previous chapter's title * List TOC items instead of spine items in chapter select * Bump `BOOK_CACHE_VERSION` to `2` to force regeneration of spine item's TOC indexes
## Summary * Swap out Bookerly font due to licensing issues, replace default font with Aleo * I did a bunch of searching around for a nice replacement font, and this trumped several other like Literata, Merriwether, Vollkorn, etc * Add Noto Sans, and Open Dyslexic as font options * They can be selected in the settings screen * Add font size options (Small, Medium, Large, Extra Large) * Adjustable in settings * Swap out uses of reader font in headings and replaced with slightly larger Ubuntu font * Replaced PixelArial14 font as it was difficult to track down, replace with Space Grotesk * Remove auto formatting on generated font files * Massively speeds up formatting step now that there is a lot more CPP font source * Include fonts with their licenses in the repo ## Additional Context Line compression setting will follow | Font | Small | Medium | Large | X Large | | --- | --- | --- | --- | --- | | Aleo |  |  |  |  | | Noto Sans |  |  |  |  | | Open Dyslexic |  |  |  |  |
…t-reader#164) ## Summary * Add setting for line spacing to adjust space between lines * Aleo is already a bit tighter than Noto Sans and Open Dyslexic, so have adjusted the values to match, this can be tweaked in the future
## Summary * Parse the author name from content.opf file * Listed in the dc:creator tag within the metadata section
|
OK, I (hopefully) resolved the conflicts. Anyhow, I think it might even be a good default behavior to show the Chapter selection activity on first open (with the |
|
oops, sorry I think I made some more conflicts 😬 as you were resolving those ones (looks like you sorted it) I think we should just throw them into the content, even just testing with apple books, it drops you right into the prelude from the book I was testing with. |
…art (crosspoint-reader#156) This parses the guide section in the content.opf for text/start references and jumps to this on first open of the book. Currently, this behavior will be repeated in case the reader manually jumps to Chapter 0 and then re-opens the book. IMO, this is an acceptable edge case (for which I couldn't see a good fix other than to drag a "first open" boolean around). --------- Co-authored-by: Sam Davis <sam@sjd.co> Co-authored-by: Dave Allie <dave@daveallie.com>
…art (crosspoint-reader#156) This parses the guide section in the content.opf for text/start references and jumps to this on first open of the book. Currently, this behavior will be repeated in case the reader manually jumps to Chapter 0 and then re-opens the book. IMO, this is an acceptable edge case (for which I couldn't see a good fix other than to drag a "first open" boolean around). --------- Co-authored-by: Sam Davis <sam@sjd.co> Co-authored-by: Dave Allie <dave@daveallie.com>
This parses the guide section in the content.opf for text/start references and jumps to this on first open of the book.
Currently, this behavior will be repeated in case the reader manually jumps to Chapter 0 and then re-opens the book. IMO, this is an acceptable edge case (for which I couldn't see a good fix other than to drag a "first open" boolean around).