Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 04-20-2020, 06:48 AM   #1
Skydancer
Enthusiast
Skydancer began at the beginning.
 
Skydancer's Avatar
 
Posts: 30
Karma: 10
Join Date: Mar 2019
Location: Slovenia
Device: PocketBoot Inkpad 3
[Feature Request] auto-completion & highlighting matching

Hi,
Let me first just say that I love Sigil, and that I'm not writing this to complain. I think it's the best ePub editor.

Lately, I've been using Bluefish Editor for other projects, and I like how easy and quick it is to write code with Bluefish, mainly because of the auto-completition, auto-tag-closing, and highlighting matching features.

I think Sigil users would benefit from these features. I often find myself checking CSS reference on the web and it can be time consuming.

Anyway, just some food for thought ...

Here are 3 pictures of how it looks in action:

CSS:


XHTML


Highlighting matching:
Skydancer is offline   Reply With Quote
Old 04-20-2020, 07:57 AM   #2
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
Use Sigil's clips features to insert or wrap text in any tag pair so that you do not need to worry about tag matching. Any unmatched tags will always be detected in Preview since it is set for xhtml. Or use Sigil's open with as desired.
KevinH is online now   Reply With Quote
Advert
Old 04-20-2020, 10:08 AM   #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: 7,644
Karma: 5433388
Join Date: Nov 2009
Device: many
I took a look at QCompleter, Qt's autocompleter class. It turns out the auto-completion via QCompleter really makes little sense for xhtml as it requires the first three letters to be typed.

As most really html tags are quite short (body, html, img, a, p, i, b, sub sup, head, title, hr ... using autocomplete for them really makes no sense when you have to use a keystroke to invoke autocomplete.

That is why I strongly recommend using Sigil's built in editing icons to handle h1-h6, p, i, b, u, and even to create lists of any type. Furthermore, using clips you can create any tag pairs you commonly use and set them up in one of the clips menu to single click insert them. Or even create clips for tag attributes you commonly use ie. class="". You can do the same clips approach to apply commonly used CSS classes set by your your own stylesheet with a single click as well.

So please try setting up clips and learning how to use them to make your editing much more effective.

And as I mentioned above, if you still like your emacs, vim, Kate, Bluefish, xedit, bbedit, notepad++, or whatever editor or ide you prefer, you can set Sigil to use them using "open with" allowing you to easily use your editor of choice within the Sigil program.

Sigil is not in the game of making a better code editor. There are simply too many code editor programs out there already desperate for users that people can choose from.

Hope this explains better Sigil's approach to editing.
KevinH is online now   Reply With Quote
Old 04-20-2020, 02:43 PM   #4
Skydancer
Enthusiast
Skydancer began at the beginning.
 
Skydancer's Avatar
 
Posts: 30
Karma: 10
Join Date: Mar 2019
Location: Slovenia
Device: PocketBoot Inkpad 3
Thank you for your reply.

I'm already using clips and editing icons. They're really helpful, especially clips. And I see now that the "Open with" feature works nice & smooth as well, I just hadn't tried using it until today. Thanks for reminding me it exists.
Skydancer is offline   Reply With Quote
Old 04-20-2020, 09:50 PM   #5
Mister L
Groupie
Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Mister L is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.
 
Posts: 159
Karma: 91148
Join Date: Jun 2010
Device: Sony 350
Not sure if this is what you are looking for but in xhtml I find really useful the "auto-close" feature in Sigil : type CTRL+SHIFT+. and any tag which is open where the cursor is placed will be closed. Can save a few keystrokes sometimes (blockquote, figcaption... ). You can also do it multiple times if you have nested open tags and you want to close all of them at once (li ul / ol for instance or strong / em / span p or similar).
Mister L is offline   Reply With Quote
Advert
Old 04-22-2020, 03:46 AM   #6
HaPeSchu
Banned
HaPeSchu began at the beginning.
 
Posts: 20
Karma: 10
Join Date: Feb 2020
Device: tolino epos
Quote:
Originally Posted by Mister L View Post
Not sure if this is what you are looking for but in xhtml I find really useful the "auto-close" feature in Sigil : type CTRL+SHIFT+. and any tag which is open where the cursor is placed will be closed
Hmmm im unable to find this feature on a mac. I tried several combinations with ctrl option command and shift bnut none of them worked.

In the list of shortcuts in the preferences i cant find something mentioned as well. Is this not available on a mac?
HaPeSchu is offline   Reply With Quote
Old 04-22-2020, 05:16 AM   #7
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
Menu: Insert > Closing Tab
Shortcuts: Closing Tab
BeckyEbook is offline   Reply With Quote
Old 04-22-2020, 07:38 AM   #8
HaPeSchu
Banned
HaPeSchu began at the beginning.
 
Posts: 20
Karma: 10
Join Date: Feb 2020
Device: tolino epos
Thx. I was pretty sure i did know all points in the menu, but obvious thats wasnt the case

In the prefernce list the description starts with "insert" so if you sort this it doesnt appear under "c".

The name starts with "c", but the keyboard shortcut says ctrl + . and this doesnt work as it is command + . on a mac (i always tried with shift).

Is there a reason why the shortcut in the menu is correct (command + .) whereas in the list in the prefernces it isnt? is there no way to distinguish between win/linux/mac in this section?
HaPeSchu is offline   Reply With Quote
Old 04-22-2020, 08:43 AM   #9
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
No. This is always how a macOS Shortcut keys are defined in Qt. They clearly document that.
KevinH is online now   Reply With Quote
Old 04-22-2020, 10:13 AM   #10
HaPeSchu
Banned
HaPeSchu began at the beginning.
 
Posts: 20
Karma: 10
Join Date: Feb 2020
Device: tolino epos
So, you mean as a sigil user i have to read the Qt documentation? Or what else do you want to address to me?

No need to reply, just think about the value of your answer to a user of sigil. I have my answer, thx Becky,
HaPeSchu is offline   Reply With Quote
Old 04-22-2020, 10:28 AM   #11
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
Yes, this should be documented in the Sigil User's guide and if not I will add it.

No, I am not changing the way Qt (and Sigil) has handled things since the very beginning to make a new macOS user happy while breaking long-time macOS Sigil users and Qt users.

ps. created an issue to remind me to add the Ctrl to CMD automapping by Qt on macOS to Sigil User's guide

Last edited by KevinH; 04-22-2020 at 03:06 PM. Reason: added ps
KevinH is online now   Reply With Quote
Old 04-22-2020, 10:36 AM   #12
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
Here is the quote from Qt docs that explains their rationale which makes sense:
Quote:
Note: On macOS, references to "Ctrl", Qt::CTRL, Qt::Key_Control and Qt::ControlModifier correspond to the Command keys on the Macintosh keyboard, and references to "Meta", Qt::META, Qt::Key_Meta and Qt::MetaModifier correspond to the Control keys. Developers on macOS can use the same shortcut descriptions across all platforms, and their applications will automatically work as expected on macOS.
So using this convention allows each platforms most common shortcut key sequenes to work as expected from a single codebase. Ctrl+C will work for Windows/Linux to copy as will Apple+C for copy on macOS without any code changes. This is how it has always been and it makes good sense for a cross-platform app like Sigil which is what Qt was designed for.
KevinH is online now   Reply With Quote
Old 04-22-2020, 11:11 AM   #13
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,550
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by HaPeSchu View Post
No need to reply, just think about the value of your answer to a user of sigil.
Gee... what a novel idea.
DiapDealer is offline   Reply With Quote
Old 04-22-2020, 01:58 PM   #14
HaPeSchu
Banned
HaPeSchu began at the beginning.
 
Posts: 20
Karma: 10
Join Date: Feb 2020
Device: tolino epos
Quote:
Originally Posted by DiapDealer View Post
Gee... what a novel idea.
Of course i will read the documentation of c++ before asking my next question here.
HaPeSchu is offline   Reply With Quote
Old 04-22-2020, 02:11 PM   #15
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
Quote:
Originally Posted by HaPeSchu View Post
Of course i will read the documentation of c++ before asking my next question here.
Please do!
KevinH is online now   Reply With Quote
Reply

Tags
auto-completion, css, highlighting matching, sigil, xhtml


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Feature Request: auto-close CC after opening a book ohIdon'tknow Calibre Companion 3 12-16-2015 06:30 AM
Auto Add - a feature request or suggestion Weekendmedic Library Management 3 05-30-2014 09:49 AM
Feature Request: Auto import books on collections from folders rfog Calibre 1 04-14-2014 04:40 AM
[Old Thread] Auto Extract ISBN-Feature request UnraisedArc Calibre 60 03-23-2011 09:31 AM
Feature Request: PDF zoom & pan control dwprice Kobo Reader 2 07-07-2010 10:24 PM


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


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