Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 02-11-2025, 10:27 AM   #1
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: 8,377
Karma: 5581842
Join Date: Nov 2009
Device: many
Ideas for New Improvements or Features

Hi All,

My Sigil to-do list is almost empty. So if you have ideas for improvements or new features that will help the majority of users without adding too much bloat, please add them here in this thread:

Please ...

- do NOT include requests better done in plugins or that duplicate current plugin functionality.

- do NOT include "advanced" editor requests better handled via "Open With" and using your favourite editor.

Please do post ideas and any justifications as to why your request would help users.

Feedback on other people ideas (either positive or negative) is also welcome.

Thanks!

Your Sigil Development Team

p.s. No promises that these will be included into future Sigil builds, but they will be carefully considered.

Last edited by KevinH; 02-11-2025 at 10:30 AM.
KevinH is offline   Reply With Quote
Old 02-11-2025, 12:33 PM   #2
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,269
Karma: 20170561
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
There is a plugin that is more of a proof-of-concept that would be very convenient to have as a built-in function: be able to use a function in the find/replace. It would allow for a myriad of possibilities only limited by the users ability to create the function. With access to a "Saved Functions" list it would reduce time spent...

For example: making a function to replace text with Title Case

This idea is unabashedly stolen from Calibre with Kovid's blessing to use.
Turtle91 is offline   Reply With Quote
Advert
Old 02-11-2025, 12:53 PM   #3
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: 8,377
Karma: 5581842
Join Date: Nov 2009
Device: many
There is a plugin that does function replacement for F&R that already exists and seems to work well. Unlike Calibre which is written in Python, Sigil is almost purely a C++ app with a one way interface to python for handling embedded routines. So adding user supplied python functions outside of Sigil's plugin framework would be a bit of an issue as would finding the required space to add a function interface to our current Find and Replace dialog.

Since I am not a Calibre user at all. I would need to see mock-ups of how to modify our current F&R dialog (without growing its height much if at all) to add in the interface elements required by a python function replace feature.

If you can provide those mock-ups here for everyone to see and comment on, I would be happy to look at integrating that functionality into mainline Sigil.

By the way... your idea violated the first "do NOT" rule provided by this announcement!

Oh well ...
KevinH is offline   Reply With Quote
Old 02-11-2025, 04:34 PM   #4
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,490
Karma: 29308976
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by KevinH View Post
There is a plugin that does function replacement for F&R that already exists and seems to work well. Unlike Calibre which is written in Python, Sigil is almost purely a C++ app with a one way interface to python for handling embedded routines. So adding user supplied python functions outside of Sigil's plugin framework would be a bit of an issue as would finding the required space to add a function interface to our current Find and Replace dialog.

Since I am not a Calibre user at all. I would need to see mock-ups of how to modify our current F&R dialog (without growing its height much if at all) to add in the interface elements required by a python function replace feature.

If you can provide those mock-ups here for everyone to see and comment on, I would be happy to look at integrating that functionality into mainline Sigil.

By the way... your idea violated the first "do NOT" rule provided by this announcement!

Oh well ...
Calibre adjusts the F&R dialogue to suit the Mode: Normal, Fuzzy, Regex and Regex-function… see attachments. Its F&R panel is 3 rows against Sigil's 4 rows.

Here's a shot of calibre alongside sigil that includes the function Create/Edit dialogue.

Click image for larger version

Name:	Calibre SxS Sigil.jpg
Views:	136
Size:	279.8 KB
ID:	213544

Doco ==>> https://manual.calibre-ebook.com/function_mode.html

BR
Attached Thumbnails
Click image for larger version

Name:	Normal & Fuzzy.jpg
Views:	124
Size:	120.4 KB
ID:	213545   Click image for larger version

Name:	Regex.jpg
Views:	132
Size:	82.1 KB
ID:	213546   Click image for larger version

Name:	Regex-function.jpg
Views:	99
Size:	88.0 KB
ID:	213547  
BetterRed is offline   Reply With Quote
Old 02-11-2025, 04:41 PM   #5
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: 8,377
Karma: 5581842
Join Date: Nov 2009
Device: many
@BetterRed

Where are these python function scripts located physically? Are they in the equivalent of our Sigil Preferences folder?

The create/edit button opens a python editor I assume. Is this just a simple text editor or is it python specific? Perhaps we require the user to select their own python editing app? When that happens? As providing a simple one in Qt would be a real pain.

Are there any predefined scripts provided out of the box?

Last edited by KevinH; 02-11-2025 at 04:49 PM.
KevinH is offline   Reply With Quote
Advert
Old 02-11-2025, 04:50 PM   #6
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,490
Karma: 29308976
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Make Search->File & Replace (and its shortcut) a Show and Hide toggle.

BR
BetterRed is offline   Reply With Quote
Old 02-11-2025, 04:54 PM   #7
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: 8,377
Karma: 5581842
Join Date: Nov 2009
Device: many
Quote:
Originally Posted by BetterRed View Post
Make Search->File & Replace (and its shortcut) a Show and Hide toggle.

BR
You meant Find not File right? And you want a repeat of the open Find and Replace shortcut to toggle if visible or not?
KevinH is offline   Reply With Quote
Old 02-11-2025, 05:00 PM   #8
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: 8,377
Karma: 5581842
Join Date: Nov 2009
Device: many
As for Python Function Replace - outside of numbering something or doing Title Case (or some other case conversion) how many people have actually used their own python function replace routines?

So is this overkill? For the few use cases, wouldn't just updating the current Plugin to work and adding a few common routines to it be better?
KevinH is offline   Reply With Quote
Old 02-11-2025, 05:17 PM   #9
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,490
Karma: 29308976
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by KevinH View Post
@BetterRed

Where are these python function scripts located physically? Are they in the equivalent of our Sigil Preferences folder?
Yep - editor-search-replace-functions.json


Quote:
Originally Posted by KevinH View Post
The create/edit button opens a python editor I assume. Is this just a simple text editor or is it python specific? Perhaps we require the user to select their own python editing app? When that happens? As providing a simple one in Qt would be a real pain.
Not sure what a python-specific editor looks like, but the one provided appears to be python-syntax aware.

Click image for larger version

Name:	Screenshot 2025-02-12 090216.jpg
Views:	126
Size:	288.7 KB
ID:	213548

Quote:
Originally Posted by KevinH View Post
Are there any predefined scripts provided out of the box?
Just a few simple ones, the doco has more complex examples.

BR
BetterRed is offline   Reply With Quote
Old 02-11-2025, 05:35 PM   #10
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,490
Karma: 29308976
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by KevinH View Post
You meant Find not File right? And you want a repeat of the open Find and Replace shortcut to toggle if visible or not?
I just want to be able to dismiss it via the menu or keyboard, like I can dismiss the other optional panels… Book browser, Preview, ToC, Clips etc.

Click image for larger version

Name:	Screenshot 2025-02-12 093003.jpg
Views:	119
Size:	172.0 KB
ID:	213549 Click image for larger version

Name:	Screenshot 2025-02-12 093401.jpg
Views:	126
Size:	96.4 KB
ID:	213550

BR
BetterRed is offline   Reply With Quote
Old 02-11-2025, 05:51 PM   #11
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: 28,264
Karma: 203719142
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
I'm on the fence about the usefulness of a Python replace function feature myself. I lean toward it being overkill, though. But then I rarely have a reason to transform content through F&R these days. I'd rather find a better source than to have to overhaul something via such granular, complex manipulation. *shrug*

Last edited by DiapDealer; 02-11-2025 at 05:53 PM.
DiapDealer is offline   Reply With Quote
Old 02-11-2025, 06:14 PM   #12
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,490
Karma: 29308976
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by KevinH View Post
As for Python Function Replace - outside of numbering something or doing Title Case (or some other case conversion) how many people have actually used their own python function replace routines?
I know of a couple of people who have made use of it in calibre, in one case to replicate some the features of Toxaris' ePUB tools and Transtools add-ins for Word.

Quote:
Originally Posted by KevinH View Post
So is this overkill?
IMO - YES… given it would be a non-trivial exercise to provide similar functionality within the Sigil eco-system, AND given there is nothing that precludes use of both editors.

BR
BetterRed is offline   Reply With Quote
Old 02-11-2025, 06:58 PM   #13
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,269
Karma: 20170561
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Sorry, I know it violated rule 1 in that it can be done as a plugin, but by that logic ALL find/replace could be done as a plugin. The current plugin is just a proof-of-concept, as stated in the plugin thread, it is not fleshed out or easily usable. If it is a built-in function then it can be easily used.

As for how many people have used their own functions in Calibre... that's hard/impossible to tell unless you monitor everyone's use of Calibre Editor

There are several examples in Calibre's documentation on how to do different functions, and I think there is/was a thread for people to share any creative functions they thought of. I don't know that we would need to provide more than a couple default functions...but it seems that this is a much easier/simpler way for someone to create/use a plugin-light function. I know people who have a great idea on something that they would use regularly but get scared away when told they need to create a whole plugin...they may be able/willing to create a simple function instead. We could even add these shared functions to a thread/sticky (like regex-examples) so others could use them.

Yes, it is possible to save the ePub, close Sigil, Open Editor, open the ePub, find/run the replace function, save the file, close Editor, Open Sigil, open the ePub, find where you were last editing and continue....oh, wait, There is another function I was supposed to do....

I honestly don't know all the particulars about C++, can it not import/run a python module? Doesn't the existing proof-of-concept Sigil plugin already show how to implement it in Sigil?
Turtle91 is offline   Reply With Quote
Old 02-11-2025, 07:54 PM   #14
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: 8,377
Karma: 5581842
Join Date: Nov 2009
Device: many
The issue is the user interface given the constraints on size in Find and Replace, and if a Python text editor is needed to create and edit python code. I could easily do a function replace in C or C++ but few if any people would or could create those.

And no the importing and running of the current function replace plugin works because all Sigil plugins are python code already so importing and using python functions or modules is very straight forward. In C++ it requires bridge code to pull that off. We have existing one way C++ to python bridge code in the embedded python interpreter in Sigil used for some very specific tasks and to provide a plugin interface which has additional safeguards so that a plugin can not easily crash Sigil.

All things to consider but none preclude the updating the current Function Replace plugin as it is more than just a proof of concept. I tested it when it first came out and it did work well.

Let's wait to here what others think.

Also can you point me to a Calibre thread that gives working replacement function code examples to play with?

Last edited by KevinH; 02-11-2025 at 08:00 PM.
KevinH is offline   Reply With Quote
Old 02-11-2025, 08:16 PM   #15
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,269
Karma: 20170561
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Here’s the Calibre user manual section: https://manual.calibre-ebook.com/function_mode.html

Here is the Calibre forum thread with function examples:https://www.mobileread.com/forums/sh...place+function
Turtle91 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Improvements/bugs/features dontcrash KOReader 10 10-23-2019 10:05 AM
Touch HD, Future features or dead features? ElWorm PocketBook 4 02-07-2018 11:36 AM
[FREE]Innovative Ideas to Ignite Your Mind: Business Ideas to Start Entrepreneurship amazon author Self-Promotions by Authors and Publishers 0 04-01-2015 04:09 AM
How many 'improvements' do we really need? Fozzybear General Discussions 61 04-15-2012 12:38 PM
ideas for calibre features smarties86 Recipes 3 07-01-2011 10:23 AM


All times are GMT -4. The time now is 10:52 AM.


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