Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 06-05-2012, 12:09 PM   #1
MSWallack
Right, Except When Wrong
MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.
 
MSWallack's Avatar
 
Posts: 353
Karma: 3968525
Join Date: Aug 2007
Location: Indianapolis
Device: Kindle Oasis 3 (sometimes iPad Mini).
Fix "small caps" problem

So I have an ebook that has been formatted (not by me) so that each new chapter or section begins with a slightly oversized letter followed by several words, in all caps, but in a tiny font before the text returns to standard upper and lower case and a regular font size. It appears that the formatting is trying to emulate small caps but doing so really poorly. When I get to each new chapter I have to either squint or zoom just to read the first few words. It's getting a wee bit annoying. Is there a quick way in Sigil to fix this? Note that I really don't understand CSS yet...
MSWallack is offline   Reply With Quote
Old 06-05-2012, 12:12 PM   #2
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 71,506
Karma: 306214458
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
Quote:
Originally Posted by MSWallack View Post
So I have an ebook that has been formatted (not by me) so that each new chapter or section begins with a slightly oversized letter followed by several words, in all caps, but in a tiny font before the text returns to standard upper and lower case and a regular font size. It appears that the formatting is trying to emulate small caps but doing so really poorly. When I get to each new chapter I have to either squint or zoom just to read the first few words. It's getting a wee bit annoying. Is there a quick way in Sigil to fix this? Note that I really don't understand CSS yet...
It depends on how the formatting has been done. It might be as simple as a change to the CSS controlling the 'smallcaps' text. Or you might need to edit each chapter start individually. It's impossible to say which case applies to your particular ebook.
pdurrant is offline   Reply With Quote
Old 06-05-2012, 12:14 PM   #3
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 73,968
Karma: 128903250
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
In most cases, smallcaps are just a simple style in the CSS. If that's the case, check how it's done. It should be a font size of either 75% or .75 em to be correct for the default font size of 1em.
JSWolf is offline   Reply With Quote
Old 06-05-2012, 01:13 PM   #4
MSWallack
Right, Except When Wrong
MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.
 
MSWallack's Avatar
 
Posts: 353
Karma: 3968525
Join Date: Aug 2007
Location: Indianapolis
Device: Kindle Oasis 3 (sometimes iPad Mini).
I opened the ebook in Sigil. Here is what the beginning of a chapter looks like (I've changed the text of the book itself...):

<body class="calibre">
<p class="calibre7" id="filepos13245"><span class="calibre11 bold">CHAPTER 1</span></p>

<p class="calibre9 sgc-1">&nbsp;</p>

<p class="calibre10"><span class="calibre12 bold">CHICAGO, ILLINOIS</span></p>

<p class="calibre9 sgc-1">&nbsp;</p>

<p class="calibre10"><span class="italic">I</span> <span class="calibre12 italic">SHOULDN’T HAVE</span> <span class="italic">come,</span> Bob Smith thought as he looked at the people around him. <span class="italic">I should have gone far away.</span></p>

<p class="calibre15">But he had answered the phone call.</p>
MSWallack is offline   Reply With Quote
Old 06-05-2012, 01:21 PM   #5
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 71,506
Karma: 306214458
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
It looks like you just need to change the CSS for style calibre12.

But that will only fix the font size, of course. Since the ALL CAPS is hard coded, there's no way to change that (without errors) without changing the text itself.
pdurrant is offline   Reply With Quote
Old 06-06-2012, 12:24 AM   #6
rkomar
Wizard
rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.rkomar ought to be getting tired of karma fortunes by now.
 
Posts: 2,986
Karma: 18343081
Join Date: Oct 2010
Location: Sudbury, ON, Canada
Device: PRS-505, PB 902, PRS-T1, PB 623, PB 840, PB 633
I created some EPUBs with small caps a while ago using sigil, and the code there looked like:

Code:
<small>I SEEM TO BE</small>
So, it looks like the same font is used for small caps and the standard text. It just has the <small> tags around the small caps. There are no issues with the font being tiny that way. I don't see how to automatically change your EPUB to follow that style, though.

Last edited by rkomar; 06-06-2012 at 12:28 AM.
rkomar is offline   Reply With Quote
Old 06-06-2012, 03:56 AM   #7
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,584
Karma: 22735033
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by pdurrant View Post
But that will only fix the font size, of course. Since the ALL CAPS is hard coded, there's no way to change that (without errors) without changing the text itself.
Since the current Sigil version supports PCRE, it'd would be possible to use a \L backreference to change the all caps text to lower-case characters.
For example, the following regular search and replace expressions would change all caps text to lower case text:

Search: <span class="calibre12 italic">(.*?)</span>
Replace: <span class="italic">\L\1</span>
Doitsu is offline   Reply With Quote
Old 06-06-2012, 04:05 AM   #8
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: 7,516
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
That cannot know when a letter must be uppercase anyway, as in a proper name.
Jellby is offline   Reply With Quote
Old 06-06-2012, 04:46 AM   #9
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 71,506
Karma: 306214458
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
Quote:
Originally Posted by Jellby View Post
That cannot know when a letter must be uppercase anyway, as in a proper name.
Exactly so. When the information isn't there, there's no automated way to fix it.
pdurrant is offline   Reply With Quote
Old 06-06-2012, 10:24 AM   #10
st_albert
Guru
st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'st_albert gives new meaning to the word 'superlative.'
 
Posts: 696
Karma: 150000
Join Date: Feb 2010
Device: none
FWIW, I will add that my experience has been that this method of simulating small caps (i.e. font size 75%, or whatever, used with all caps in the text) does not work reliably in all epub readers (nor, IIRC, in kindle 3 and below).

One could (should?) embed an actual small-caps font, but some e-readers don't handle embedded fonts well either.
st_albert is offline   Reply With Quote
Old 06-06-2012, 10:45 AM   #11
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 71,506
Karma: 306214458
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
Well, actually small-caps should be done by specifying font-variant:small-caps in the CSS for the text you want in small-caps. Unfortunately, ADE doesn't support this part of the OPS 2.0.1 specification yet, and ADE is what most readers use when rendering ePubs.
pdurrant is offline   Reply With Quote
Old 06-06-2012, 10:59 AM   #12
MSWallack
Right, Except When Wrong
MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.MSWallack ought to be getting tired of karma fortunes by now.
 
MSWallack's Avatar
 
Posts: 353
Karma: 3968525
Join Date: Aug 2007
Location: Indianapolis
Device: Kindle Oasis 3 (sometimes iPad Mini).
I just changed the CSS definition (it was .43em or such) to 1.0em and everything looks fine now. I'd obviously prefer "real" small caps than just all caps, but at least the text is readable without zooming or squinting (I guess I'm getting old...). Thanks for the help.
MSWallack is offline   Reply With Quote
Old 06-06-2012, 11:06 AM   #13
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 73,968
Karma: 128903250
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by MSWallack View Post
I opened the ebook in Sigil. Here is what the beginning of a chapter looks like (I've changed the text of the book itself...):

<body class="calibre">
<p class="calibre7" id="filepos13245"><span class="calibre11 bold">CHAPTER 1</span></p>

<p class="calibre9 sgc-1">&nbsp;</p>

<p class="calibre10"><span class="calibre12 bold">CHICAGO, ILLINOIS</span></p>

<p class="calibre9 sgc-1">&nbsp;</p>

<p class="calibre10"><span class="italic">I</span> <span class="calibre12 italic">SHOULDN’T HAVE</span> <span class="italic">come,</span> Bob Smith thought as he looked at the people around him. <span class="italic">I should have gone far away.</span></p>

<p class="calibre15">But he had answered the phone call.</p>
Code:
.calibre12 {
  font-size: 75%
}
There, fixed.
JSWolf is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem "installing" "Kindle library extractor" dhdurgee Kindle Developer's Corner 7 11-24-2012 07:09 PM
small caps problem in Sigil goroke Sigil 16 08-05-2011 12:14 PM
RTF "small caps" conversion? sehlat Calibre 3 06-23-2011 07:24 PM
"A Problem Occurred" on the "Shop" page. swallman Nook Color & Nook Tablet 1 12-25-2010 12:34 PM
Is there a "fix" or work-around for Kindle doubleing size of small graphics? bfollowell Amazon Kindle 15 11-14-2010 07:27 PM


All times are GMT -4. The time now is 04:15 PM.


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