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 03-20-2021, 06:11 PM   #46
Onyx Tao
Moderately Puzzled
Onyx Tao began at the beginning.
 
Onyx Tao's Avatar
 
Posts: 1
Karma: 10
Join Date: Mar 2021
Device: MARVIN on iOS
Smile CSS Preprocessor Support / plugin

It would be handy to be able to write, for example, SASS (scss) stylesheets, and have Sigil update the .scss to .css.

But any reasonably powerful CSS-extension language (Sass, Less, Stylus) would work.

Came to this forum to see if someone had already created such a beast, or, worst case, estimate the effort required to do it myself. And since you're asking what I'd like to see ... well, I'd love to see one!

Cheers,
OT
Onyx Tao is offline   Reply With Quote
Old 03-20-2021, 08:23 PM   #47
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,644
Karma: 5433388
Join Date: Nov 2009
Device: many
Are there open source (GPL/MIT/BSD) projects that can take CSS extension languages and generate standard css? If so, this would certainly be something for a plugin. I have never used any of these, so links to appropriate github projects in python3, C, or C++ that does this might help.
KevinH is offline   Reply With Quote
Old 01-09-2023, 11:14 PM   #48
Chang
Connoisseur
Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!
 
Posts: 87
Karma: 50000
Join Date: Oct 2009
Device: none
Replace title value with h1 value

It would be nice to have a plugin that searches the value of the first h1 element in html file and puts it in the title element of the same html file. I'm using InDesign to create ebooks and the title element is just something generic. I checked available Sigil plugins but nothing I found seemed to do this.
Chang is offline   Reply With Quote
Old 01-09-2023, 11:54 PM   #49
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
find replace would do it.

Code:
find: <title>.*?</title>(.*?)<h1>(.*?)</h1>
replace: <title>/2</title>/1<h1>/2</h1>

Although, I wouldn't worry about doing this for each html file. Most readers/apps don't really care about that, if at all. So I put the title of the book at the top of the page, not the title of the chapters. I actually replace the entire header portion with a simplified version to clean up a lot of the fluff people put in the header:

Code:
find:
  .*?</head>

replace: 
  <?xml version="1.0" encoding="utf-8"?>
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
    "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

  <html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>Title of the Book</title>
    <link href="../Styles/styles.css" type="text/css" rel="stylesheet"/>
  </head>

Last edited by Turtle91; 01-10-2023 at 12:01 AM.
Turtle91 is offline   Reply With Quote
Old 01-10-2023, 05:31 AM   #50
BeckyEbook
Guru
BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.BeckyEbook ought to be getting tired of karma fortunes by now.
 
BeckyEbook's Avatar
 
Posts: 692
Karma: 2180740
Join Date: Jan 2017
Location: Poland
Device: Misc
Quote:
Originally Posted by Chang View Post
It would be nice to have a plugin that searches the value of the first h1 element in html file and puts it in the title element of the same html file.
Such a plugin exists. Download it from here.
BeckyEbook is offline   Reply With Quote
Old 02-15-2023, 09:59 PM   #51
Chang
Connoisseur
Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!
 
Posts: 87
Karma: 50000
Join Date: Oct 2009
Device: none
Quote:
Originally Posted by BeckyEbook View Post
Such a plugin exists. Download it from here.
This plugin seems to do the trick, thank you!
I'm creating accessible ebooks and I need to have descriptive title for each xhtml file as explained in Daisy's instructions. Having a name of the book in each title element isn't adequate.
Chang is offline   Reply With Quote
Old 02-16-2023, 08:57 AM   #52
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,644
Karma: 5433388
Join Date: Nov 2009
Device: many
Shameless plug ... if you are interested in creating more accessible epub3, you might want to checkout my Access-Aide plugin which will properly fill in missing titles, allow img alt attributes to be easily updates, add aria roles based on existing epub:type attributes, and etc.
KevinH is offline   Reply With Quote
Old 02-27-2023, 01:56 AM   #53
Chang
Connoisseur
Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!Chang is faster than a rolling 'o,' stronger than silent 'e,' and leaps capital 'T' in a single bound!
 
Posts: 87
Karma: 50000
Join Date: Oct 2009
Device: none
Quote:
Originally Posted by KevinH View Post
Shameless plug ... if you are interested in creating more accessible epub3, you might want to checkout my Access-Aide plugin which will properly fill in missing titles, allow img alt attributes to be easily updates, add aria roles based on existing epub:type attributes, and etc.
This seems to be a great plugin but it doesn't place the chapter header to the title element. As you probably know InDesign creates generic titles for each xhtml file so the title element is never empty. I noticed that your plugin places header to title element only if the title is empty. But I think I might use your plugin to add other required accessible features in ebooks. Thank you!
Chang is offline   Reply With Quote
Old 02-27-2023, 02:37 AM   #54
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,644
Karma: 5433388
Join Date: Nov 2009
Device: many
I never use InDesign as it just makes extra work for me.

Note: You can easily use Sigil's Find and Replace All capability to empty all title tags at the same time n one go *before* running the plugin.

Last edited by KevinH; 02-27-2023 at 04:27 AM.
KevinH is offline   Reply With Quote
Old 02-27-2023, 06:08 AM   #55
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 73,976
Karma: 128903378
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Chang View Post
This seems to be a great plugin but it doesn't place the chapter header to the title element. As you probably know InDesign creates generic titles for each xhtml file so the title element is never empty. I noticed that your plugin places header to title element only if the title is empty. But I think I might use your plugin to add other required accessible features in ebooks. Thank you!
<title>Book Title</title>

That's how the title is supposed to be used. It's not supposed to be used to put in things like Chapter 1.
JSWolf is offline   Reply With Quote
Old 02-27-2023, 10:18 AM   #56
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Welllllll, actually….

There is no requirement for anything to be in the title tags…. Just that you have a title tag.

Originally html documents were not designed to be zipped up and put in a book…
When multi-tabbed browsers were introduced they would use the contents of the title tag in the tab, but otherwise most readers/devices/apps completely ignore the contents of the title tag.

There is nothing wrong with putting chapter names in there, it’s just largely irrelevant.
Turtle91 is offline   Reply With Quote
Old 02-27-2023, 10:39 AM   #57
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,644
Karma: 5433388
Join Date: Nov 2009
Device: many
For accessible epub reasons, they require that the title tag be filled and that they should be relevant to that html file (for screen readers and things).
KevinH is offline   Reply With Quote
Old 02-27-2023, 11:04 AM   #58
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Valid point!

I was only thinking about ePub standard, not accessibility standard. Thanks!
Turtle91 is offline   Reply With Quote
Old 02-27-2023, 07:44 PM   #59
slowsmile
Witchman
slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.slowsmile ought to be getting tired of karma fortunes by now.
 
Posts: 628
Karma: 788808
Join Date: May 2013
Location: Philippines
Device: Android S5
@Chang...Another shameless plug. I also have two plugins that automatically add the section or chapter title to the <title></title> tags. These plugins are GenerteHeaders and CustomCleanerPlus. Both these plugins automatically set the title name to the current chapter or section heading name.
slowsmile is offline   Reply With Quote
Old 12-25-2023, 05:26 AM   #60
iieeann
Member
iieeann began at the beginning.
 
iieeann's Avatar
 
Posts: 12
Karma: 10
Join Date: Dec 2020
Device: Android
Is there a plugin that can save the search & replace as favourite? This make repeating search & replace much easier.
Is is difficult to just depend on the droplist history. I have to create a txt file to save a long list of normal & regex for what i need to search and replace, then copy paste to Sigil, select either regex or normal, select either this page or whole html.... which is very troublesome. I need to do this for every book i download.

Everytime i download a book i will be like oh gosh i need to repeat the same thing all over again...
iieeann is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[FileType Plugin] YVES Bible Plugin ClashTheBunny Plugins 27 01-16-2023 01:25 AM
[GUI Plugin] KindleUnpack - The Plugin DiapDealer Plugins 492 10-25-2022 08:13 AM
Plugin not customizable: Plugin: HTML Output does not need customization flyingfoxlee Conversion 2 02-24-2012 02:24 AM
[GUI Plugin] Plugin Updater **Deprecated** kiwidude Plugins 159 06-19-2011 12:27 PM
New Plugin Type Idea: Library Plugin cgranade Plugins 3 09-15-2010 12:11 PM


All times are GMT -4. The time now is 12:16 PM.


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