10-04-2016, 12:36 AM | #1 |
Witchman
Posts: 628
Karma: 788808
Join Date: May 2013
Location: Philippines
Device: Android S5
|
What is the max size allowed for a Sigil plugin ?
I'm hoping someone can answer this.
Some background. I've written a python app(as a Windows exe) that converts a Word filtered HTML file directly to epub. This is a full conversion -- it ports all Word char styles and paragraph styles to the epub's stylesheet. I was hoping to port this python code to a free python plugin. The current app size is about 17 Mb but since I will not be using the mainwindow part(Tk) for the plugin(I envisage using only one metadata dialog and various error popup windows) the plugin should be much smaller in size. Hence the question. By the way, this windows app does a lot more than just convert to epub. I already use this app for quick, clean and bloodless conversions of Word filtered HTML to epub and it works fairly accurately and well. It gives me a great start point for using Sigil. But it sometimes has mixed encoding problems on html import. Still trying to resolve that one. To give you a better idea what this app really does -- please read the App Description in the application help doc below. The plugin itself will have somewhat reduced functionality -- for instance it will not be able to convert html to Kindle mobi. App Help Doc(Word docx) Last edited by slowsmile; 10-04-2016 at 09:50 AM. |
10-04-2016, 02:19 AM | #2 |
Wizard
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
|
There is no limit, but the performance would of course degrade. I wonder why the app is 17 Mb though. My Word add-in is nowhere near that size and also has the functionality to convert a Word document to HTML and export a Word document directly to ePUB (amongst many other functions).
I am currently rewriting the conversion to HTML part, which is around 80% I guess. That can also be used standalone outside of Word. When it is finished it might be fairly easy to create plugin that uses it. It would work on Windows, Linux and OSX then. Also, it is much faster than using Word filtered HTML in between. |
10-04-2016, 02:32 AM | #3 |
Witchman
Posts: 628
Karma: 788808
Join Date: May 2013
Location: Philippines
Device: Android S5
|
@Toxaris...Much thanks for that. The reason the windowing app is so big is because I used Tkinter for all the window components -- but the MainWindow won't be needed for the plugin. I also have a simpler command line version of the same converter app(an earlier version with reduced functionality) and that has an overall py size of only about 1.92Mb.
Last edited by slowsmile; 10-04-2016 at 02:52 AM. |
10-04-2016, 02:52 AM | #4 | ||
Grand Sorcerer
Posts: 5,584
Karma: 22735033
Join Date: Dec 2010
Device: Kindle PW2
|
Quote:
Quote:
BTW, the Sigil plugin runner code has a built-in preferences handler that allows you to automatically read JSON preferences with bk.getPrefs(). |
||
10-04-2016, 03:07 AM | #5 |
Witchman
Posts: 628
Karma: 788808
Join Date: May 2013
Location: Philippines
Device: Android S5
|
@Doitsu....I don't really think that I am re-inventing the wheel. I've had a good look around all the online converters and most of the Sigil plugins. To be honest, I became fed up with converters that only ever seemed to achieve partial conversions to epub or conversions with errors. When my own app converts the Word html to epub -- it's a full conversion. In other words all Word paragraph styles and char styles are directly ported to the epub stylesheet and html text on conversion. Any in-text html styling is also directly ported to named styles in the epub stylesheet. At the heart of my app is the html to epub function which I developed from scratch. And that's really not the only thing this app does -- it does a heck of alot more than just convert to epub -- for instance it also automatically removes all Word html garbage code, fixes simple punctuation spacing errors, creates a doc TOC and Nav TOC(device TOC), creates and adds the Go To guides to the content.opf file, adds global presets to help avoid LITB problems, etc etc. Best read the App Description in my Help Doc link(top post) if you want all the detail.
Last edited by slowsmile; 10-04-2016 at 08:52 AM. |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Plugin] PunctuationSmarten Sigil plugin | DiapDealer | Plugins | 138 | 07-11-2023 11:22 AM |
[Plugin] KindleImport Sigil plugin | DiapDealer | Plugins | 187 | 07-04-2022 10:11 AM |
Max Optimum File Size | Fabe | ePub | 7 | 10-10-2010 03:57 AM |
Max size of SDHC useable? | askyn | PocketBook | 3 | 03-09-2010 01:05 PM |
Max file size? | Parastie | Sony Reader | 10 | 04-17-2009 06:28 PM |