View Single Post
Old 07-18-2011, 05:14 AM   #1
paulfiera
Addict
paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.
 
paulfiera's Avatar
 
Posts: 387
Karma: 3102
Join Date: Dec 2010
Location: EU
Device: Kobo Aura ONE, Kobo Libra H20
Question Regexp help - I think...

I'm working in fixing some epubs and have discovered that on some of them, on every page there is over 50 KB of inline style font definitions like this:

Quote:
@font-face {
font-family: Meiryo;
panose-1: 2 11 6 4 3 5 4 4 2 4;
mso-font-charset: 128;
mso-generic-font-family: swiss;
mso-font-pitch: variable;
mso-font-signature: -536870145 1791492095 18 0 131081 0
}
I'd like to remove everything inside the style tags during a conversion. I don't know if I could use a regexp in Search & Replace for this or even a built-in feature in calibre or any plugin.

So far, I've been exploding the epubs and manualy removing all these font definitions with UltraEdit but it would be really great if I could do it at the time of conversion.

Many thanks
PF
paulfiera is offline   Reply With Quote