View Single Post
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,437
Karma: 5702578
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