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 01-31-2023, 10:42 AM   #511
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,647
Karma: 5433388
Join Date: Nov 2009
Device: many
No problems. We just wish the Linux distributions could come together to create a common desktop environment, gui, and package format and move to a rolling release. It would simplify so much. Arch and its derivatives like Manjaro seem like our best hope for fast updates. But there is still too much choice and that makes people uncomfortable and leads to distribution chaos.

I got involved with PowerPC linux dev in the early 90s, and I am still waiting to see something.
KevinH is online now   Reply With Quote
Old 01-31-2023, 10:57 AM   #512
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,552
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by philm View Post
Sorry, nothing personal here, I just need to say it because it happens too often:
- When will be the time to ask USERS to build on Windows, like for Linux USERS? Or are we second zone citizens?
When up to date Windows installers aren't easy to provide. The rainbow of Linux distros don't make it simple at all for us to provide a binary distribution of Sigil, so we rely on the various Repo maintainers to do so for their users.

I get the frustration, but this is very much a Linux Repo maintainer problem. There is no reason Ubuntu can't offer the latest Sigil to their users. Many other distros do. Bureaucracy and dogma are most often the reasons they don't (couched in statements touting "stability").

And no, you're not second class citizens. Quite the opposite in fact. As a Linux user, you have the ability to easily build custom versions of many open-source software applications with tools that are provided by your operating system right out of the box. Windows user don't have that luxury.

I do all of my Sigil development on Linux (Kevin does his on Mac), so neither of us are Windows "homers" when it comes to this sort of thing. The only thing we might be guilty of is assuming that those who have adopted Linux has their OS of choice have a bit of an edge over Windows users when it comes to compiling stuff.
DiapDealer is offline   Reply With Quote
Advert
Old 01-31-2023, 12:03 PM   #513
philm
Member
philm began at the beginning.
 
Posts: 24
Karma: 10
Join Date: Jul 2022
Location: France
Device: Kobo Clara
I agree it's a Linux repo problem.
Just by curiosity, did you try AppImage since it works on everything that runs FUSE (CentOS RHEL, Suse, Fedora, Arch, Ubuntu, Debian)?
I don't know how to build an AppImage so I just wonder.
philm is offline   Reply With Quote
Old 01-31-2023, 12:07 PM   #514
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,647
Karma: 5433388
Join Date: Nov 2009
Device: many
AppImage requires the app to be fully relocatable. I do this for Sigil on macOS but making python itself fully drag and drop relocatable is not easy and requires some manual tweaking after a build. The same must hold for all Sigil dependencies. Not a straightforward task especially on platforms that make heavy use of build-time rpaths.
KevinH is online now   Reply With Quote
Old 01-31-2023, 12:11 PM   #515
philm
Member
philm began at the beginning.
 
Posts: 24
Karma: 10
Join Date: Jul 2022
Location: France
Device: Kobo Clara
Ah, ok, I didn't get this part of relocatable python and dependencies. I thought it was packaging everything, like Blender who comes with its own python.
philm is offline   Reply With Quote
Advert
Old 01-31-2023, 12:43 PM   #516
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,647
Karma: 5433388
Join Date: Nov 2009
Device: many
It does, but if the app is relocatable then everything packaged with it must be relocatable. This is straightforward with macOS Frameworks where everything is stored inside the macOS .app folder.

But the concept of Frameworks which effectively duplicate general shared libraries so that they become app specific is something almost all Linux distributions are strongly against.

This is understandable for a server os, but it is not understandable for a desktop os.
KevinH is online now   Reply With Quote
Old 02-19-2023, 12:38 PM   #517
charlweed
Enthusiast
charlweed began at the beginning.
 
Posts: 27
Karma: 30
Join Date: Jul 2011
Device: none
Preferred way to install an external modules for a plugin

I'd like to write a plugin that uses PyDictionary, which is a english language dictionary.
How do I "install" external modules so they is available to my Calibre plugin, and can be re-distributed within the zip? I typically install stuff with pip, but that does not seem correct for distributable plugins.

Last edited by charlweed; 02-19-2023 at 01:08 PM.
charlweed is offline   Reply With Quote
Old 02-19-2023, 12:46 PM   #518
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,647
Karma: 5433388
Join Date: Nov 2009
Device: many
They must be packaged inside the plugin and the plugin needs to extend the python sys path.

FWIW, you have built-in access to the hunspell spell checker and lots of hunspell dictionaries directly in the plugin. But pyDictionary is more WordNet than spellchecking dictionary. There are numerous thesaurus programs that use WordNet data directly and lots of front ends.
KevinH is online now   Reply With Quote
Old 02-19-2023, 12:50 PM   #519
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,584
Karma: 22735033
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by charlweed View Post
How do I "install" external modules so they is available to my Calibre plugin, and can be re-distributed within the zip?
Simply copy them to the plugin folder.
Do you want to write a plugin for Sigil or Calibre?
FYI: there's no Sigil API function for getting the word under the cursor.
Doitsu is offline   Reply With Quote
Old 02-19-2023, 01:06 PM   #520
charlweed
Enthusiast
charlweed began at the beginning.
 
Posts: 27
Karma: 30
Join Date: Jul 2011
Device: none
Thanks, I will try using the included hunspell. I'm a Python and Calibre plugin newb so I have lots of trial and error ahead.

The goal of my plugin will be to help me un-mangle a very messy Calibre library. There are hundreds of books with titles mixed into the author fields, and vice-versa. My first pass is to find authors that have several common english words in the name. Then I can inspect them to see if they are really titles, and process them further.

Last edited by charlweed; 02-19-2023 at 01:09 PM.
charlweed is offline   Reply With Quote
Old 02-19-2023, 01:23 PM   #521
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,647
Karma: 5433388
Join Date: Nov 2009
Device: many
Then this belongs in the Calibre forum not Sigil. Calibre plugins are different.
KevinH is online now   Reply With Quote
Old 02-19-2023, 01:42 PM   #522
charlweed
Enthusiast
charlweed began at the beginning.
 
Posts: 27
Karma: 30
Join Date: Jul 2011
Device: none
oops! Sorry!
charlweed is offline   Reply With Quote
Old 12-04-2023, 07:55 PM   #523
codepoet
Junior Member
codepoet began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Dec 2023
Device: Kobo, HP TouchPad
Post New Sigil Plugin - Punctuation Dumbener

I read eBooks on older devices (webOS tablets, circa 2011) that can't render fancy new HTML entities for things like smart quotes. They just end up garbled. So I modified the very handy punctuationsmarten-sigil-plugin to go the other way.

This plug-in replaces the entities for smart quotes, ellipsis, and other common modern niceties with their simpler equivalents, readying content for consumption on older devices.
The source, and a release .zip, is here: https://github.com/codepoet80/punctu...n-sigil-plugin

Would love to have it available in the official list -- any idea how I could submit for that?
codepoet is offline   Reply With Quote
Old 12-04-2023, 09:42 PM   #524
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,647
Karma: 5433388
Join Date: Nov 2009
Device: many
Create a new post in the Plugins thread, not here in the thread for development issues.
You can model it on all of the other plugin thread topics. Put a link to your plugin in the new topic thread and attach a copy of the latest plugin to your first post.

Once that is created, we will try it out and if okay, add a link in our Plugin_Index sticky post to your plugin.
KevinH is online now   Reply With Quote
Old 04-20-2024, 03:56 AM   #525
Jaco
Junior Member
Jaco began at the beginning.
 
Posts: 5
Karma: 10
Join Date: May 2023
Device: none
Plugin pull request

Hi everybody,

It is Jacob, from Spain (EU).

I don't know a word about programming (I am a professional editor) but I love Sigil. I am a 100% evangelist.

Recently I discovered HAML markup language, and I found it helps a lot to write HTML code faster. Some info:

https://herotofu.com/haml-converter
https://haml.info/

AI say me that pyhaml library could do it and it gives me this piece of code, but I have no idea how to program in Python.

I was wondering if there is any volunteer to write a plugin for converting HALM to HTML.

Thanks in advance.

---------

# Installation pyhaml with pip:
# pip install pyhaml

from pyhaml_jinja import Compiler

# Your HAML (change this with your code HAML)
haml_content = """
%html
%head
%title Example HAML to HTML
%body
%h1 Hello, Word!
%p Converting example HAML to HTML.
"""

# Compile HAML
compiler = Compiler()

# Convert HAML to HTML
html_content = compiler.process(haml_content)

# Print HTML
print(html_content)
Jaco 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 03:41 PM.


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