12-20-2010, 05:53 AM | #1 |
Zealot
Posts: 124
Karma: 10
Join Date: Dec 2008
Location: France
Device: None
|
Feature request : using a custom css file
Hi
First, big thanks to eBookLuke. I use your 2 extensions a lot, My TXT Cleaner and W2E. I know that your goal with the latter is to provide perfect and easy-to-do epub files. But here's a request : In the Options dialog box, an option to use our own stylesheet. For example : If the option is checked, a Browse button that will allow to choose a css file and your extension will copy it in the style folder of the epub file, instead of the current default stylesheet. If not checked, use the default stylesheet as usual. It seems simple when said like that :-) Dont' know how hard it would be to implement. I don't know anything about programming in openOffice. Thanks for reading. |
12-20-2010, 06:41 AM | #2 | |
Writer2ePub creator
Posts: 354
Karma: 121129
Join Date: Sep 2009
Location: Genova, Italy
Device: Cybook Bebook iLiad Kindle HanlinV2 Readius SonyPRS500 SonyPRS700 etc
|
No, it is quite simple, but there is just a problem to solve.
The proposed CSS in the current version is "dinamic". This means that some values in the CSS can change depending of the user choice ( font dimension and font face) I can easily allow to choose an alternative CSS but this will be "static" and you cannot anymore change that parameters by preference window. To enable parameter change even in external CSS I have to rewrite a lot of code. Let me know if the first option is enought for you. Quote:
Luke Last edited by eBookLuke; 12-20-2010 at 09:57 AM. |
|
12-20-2010, 06:48 AM | #3 |
Writer2ePub creator
Posts: 354
Karma: 121129
Join Date: Sep 2009
Location: Genova, Italy
Device: Cybook Bebook iLiad Kindle HanlinV2 Readius SonyPRS500 SonyPRS700 etc
|
I like your idea… Can you post your favorite CSS in this thread? I try to experiment with it…
The W2E CSS is just one of some "good Tyoographer" choice. Other country can have different rules to well formatting a book… We can provide a set of good CSS, and leaving to the user to create his own… Luke |
12-20-2010, 12:57 PM | #4 |
Zealot
Posts: 124
Karma: 10
Join Date: Dec 2008
Location: France
Device: None
|
Ok, here's my css code.
This is the file that I use to replace the default stylesheet. In this file I kept all your classes. I change the selectors h1 to h6, p. I add two custom classes. (Sometimes I add more classes, it depends on the content of the book, but those are the main styles) I have to say that in openOffice, before creating the epub, I reset all predefined styles, load my own styles and apply them. After that, my css file works nicely in my reader. |
12-20-2010, 02:00 PM | #5 | |
Writer2ePub creator
Posts: 354
Karma: 121129
Join Date: Sep 2009
Location: Genova, Italy
Device: Cybook Bebook iLiad Kindle HanlinV2 Readius SonyPRS500 SonyPRS700 etc
|
Quote:
If you change: Code:
font: 1em Georgia, "Times New Roman", Times, serif; Code:
font: 1em Georgia, "Times New Roman", Times, serif, sansserif, monospace; By remove sansserif and monospace the user cannot set the font to "Arial" or "Courier" Luke |
|
12-21-2010, 04:46 AM | #6 |
Wizard
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
|
Epub validation test
I tried to check our last produced epub with Valloric's new FlightCrew 0.7.1. epub validator. You'll find the result below. Of course, I guessed it beforehand PS/ of course "Gabriel" would have been better, but this is MY mistake. Next time, I'll open a new thread. Sorry for this. Last edited by roger64; 12-21-2010 at 04:49 AM. |
12-21-2010, 06:09 AM | #7 |
Writer2ePub creator
Posts: 354
Karma: 121129
Join Date: Sep 2009
Location: Genova, Italy
Device: Cybook Bebook iLiad Kindle HanlinV2 Readius SonyPRS500 SonyPRS700 etc
|
|
12-22-2010, 03:55 AM | #8 |
Wizard
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
|
My purpose was to check something I was sure of, which was working on my Sony to see if I could trust this validation tool and not he other way around.
My previous trials at W3C for validation software had been a little disappointing because they brought me back lots of clueless details that I could'nt exploit. So, FlightCrew seems to be an exploitable no-nonsense tool and of course, do not misunderstand me, W2E is a very good epub software producer. |
12-28-2019, 12:46 PM | #9 |
Connoisseur
Posts: 79
Karma: 228
Join Date: Aug 2014
Device: lambda k21
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Custom CSS for output | deckoff | Calibre | 1 | 08-29-2010 12:55 AM |
Feature request: CSS style application | Fitz | Sigil | 4 | 07-25-2010 07:36 AM |
Feature Request - Edit File Option | fcoulter | Calibre | 10 | 07-22-2010 01:56 AM |
Feature request: make two or more files into one big file | spikebrennan | Calibre | 4 | 07-19-2010 10:24 PM |
Feature request: Select what file format to save RSS into | haridasi | Calibre | 2 | 08-23-2008 11:03 AM |