Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil > Plugins

Notices

Reply
 
Thread Tools Search this Thread
Old 04-20-2024, 09:40 AM   #526
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 7,898
Karma: 5449552
Join Date: Nov 2009
Device: many
Ignoring the AI aspect of all of this.

Although a plugin like this is doable, there really is not a lot of need for one.

Let me explain.

Normally, authors of books write and do primary editing of their books in a Word Processor like LibreOffice or Word remembering to properly specify and use styles.

Then the epub dev person can either export that word document as html to load it into Sigil or use one of the existing Sigil import plugins to load it. There is very little need to create lots of html by hand. Next Sigil has the ability to use user supplied text Clips. Many users assign a few of the most common html tags to the clip so they can insert them with a single click on any of the 40 clip icons Sigil supports.

Sigil already starts every page with the proper xhtml framework that is equivalent to what your example haml code would produce but for Sigil, since epubs need proper xhtml, Sigil uses that not the more loosely formatted xhtml.

So rarely do epub developers need to hand create large blocks of html/xhtml code. They in fact spend a large part of their time cleaning up the poor html most other programs create, adding the proper css styling, reformatting footnotes, adding images, cover, etc and even javascript if needed.

Now if you know of a good html editor that produces haml, then by all means you could create and use a plugin to read it in and convert it to xhtml.

Alternatively you could run a standalone program to convert haml to html and then import that to Sigil right now.

Hope this explains things better.
KevinH is offline   Reply With Quote
Old Today, 06:19 AM   #527
PubFut
Junior Member
PubFut began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2024
Device: Sigil
Developer for little Sigil Plugin

Hello, I am looking for a developer who can build a little Sigil plugin that adds "Back" and "Forward" buttons at the end of every page to navigate through a book in an HTML export from an EPUB. Is there anyone interested in doing this as a work for hire?
If this is not the right place for this request, I am sorry and grateful for any advice where to post it.
Best regards, Bertram
PubFut is offline   Reply With Quote
Old Today, 08:55 AM   #528
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,736
Karma: 197700000
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
This is the right place. I'm just not sure it's doable (or that I understand correctly). Unless it's a fixed layout (pretty rare), epubs don't have "pages." They reflow based on font size and margin/line-height preferences. So there would be no programmatically definable "end of every page." And an HTML export would be in the same boat. An HTML book would endlessly scroll--with no need for page buttons. Unless you're talking chapters or sections?
DiapDealer is offline   Reply With Quote
Old Today, 12:51 PM   #529
PubFut
Junior Member
PubFut began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2024
Device: Sigil
Thank you for your fast reply

If it is possible to retrieve the file name of the previous and following xhtml file within the file list of the EPUB than it shoud be doable. In this case in the following html snippet only in the "href="XXX.xhtml" the "XXX.xhtml" needs to be replaced once by the file name of the previous file and once by the file name of the following file. Inserting this code snippet in every file before the </body> tag should do the job. Shouldn't it?

Code:
<div class="wh_prev_next"><a class="wh_prev_next_link" href="XXX.xhtml"><span class="icon-arrow-left"> </span><span style="vertical-align:top; font-size:large;">Previous</span></a><a class="wh_prev_next_link" href="XXX.xhtml"><span style="vertical-align:top; font-size:large; padding-right: 1em;">Next</span><span class="icon-arrow-right"> </span></a></div>
PubFut is offline   Reply With Quote
Old Today, 01:45 PM   #530
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,736
Karma: 197700000
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by PubFut View Post
If it is possible to retrieve the file name of the previous and following xhtml file within the file list of the EPUB than it shoud be doable. In this case in the following html snippet only in the "href="XXX.xhtml" the "XXX.xhtml" needs to be replaced once by the file name of the previous file and once by the file name of the following file. Inserting this code snippet in every file before the </body> tag should do the job. Shouldn't it?
Sure. That should be possible for someone. But you're talking about adding code to the end of every file/chapter, where you said pages. That's what I was looking to clarify.
DiapDealer is offline   Reply With Quote
Old Today, 02:05 PM   #531
PubFut
Junior Member
PubFut began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2024
Device: Sigil
Essentially, what I am looking for is a function that replaces some string like "Previous.xhtml" by the file name of the previous file in the file list and "Next.xhtml" by the file name of the following file. Everything else is still in place. Just this part is missing.
PubFut is offline   Reply With Quote
Old Today, 02:07 PM   #532
PubFut
Junior Member
PubFut began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2024
Device: Sigil
Quote:
Originally Posted by DiapDealer View Post
you're talking about adding code to the end of every file/chapter, where you said pages. That's what I was looking to clarify.
Correct, "page" referred to the HTML output that I produce where every EPUB file/chapter results in an html page.
PubFut is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Loading Plugin in development Sladd Development 6 06-17-2014 06:57 PM
Question for plugin development gurus DiapDealer Plugins 2 02-04-2012 11:33 PM
DR800 Plugin development for DR800/DR1000 yuri_b iRex Developer's Corner 0 09-18-2010 09:46 AM
Device plugin development reader42 Plugins 10 03-29-2010 12:39 PM
Calibre plugin development - Newbie problems minstrel Plugins 5 04-12-2009 12:44 PM


All times are GMT -4. The time now is 04:26 PM.


MobileRead.com is a privately owned, operated and funded community.