Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Sony Reader

Notices

Reply
 
Thread Tools Search this Thread
Old 06-23-2011, 07:49 AM   #1
Japes
Addict
Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.
 
Posts: 303
Karma: 1033852
Join Date: Jun 2011
Device: Sony PRS-350,Sony PRS-950,Pocketbook 360+,B&N Nook Simple Touch Reader
CSS Help Please

Ok, so I have PRS+ installed. Below is an example CSS file for one of the fonts that I installed. The problem is that, regardless of what I set line height to, nothing at all seems to actually change with regards to line height. I've tinkered with making it huge (just to see if it changes anything) and tiny, and nothing changes. Can anyone help?








@font-face {
font-family: "Vollkorn";
font-weight: normal;
font-style: normal;
src: url(res:///Data/fonts/Vollkorn-Regular.ttf);
}

@font-face {
font-family: "Vollkorn";
font-weight: bold;
font-style: normal;
src: url(res:///Data/fonts/Vollkorn-Bold.ttf);
}

@font-face {
font-family: "Vollkorn";
font-weight: normal;
font-style: italic;
src: url(res:///Data/fonts/Vollkorn-Italic.ttf);
}

@font-face {
font-family: "Vollkorn";
font-weight: bold;
font-style: italic;
src: url(res:///Data/fonts/Vollkorn-BoldItalic.ttf);
}

body {
font-family: "Vollkorn"; line-height: 1.9em
}

p {
line-height: 1.9em !important;
text-indent: 1.5em !important;
}

html {
font-family: Vollkorn !important;
}

.mainBody {
font-family: Vollkorn !important;
}

.calibre {
font-family: Vollkorn !important;
}
Japes is offline   Reply With Quote
Old 06-23-2011, 07:59 AM   #2
elemenoP
Wizard
elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.
 
Posts: 1,717
Karma: 3790058
Join Date: Oct 2010
Location: NYC
Device: Kindle Paperwhite, Sony 650
Are you using Calibre? Calibre also has both minimum line height and line height settings, and the CSS does NOT take precedence. So check those settings, on the Look and Feel tab.

eP
elemenoP is offline   Reply With Quote
Advert
Old 06-23-2011, 08:05 AM   #3
Japes
Addict
Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.
 
Posts: 303
Karma: 1033852
Join Date: Jun 2011
Device: Sony PRS-350,Sony PRS-950,Pocketbook 360+,B&N Nook Simple Touch Reader
Yes, I'm using Calibre, and, I presently have all my Epub Conversions to the following:

Base Font Size: 11.5pt
Line Height: 13.0pt


But, the CSS that I'm referencing above is the custom CSS that has to be installed for each font in PRS+. It should (correct me if I'm wrong), take precedence. For example, in Calibre, my "Extra CSS" references LexiaDaMa, but, I'm able to switch between fonts with each font's CSS.

Please advise.
Japes is offline   Reply With Quote
Old 06-23-2011, 08:27 AM   #4
viviena
Evangelist
viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.
 
Posts: 412
Karma: 520610
Join Date: May 2010
Location: Canberra, Australia
Device: Currently Kobo Clara HD and Aura One, iPad
I don't know what might help. I currently designate line-height like this without any problems:

Code:
html { 
	font-family: "Vollkorn" !important;
}

body { 
	font-family: "Vollkorn" !important;
	line-height: 1.05em;
}

.mainBody {
	font-family: "Vollkorn" !important;
}

.calibre {
	font-family: "Vollkorn" !important;
}

p {
	font-family: "Vollkorn" !important;
}

@font-face {
  font-family: "Vollkorn";
  font-weight: normal;
  font-style: normal;
  src: url(res:///Data/fonts/vollkorn/Vollkorn-Regular.ttf);
}

@font-face {
  font-family: "Vollkorn";
  font-weight: bold;
  font-style: normal;
  src: url(res:///Data/fonts/vollkorn/Vollkorn-Bold.ttf);
}

@font-face {
  font-family: "Vollkorn";
  font-weight: normal;
  font-style: italic;
  src: url(res:///Data/fonts/vollkorn/Vollkorn-Italic.ttf);
}

@font-face {
  font-family: "Vollkorn";
  font-weight: bold;
  font-style: italic;
  src: url(res:///Data/fonts/vollkorn/Vollkorn-BoldItalic.ttf);
}
(To make sure I wasn't imagining the extra line-height, I even took another screenshot after my line-height adjustment and measured the difference with a ruler. I'm good at fooling myself otherwise.)

The only difference I can see is that you have no semi-colon after the second CSS property, but that shouldn't usually matter, I think? It doesn't for most web design, not when it's the final property in a ruleset.

Last edited by viviena; 06-23-2011 at 09:12 AM. Reason: Awesome, just discovered an error in my CSS. I haven't had any bold italicised text yet, which is probably how it eluded me.
viviena is offline   Reply With Quote
Old 06-23-2011, 08:44 AM   #5
Japes
Addict
Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.
 
Posts: 303
Karma: 1033852
Join Date: Jun 2011
Device: Sony PRS-350,Sony PRS-950,Pocketbook 360+,B&N Nook Simple Touch Reader
I tried it with and without the semicolon and it didn't make a difference. I will try YOUR code later on when I get home. Is it possible that the CSS is unable to overide what Calibre is setting for line heights and the like?
Japes is offline   Reply With Quote
Advert
Old 06-23-2011, 08:45 AM   #6
elemenoP
Wizard
elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.
 
Posts: 1,717
Karma: 3790058
Join Date: Oct 2010
Location: NYC
Device: Kindle Paperwhite, Sony 650
You'd think the custom CSS would take precedence, but it does not. (this is a big beef I have with Calibre.) Try fiddling with those settings in Calibre, both line height and minimum line height.

eP
elemenoP is offline   Reply With Quote
Old 06-23-2011, 08:46 AM   #7
elemenoP
Wizard
elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.
 
Posts: 1,717
Karma: 3790058
Join Date: Oct 2010
Location: NYC
Device: Kindle Paperwhite, Sony 650
Viviena, do you use Calibre? What are your settings in the "Look and Feel" tab in Calibre?

eP
elemenoP is offline   Reply With Quote
Old 06-23-2011, 08:46 AM   #8
Japes
Addict
Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.
 
Posts: 303
Karma: 1033852
Join Date: Jun 2011
Device: Sony PRS-350,Sony PRS-950,Pocketbook 360+,B&N Nook Simple Touch Reader
Oh, God, wow. If that is the case, then I would have to re-convert every single book in my library WITHOUT putting in any values for those fields?
Japes is offline   Reply With Quote
Old 06-23-2011, 08:49 AM   #9
elemenoP
Wizard
elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.
 
Posts: 1,717
Karma: 3790058
Join Date: Oct 2010
Location: NYC
Device: Kindle Paperwhite, Sony 650
Oh it's even worse than that. There is no way to put a "none" or "inherit" value in those fields in Calibre. You must set it to *something.* But I'm wondering if someone else has found a better way to deal with this problem. It's weird.

eP
elemenoP is offline   Reply With Quote
Old 06-23-2011, 08:51 AM   #10
Japes
Addict
Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.
 
Posts: 303
Karma: 1033852
Join Date: Jun 2011
Device: Sony PRS-350,Sony PRS-950,Pocketbook 360+,B&N Nook Simple Touch Reader
Quote:
Originally Posted by elemenoP View Post
Oh it's even worse than that. There is no way to put a "none" or "inherit" value in those fields in Calibre. You must set it to *something.* But I'm wondering if someone else has found a better way to deal with this problem. It's weird.

eP

If that's the case, then that can't be the problem. Otherwise, nobody who uses Calibre to convert to Epub, would get any results, and some people are (Ripplinger, Vivienna, et al).
Japes is offline   Reply With Quote
Old 06-23-2011, 08:55 AM   #11
elemenoP
Wizard
elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.
 
Posts: 1,717
Karma: 3790058
Join Date: Oct 2010
Location: NYC
Device: Kindle Paperwhite, Sony 650
Yes, it's a mystery to me. First I would try making changes to those settings, just to see if that has an effect and is, in fact, the problem. Then maybe ask in the Calibre forum what you can do about it. Please report back. Maybe I'm all wrong, I did my tinkering a while ago and haven't touched it since, but that was the problem that I found. It could be that there is *some* kind of setting you can use in Calibre and I just don't know what it is.

eP
elemenoP is offline   Reply With Quote
Old 06-23-2011, 08:57 AM   #12
elemenoP
Wizard
elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.
 
Posts: 1,717
Karma: 3790058
Join Date: Oct 2010
Location: NYC
Device: Kindle Paperwhite, Sony 650
But I did ask in the Calibre forum once if it was possible to change to allowing CSS to take precedence over Calibre settings, and Kovid said no, because it would break people's existing settings.
elemenoP is offline   Reply With Quote
Old 06-23-2011, 08:58 AM   #13
Japes
Addict
Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.Japes ought to be getting tired of karma fortunes by now.
 
Posts: 303
Karma: 1033852
Join Date: Jun 2011
Device: Sony PRS-350,Sony PRS-950,Pocketbook 360+,B&N Nook Simple Touch Reader
There has to be a way. I just don't know it. For example, by putting the "important" in you are able to override even embedded fonts (thanks to Ripplinger for that tip). So, I can't imagine, that if you can override embedded fonts, you wouldn't be able to override a simple line height setting. I just don't know anything about programming, so, I don't know it. But someone out there, I'm sure, does.
Japes is offline   Reply With Quote
Old 06-23-2011, 09:00 AM   #14
viviena
Evangelist
viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.viviena ought to be getting tired of karma fortunes by now.
 
Posts: 412
Karma: 520610
Join Date: May 2010
Location: Canberra, Australia
Device: Currently Kobo Clara HD and Aura One, iPad
I use Calibre regularly for file conversions, but I have nothing in the Extra CSS field. I usually have the text justified and I sometimes remove spacing between paragraphs (thus adding indents). Minimum line height is 120% and line height 0.0pt and I've never altered them from the default. The image which I have demoing Vollkorn is from a book converted to EPUB from LIT and in the EPUB's stylesheet is a line-height of 1.2.

Yet when I adjusted the Vollkorn stylesheet for PRS, the line-height did increase visibly for me. I'm not sure what's going on, but hey, as long as it increased, I'm happy.

Last edited by viviena; 06-23-2011 at 09:02 AM.
viviena is offline   Reply With Quote
Old 06-23-2011, 09:00 AM   #15
elemenoP
Wizard
elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.elemenoP ought to be getting tired of karma fortunes by now.
 
Posts: 1,717
Karma: 3790058
Join Date: Oct 2010
Location: NYC
Device: Kindle Paperwhite, Sony 650
Japes, did you try making changes in Calibre, to see if you can affect the line-height at least?
elemenoP is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Override ePub CSS with userStyle.css? barium Sony Reader Dev Corner 11 07-16-2011 03:25 PM
CSS help? graycyn ePub 2 06-16-2011 04:56 AM
epub CSS versus "Regular" CSS konrad ePub 4 02-18-2011 09:29 AM
css pseudo elements and adjacent combinators in extra css? ldolse Calibre 2 12-21-2010 05:09 PM
Help with CSS, anyone? rogue_ronin Workshop 36 08-14-2009 09:28 PM


All times are GMT -4. The time now is 11:37 PM.


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