|
|
#166 |
|
eBook FANatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,852
Karma: 13081948
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
Delete Unused Stylesheet Styles
If possible, it would be nice if this could be turned on/off in Preferences. I would leave it ON.
__________________
Charlie 'Bene legere saecla vincere'. 'To read well is to master the ages' [Prof. Issac Flagg] |
|
|
|
|
#167 |
|
Sigil developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,261
Karma: 1101600
Join Date: Jan 2011
Location: UK
Device: Kindle PW, K4 NT, K3, Kobo Touch
|
Its not a checkbox/option - its a function/action that gets run, like Validate. The same with Delete Unused Images. So you get to choose to use it or not
__________________
See the Sigil User Guide and its tutorials for details about Sigil. |
|
|
|
Enthusiast
|
|
|
|
#168 |
|
Det
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 716
Karma: 450180
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
|
Regex
Regex seams not to work properly. It seams that the "Dotall" option is always turned on (I'm sure that it is not checked")
|
|
|
|
|
#169 |
|
Techno-geek
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 149
Karma: 1000613
Join Date: Nov 2006
Location: Mississippi, USA
Device: PRS-T1 (Black)
|
Could someone explain the dotall option? Does it have to do with greedy matching? Or what?
--MH |
|
|
|
|
#170 |
|
calibre/Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,087
Karma: 1211084
Join Date: Oct 2010
Location: London, UK
Device: Kindle 3 3G, iPad 2, iPad 3
|
@mmat1 - oops - that would be because the settings are the wrong way around in the code. Will be fixed for the next build. I always leave both turned on so never noticed. Thanks for reporting this.
__________________
Like my calibre plugins or Sigil work? Say thanks with PayPal |
|
|
|
|
#171 | |
|
calibre/Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,087
Karma: 1211084
Join Date: Oct 2010
Location: London, UK
Device: Kindle 3 3G, iPad 2, iPad 3
|
Quote:
Basically it comes down to if in an expression you do .* it matches just a single line or not. Say you want to get rid of whole script blocks, you can do <script>.*</script> with DotAll turned on, but that won't work with it turned off because the closing </script> is on a different line in the file.
__________________
Like my calibre plugins or Sigil work? Say thanks with PayPal |
|
|
|
|
|
#172 |
|
eBook FANatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,852
Karma: 13081948
Join Date: Apr 2008
Location: Alabama, USA
Device: HP ipac RX5915 Wife's Kindle
|
What I would expect from a Preferences Option.
__________________
Charlie 'Bene legere saecla vincere'. 'To read well is to master the ages' [Prof. Issac Flagg] |
|
|
|
|
#173 |
|
calibre/Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,087
Karma: 1211084
Join Date: Oct 2010
Location: London, UK
Device: Kindle 3 3G, iPad 2, iPad 3
|
@crutledge - it can only run at a point in time - just like validating with FlightCrew for instance. It is the same sort of feature. Otherwise you wouldn't be able to declare a new style and then switch to an html file to use it, it would be gone already
. The only way at which you would know it was "safe" to be run is when the user says so - which is exactly what you have now by triggering it from the tools menu.
__________________
Like my calibre plugins or Sigil work? Say thanks with PayPal |
|
|
|
|
#174 |
|
Sigil developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,261
Karma: 1101600
Join Date: Jan 2011
Location: UK
Device: Kindle PW, K4 NT, K3, Kobo Touch
|
I don't think I quite understand how this would work, or help.
Delete Unused Stylesheet Classes (renamed for the next beta to be clear its only classes - although technically they are selectors) checks your HTML and stylesheets then deletes the stylesheet entries that weren't matched by a class used in the HTML. Delete Unused Image Files does something similar - removes any image file that was not included in your HTML with an img tag. These are actions you run on demand. If they were on or off in a preferences setting, then as soon as you added an image or typed a class it would be deleted before you could use it.
__________________
See the Sigil User Guide and its tutorials for details about Sigil. |
|
|
|
|
#175 |
|
Staff to 4 Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,699
Karma: 2485850
Join Date: Aug 2009
Location: The (original) Silicon Valley, USA
Device: Galaxy Tab 2,Black Astak PEz, K4NT(now Wifes)
|
These are not Toggled options.
They are click to run. No clickey, no runney which is a good thing. I might have a default stylesheet, that I have not finished editing the book sections, some of which may use some of those styles (later) Sigil crew: GREAT feature
__________________
Using: Ubuntu(32 bit):Oneric,Precise and XPpro SP3, W7HP(64)- - Libre Office w/Writer2EPUB
|
|
|
|
|
#176 |
|
Jr. - Junior Member
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 532
Karma: 2000170
Join Date: Aug 2010
Location: East Texas
Device: DXG, K3, Jetbook(+Lite), eSlick, Nook, PRS350, PB301+, PB360
|
|
|
|
|
|
#177 |
|
Det
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 716
Karma: 450180
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
|
Reformat CSS
Reformat (to single line per style) eats my characters
![]() span.fakesmallcaps {font-size: .75em} becomes: span.fakesmallcaps { font-size: .75e; } This happens probably only with lines which are already a single line style definition plus it does not happen always. In my example I had 4 single line definitions at the end of the file (showing one of them above) and the very last 3 were faulty afterwards. |
|
|
|
|
#178 |
|
calibre/Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,087
Karma: 1211084
Join Date: Oct 2010
Location: London, UK
Device: Kindle 3 3G, iPad 2, iPad 3
|
@mmat1 - thanks, that is an interesting one, it does seem the wind needs to blow in a particular direction for it to fail. It will get sorted for the next build.
__________________
Like my calibre plugins or Sigil work? Say thanks with PayPal |
|
|
|
|
#179 | |
|
Det
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 716
Karma: 450180
Join Date: Jan 2012
Location: Zischebattem
Device: Acer Lumiread
|
Quote:
|
|
|
|
|
|
#180 |
|
calibre/Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,087
Karma: 1211084
Join Date: Oct 2010
Location: London, UK
Device: Kindle 3 3G, iPad 2, iPad 3
|
@mmat1 - thanks but I figured out the cause and the fix. It was a simple "one-off" error after the code was changed to handle three different purposes. Did the two new ones well, the original purpose not so much any more...
__________________
Like my calibre plugins or Sigil work? Say thanks with PayPal |
|
|
![]() |
| Thread Tools | Search this Thread |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| New Beta for BB? | FF2 | Amazon Kindle | 2 | 05-28-2011 10:21 AM |
| Ίχνη Φαντασμάτων Μία υπόθεση του Μαξ Κίλλιαν - 99 cents! | BearMountainBooks | Author Self-Promotions | 5 | 08-24-2010 07:00 PM |
| Beta Beta Test of Major New Features | Starson17 | Calibre | 45 | 05-17-2010 10:55 AM |
| 0.6 out of beta? | Nate the great | Calibre | 3 | 07-17-2009 02:45 AM |