View Single Post
Old 08-22-2014, 02:02 AM   #3260
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 7,028
Karma: 4604637
Join Date: Dec 2011
Location: Midwest USA
Device: Kobo Clara Colour running KOReader
Quote:
Originally Posted by Amalthia View Post
I downloaded a story: http://archiveofourown.org/works/1426027

On the HTML page it says "Chapter 1: Mirror"

However, when I view the story in Calibre the chapter header say "1. Mirror"

Where did the word "Chapter" go? And how can I bring it back?

The only code I have in my personal.ini related to chapters is this:
Code:
exclude_notes:authorheadnotes,chaptersummary,chapterheadnotes,
chapterfootnotes,authorfootnotes
Ideally what I like to see for this story is "Chapter 1 - Mirror"
FFDL takes the chapter names from the chapter list, not the chapter pages.

You can accomplish what you want by changing the chapter title settings. (The exclude_notes setting is just for AO3 notes, nothing to do with chapter titles.)

I haven't tested it, but it should be something like this:

Code:
[archiveofourown.org]
strip_chapter_numbers:true
add_chapter_numbers:true
chapter_title_add_pattern:Chapter ${index} - ${title}
Full descriptions from defaults.ini:

Spoiler:
Code:
## Don't like the numbers at the start of chapter titles on some
## sites?  You can use strip_chapter_numbers to strip them off.  Just
## want to make them all look the same?  Strip them off, then add them
## back on with add_chapter_numbers:true.  Only want them added back
## on for Table of Contents(toc)? Use add_chapter_numbers:toconly.
## (toconly doesn't work on mobi output.)  Don't like the way it
## strips numbers or adds them back?  See chapter_title_strip_pattern
## and chapter_title_add_pattern.
strip_chapter_numbers:false

## add_chapter_numbers can be true, false or toconly
## (Note number is not added when there's only one chapter.)
add_chapter_numbers:false

## (Two versions of chapter_title_strip_pattern are shown below.  You
## should only have one uncommented.)
## This version will remove the leading number from:
## "1." => ""
## "1. The Beginning" => "The Beginning"
## "1: Start" => "Start"
## "2, Chapter the second" => "Chapter the second"
## etc
chapter_title_strip_pattern:^[0-9]+[\.: -]+

## This version will strip all of the above *plus* remove 'Chapter 1':
## "Chapter 1" => ""
## "1. Chapter 1" => ""
## "1. Chapter 1, Bob's First Clue" => "Bob's First Clue"
## "Chapter 2 - Pirates Place" => "Pirates Place"
## etc
#chapter_title_strip_pattern:^([0-9]+[\.: -]+)?(Chapter *[0-9]+[\.:, -]*)?

## Uses a python template substitution.  The ${index} is the 'chapter'
## number and ${title} is the chapter title, after applying
## chapter_title_strip_pattern.  Those are the only variables available.
## "The Beginning" => "1. The Beginning" 
chapter_title_add_pattern:${index}. ${title}


Hope that helps.
JimmXinu is offline