Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 01-19-2010, 06:03 AM   #1
paulpeer
Zealot
paulpeer is on a distinguished road
 
paulpeer's Avatar
 
Posts: 147
Karma: 56
Join Date: Dec 2009
Location: Antwerpen
Device: iPhone, Sony PRS-505, EPUBreader
Superscript in titles

I'm working on a book with many superscripts in the titles. If I create the code as follows

<h3>TITLE<sup><a href="#sdfootnote24sym" id="sdfootnote24anc">24</a></sup></h3>

the book view looks perfecly but the TOC shows: TITLE24

If I change the code to

<h3>TITLE</h3> <sup><a href="#sdfootnote24sym" id="sdfootnote24anc">24</a></sup>

the TOC is perfect, but the book view looks stupid (superscript on next line).

Does anyone has a suggestion?

Thanks!
paulpeer is offline   Reply With Quote
Old 01-19-2010, 07:15 AM   #2
Valloric
Created Sigil, FlightCrew
Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.
 
Valloric's Avatar
 
Posts: 1,978
Karma: 350515
Join Date: Feb 2008
Device: Sony Reader PRS 505
I don't think you'll ever be able to get text display as superscript in the TOC. Not because of Sigil, but because I doubt you can express a superscript in the NCX file. The NCX doctype is, well, "ncx". It's not HTML. I doubt there's a "<sup>" tag (I could be wrong).

What I would do is this:
Code:
<h3 title="TITLE^24">TITLE<sup><a href="#sdfootnote24sym" id="sdfootnote24anc">24</a></sup></h3>
That is, display the superscript correctly in the book, but use the common "^" notation for the TOC. The "title" attribute overrides the content of the element for the TOC generation.
Valloric is offline   Reply With Quote
 
Enthusiast
Old 01-19-2010, 10:17 AM   #3
paulpeer
Zealot
paulpeer is on a distinguished road
 
paulpeer's Avatar
 
Posts: 147
Karma: 56
Join Date: Dec 2009
Location: Antwerpen
Device: iPhone, Sony PRS-505, EPUBreader
Quote:
Originally Posted by Valloric View Post
The "title" attribute overrides the content of the element for the TOC generation.
Yeees! That's the trick I was looking for. Thanks very much, Valloric!
paulpeer is offline   Reply With Quote
Old 01-19-2010, 04:48 PM   #4
rogue_ronin
Banned
rogue_ronin has learned how to read e-booksrogue_ronin has learned how to read e-booksrogue_ronin has learned how to read e-booksrogue_ronin has learned how to read e-booksrogue_ronin has learned how to read e-booksrogue_ronin has learned how to read e-booksrogue_ronin has learned how to read e-books
 
Posts: 475
Karma: 796
Join Date: Sep 2008
Location: Honolulu
Device: Nokia 770 (fbreader)
If the NCX allows unicode, then you could fake it by using superscript characters directly:

Code:
Title²⁴
m a r
rogue_ronin is offline   Reply With Quote
Old 01-19-2010, 04:54 PM   #5
Valloric
Created Sigil, FlightCrew
Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.Valloric ought to be getting tired of karma fortunes by now.
 
Valloric's Avatar
 
Posts: 1,978
Karma: 350515
Join Date: Feb 2008
Device: Sony Reader PRS 505
Quote:
Originally Posted by rogue_ronin View Post
If the NCX allows unicode, then you could fake it by using superscript characters directly.
Damn good idea. An NCX is still an XML file, and thus uses Unicode. And since Sigil is fully Unicode aware and exports everything as UTF-8, you can use this:
Code:
<h3 title="Title²⁴">
But there's a good chance a Reading System will screw up the rendering. Try it in ADE first.
Valloric is offline   Reply With Quote
Old 01-20-2010, 08:37 AM   #6
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 6,195
Karma: 4800739
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
But if the "24" is just a note call, I don't think anyone would want it showing in the TOC.

And using Unicode is not always a solution. It does not work if you have "M<sup>lle</sup>" or "3.<sup>er</sup>" in your titles (although in these cases, rendering the superscripts as normal text is an acceptable solution).
Jellby is offline   Reply With Quote
Reply

Tags
superscript, title

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Superscript and Subscript ramjet1953 Sigil 1 06-13-2010 07:15 AM
PRS-600 Titles trout Sony Reader 3 04-11-2010 04:40 PM
Managing Titles yihyng Sony Reader 3 09-16-2009 07:23 PM
So many titles available in the US only... bentley Sony Reader 13 03-22-2009 02:54 PM
Figuring Out Titles mlove Sony Reader 4 11-24-2007 08:33 PM


All times are GMT -4. The time now is 08:44 PM.


MobileRead.com is a privately owned, operated and funded community.