07-07-2012, 07:38 PM | #1 |
eBook FANatic
Posts: 18,301
Karma: 16071131
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
css Pretty Printer
Can anyone recommend a utility that will pretty print and validate a Css file?
Something like Tidy for HTML files. Thanks |
07-07-2012, 07:44 PM | #2 |
Resident Curmudgeon
Posts: 73,660
Karma: 127838196
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
|
07-08-2012, 06:12 AM | #3 |
Not who you think I am...
Posts: 374
Karma: 30283
Join Date: Jan 2010
Location: Honolulu
Device: PocketBook 360 -- Ivory
|
|
07-08-2012, 06:18 AM | #4 |
Grand Sorcerer
Posts: 5,582
Karma: 22735033
Join Date: Dec 2010
Device: Kindle PW2
|
Free CSS Toolbox does a good job.
|
07-08-2012, 09:43 AM | #5 |
eBook FANatic
Posts: 18,301
Karma: 16071131
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
Thank you, Gentlemen.
It proved what I suspected about a set of files I downloaded. |
07-08-2012, 09:46 AM | #6 |
Resident Curmudgeon
Posts: 73,660
Karma: 127838196
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
|
07-08-2012, 12:21 PM | #7 | |
Well trained by Cats
Posts: 29,689
Karma: 54369090
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
Using it to perform a number of sequential passes over the CSS. 1) I removed blank lines. 2) I alphabetized 3) I then sorted by type (to put Selectors at the top of the alphabetized list) Nice. It is not integrated with Calibre, so use is a bit cumbersome: 1 Use Tweak EPUB to get at the CSS 2 copy the CSS to the desktop (or a easy accessible temp folder). LEave Tweak Open (minimized OK) 3 open that CSS with Free CSS Toolbox and do your stuff and Save 4 add (replace)the cleaned CSS back into the place you found it. Click Rebuild |
|
07-09-2012, 11:25 AM | #8 |
calibre/Sigil Developer
Posts: 4,601
Karma: 2092290
Join Date: Oct 2010
Location: Australia
Device: Kindle Oasis
|
Does it have a command line option (out of curiosity)?
|
07-09-2012, 11:45 AM | #9 |
Well trained by Cats
Posts: 29,689
Karma: 54369090
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
I experimented.
It will open a CSS file (after making a file association in windows). What it won't do is open an (EPUB) embedded CSS (and repackage it when done) There is a cssformat.dll (windows, obviously ) |
07-10-2012, 04:57 PM | #10 |
Evangelist
Posts: 416
Karma: 1045911
Join Date: Sep 2011
Location: Cape Town, South Africa
Device: Kindle 3
|
I usually use the aforementioned validator.w3.org, then copy the output over to be pretty printed by a little script. The validator removes redundant stuff, and it's not a bad idea to validate anyway. Two birds etc.
|
Thread Tools | Search this Thread |
|
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 pseudo elements and adjacent combinators in extra css? | ldolse | Calibre | 2 | 12-21-2010 05:09 PM |
ePub printer? | el.astrologo | ePub | 5 | 11-25-2010 02:10 PM |
Pretty Printer | crutledge | Sigil | 4 | 09-01-2010 04:42 PM |
About Printer for Librie | mike007dog | Sony Reader | 0 | 12-14-2009 03:29 AM |