|
|
#16 |
|
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 29,016
Karma: 210162574
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
I'm not following the example of a cached parse tree that a relaunched plugin (same Sigil instance) could reuse either. Just because the same instance of Sigil is open is no guarantee that the cached tree in the plugin is still going to match the current tree in Sigil. If it does still match (no subsequent Sigil edits were made before the plugin was relaunched) then why was the plugin closed in the first place?
Unless you're talking about a completely external tree that's being cached. But in that case, why would it matter if Sigil had been relaunched or not? I understand this sort of thing might work well for your particular workflow, but it seems like a highly specialized thing that's not going to benefit very many people in the long run. |
|
|
|
|
|
#17 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,208
Karma: 6565382
Join Date: Nov 2009
Device: many
|
And for what it is worth the python os.getppid() function can be used in a plugin to get the Sigil process id. So both date and parent process id are retrieveable in a python plugin without any changes to Sigil.
Last edited by KevinH; Yesterday at 01:22 PM. |
|
|
|
|
|
#18 |
|
Bibliophagist
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 49,482
Karma: 174632680
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
|
IMNSHO, epubcheck and either the builtin Validate stylesheets with W3C or the offline CSSValidator plugin do a better job than is done by calibre's Check book. Especially when you are wanting to publish a book where calibre deliberately does not check for several errors which publishers running epubcheck will detect and bounce back to the author for correction.
|
|
|
|
|
|
#19 |
|
null operator (he/him)
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 22,135
Karma: 30317706
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
FWIW: I make use of these calibre features: Live CSS panel (saves me unravelling) and Reports->Words (because I can save the list). I don't have a problem with using both editors.
I also like calibre's display of character name preceding cursor (at bottom right), would quite like to have it Sigil. BR |
|
|
|
|
|
#20 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,208
Karma: 6565382
Join Date: Nov 2009
Device: many
|
- The Live CSS panel is part of the Preview Inspector in Sigil as Sigil uses the Chrome computed css for any selected element and does not try to duplicate it. That will not change.
- You can generate a list of all words using a plugin or in the SpellCheck dialog with a copy and paste. - Please explain of what real use is the name of the character preceding the cursor? The cursor in Sigil's CodeEditor can be made double width to more easily see its position in the text if you have trouble seeing the cursor. |
|
|
|
|
|
#21 |
|
null operator (he/him)
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 22,135
Karma: 30317706
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
I find Live CSS easier - don't have to click on anything, don't need Preview, if it's not already shown I can pop it from the menu bar or use a shortcut. It opens in a dock site, and doesn't have a slew of features/options I don't understand… many of which I suspect are irrelevant to EPUBs.
Calibre's Reports->Words->Save is to a CSV file. Re the display of character descriptor - useful when editing foreign language transcriptions. Diacritics often get carried over… e.g macrons over vowels often show up in Māori to English translations for no gōōd reason. BR Last edited by BetterRed; Today at 04:50 AM. Reason: clarity |
|
|
|
|
|
#22 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,208
Karma: 6565382
Join Date: Nov 2009
Device: many
|
Live CSS via Inspector is how Sigil will handle that as even if you hand apply your own css scoring rules and recreate what a browser processing css will do, you are much better using the Preview's exact final DOM tree to do it which is exactly what the Inspector does.
You can configure the Inspector to open as you like it and it will be remembered. So that is not going to be changed as its primary use is when some unexpected css styling appears. I will think about adding a Report -> Words that can be saved as csv. I am still not sure about the usefulness of seeing the name of the character that precedes the cursor or even under the cursor. It really depends on if losing vertical height in the CodeEditor (at least one status line) is worth it. Last edited by KevinH; Today at 09:36 AM. |
|
|
|
|
|
#23 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,208
Karma: 6565382
Join Date: Nov 2009
Device: many
|
Okay, I have looked and Qt does *not* have a built in way to get the official name for any QChar value, just its category. To add this to a C++ app you must link it to the ICU library which is not directly accessible on some platforms, and some platforms use older private versions.
In python, this name is available in the unicodedata module. And I believe Calibre already links to the ICU library for other things. So getting the character name would either slow down the editor forcing it to call into the python interpreter every time you move the cursor, or add 31 meg of app size to embed the ICU data tables and library into Sigil. Neither of these am I willing to do for such limited benefit, especially given it would also consume a line of vertical space in the CodeEditor. So the character name of the character under the cursor is not going to happen. That said ... I will either add a Words Report with the ability to save to csv or simply add a Save Selected pop up menu item to the Spellcheck dialog so that you can save the table to CSV. Most probably the latter as it is simpler and makes more sense. Last edited by KevinH; Today at 04:36 PM. |
|
|
|
|
|
#24 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,208
Karma: 6565382
Join Date: Nov 2009
Device: many
|
Okay, it turns out that adding a "Save Selected" pop up menu item to the SpellcheckEditor dialog was the easiest to implement versus an entire new report with limited usefulness.
I have pushed this new feature to Sigil master, it will appear in the next release. |
|
|
|
|
|
#25 | |
|
Chalut o/
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 557
Karma: 718860
Join Date: Dec 2017
Device: Kobo
|
Quote:
Currently, if the xhtml is malformed, you need to read the "header error report" at the top of the preview or open the "Validation Result" dialog. This two tools are great, but you need to manualy brower to the malformed line and meti-cu-lou-sly read the code for found the error. A little visual help would be very appreciated. Make it aslo work for CSS and various XML could be nice too. Last edited by un_pogaz; Today at 05:16 PM. |
|
|
|
|
|
|
#26 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,208
Karma: 6565382
Join Date: Nov 2009
Device: many
|
An IDE and syntax coloring already exists for valid xhtml in CodeEditor. Are you asking for a special syntax color to help identify what is incorrect (but that can not help if something is missing). The Validation pane and the xmlparsing error is already placed and the page up to the error is already displayed in Preview.
How much more help does someone need to find an error? |
|
|
|
|
|
#27 | |
|
Chalut o/
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 557
Karma: 718860
Join Date: Dec 2017
Device: Kobo
|
Quote:
I will very prefer it with a undeline wave, 'bigger' than for spell error (so very like in a code IDE), but I let you see how implement it at the end. As long as there is a clear and specific such visual hint, I would be satisfied. Like I said, the "Validation pane" and the "xmlparsing error" work fine, but it would be sooooooooooooo great to have also a hint in the code view itself. |
|
|
|
|
|
|
#28 |
|
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,208
Karma: 6565382
Join Date: Nov 2009
Device: many
|
But what do you colourize if it is missing? Most structural errors are errors of omission.
And worse yet many parsing errors can not be detected until another tag is parsed much later in the file. And so Highlighting any error location will probably not be correct as the missing tag could go in many different locations based on degree of nesting. Only the initial creator of the xhtml can know where the omission happens. Sorry, this is really not something I am interested in. Maybe improving position info to be more precise from the validation pane to the destination file would make sense. I will think about that. This is dangerously close to the feature request for advanced editors that were strictly forbidden in the first post of this thread! I am much happier using the validation pane to locate the error, then to rely on a guessed error location. |
|
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Suggestions for Sigil Improvements or New Features | KevinH | Sigil | 168 | 11-18-2025 01:23 PM |
| Suggestions for New Plugins and Plugin Improvements | KevinH | Plugins | 0 | 09-22-2025 11:53 AM |
| Ideas for New Improvements or Features | KevinH | Sigil | 97 | 04-09-2025 10:45 AM |
| Improvements/bugs/features | dontcrash | KOReader | 10 | 10-23-2019 11:05 AM |
| Onyx M92: Suggestions for possible improvements | Lode | Onyx Boox | 3 | 02-11-2013 08:40 AM |