Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 12-11-2025, 08:32 PM   #1
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 118
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
Drag and drop not working?

I just noticed that drag and drop no longer works in the code editor. Was this changed recently?


Maybe this will inspire me to come up with a regex to fix the badly interweaved spans in this document that I’ve been fixing by dragging tags around.
seanos is offline   Reply With Quote
Old 12-11-2025, 08:39 PM   #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: 9,157
Karma: 6565346
Join Date: Nov 2009
Device: many
Drag and drop in the editor was never officially supported because its usage constantly caused Qt segfaults. Its use is disabled for that reason as we do not want to support something that can cause crashes that we can not fix as they are internal to Qt.

There is an environment variable a user can set to re-enable it in Sigil. But if you choose to do that, you will get no support from us for any crashes it may cause.

I do not remember the exact env variable name anymore, but it is documented in the advanced chapters in our Sigil user guide that deals with environment variables and Sigil.

Update ... Found it:

SIGIL_ALLOW_CODEVIEW_DROP If this value is set, drag and drop editing inside CodeView is enabled. Be warned that on some platforms, using drag and drop to edit inside CodeView can be unstable causing Sigil to crash. No support will be provided to people who decide to enable drag and drop as fixing these issues are outside our control (internal to Qt6).

Last edited by KevinH; 12-11-2025 at 08:45 PM.
KevinH is offline   Reply With Quote
Old 12-11-2025, 08:41 PM   #3
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 118
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
Thanks. I don’t think I’ve experienced that crash, or at least, not often enough to recall.
seanos is offline   Reply With Quote
Old 12-11-2025, 09:36 PM   #4
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 118
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
Maybe I had this set in the desktop entry file which has been overwritten.

I tried setting this in .bashrc, but that doesn’t seem to work for some reason. I can see the variable is set from a command prompt.

Launching from a local desktop entry with env SIGIL_ALLOW_CODEVIEW_DROP=1 sigil %F works so I suppose I just need to keep a .local copy of the desktop file.
seanos is offline   Reply With Quote
Old 12-11-2025, 10:53 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: 9,157
Karma: 6565346
Join Date: Nov 2009
Device: many
Or your login account uses a .profile instead of .bashrc
KevinH is offline   Reply With Quote
Old 12-11-2025, 11:42 PM   #6
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 118
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
I seem to have both .profile and .bashrc (but no .bash_profile). The .profile sources .bashrc though (. "$HOME/.bashrc").

If the variable appears when I type env in a command prompt, shouldn’t it be available to Sigil?
seanos is offline   Reply With Quote
Old 12-11-2025, 11:47 PM   #7
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,970
Karma: 208569852
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Depends on the distro. The terminal environment is typically not exactly same as the gui environment.

Why not just set the variable by adding it to the env-vars.txt file in Sigil's prefs directory (create the file if need be) and be done with it? Use of the env-vars.txt file was introduced in Sigil 2.6.2

Last edited by DiapDealer; 12-11-2025 at 11:55 PM.
DiapDealer is offline   Reply With Quote
Old 12-11-2025, 11:57 PM   #8
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 118
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
At a guess, because I didn’t realise that was a thing.
seanos is offline   Reply With Quote
Old 12-12-2025, 12:03 AM   #9
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 118
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
In this process I’ve also noticed that I can’t copy text from the online version of Sigil’s manual.
seanos is offline   Reply With Quote
Old 12-12-2025, 05:31 AM   #10
philja
Addict
philja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enough
 
Posts: 313
Karma: 516
Join Date: Nov 2015
Location: Europe EEC
Device: Kindle Fire HD6 & HD8
Quote:
Originally Posted by DiapDealer View Post
Depends on the distro. The terminal environment is typically not exactly same as the gui environment.

Why not just set the variable by adding it to the env-vars.txt file in Sigil's prefs directory (create the file if need be) and be done with it? Use of the env-vars.txt file was introduced in Sigil 2.6.2
This thread prompted me to review the environment variables in the user guide. I didn't realise there were so many possibilities. The guide doesn't show any example entry.

What would an entry in env-vars.txt look like?
philja is offline   Reply With Quote
Old 12-12-2025, 05:39 AM   #11
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: 915
Karma: 3501166
Join Date: Jan 2017
Location: Poland
Device: Various
Use the Force plugin, Luke.
BeckyEbook is offline   Reply With Quote
Old 12-12-2025, 07:18 AM   #12
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,970
Karma: 208569852
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Lots of insight into the feature in the thread where its inclusion was first discussed:

https://www.mobileread.com/forums/sh...d.php?t=369497
DiapDealer is offline   Reply With Quote
Old 12-12-2025, 09:12 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: 28,970
Karma: 208569852
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by seanos View Post
In this process I’ve also noticed that I can’t copy text from the online version of Sigil’s manual.
Not sure why. It works fine for me. From the Advanced section of the user guide: Using Sigil's Environment Variables

Some rarely needed settings in Sigil are controlled by "Environment Variables". An environment variable is a user-definable value that can affect the way running processes will behave on a computer. See https://en.wikipedia.org/wiki/Environment_variable for more information on setting and using environment variables on your computer. Starting with Sigil 2.6.2, we have tried to make the process of setting and changing Sigil's environment variables much easier. With that release or later you can now simply use any text editor you want (Notepad, BBedit, emacs, vi, kate, etc) and create a file called "env-vars.txt" inside your Sigil Preferences folder. Add each environment variable and its value, one per line, in the following format:

ENVIRONMENT_VARIABLE_NAME=VALUE

Last edited by DiapDealer; 12-12-2025 at 09:18 AM.
DiapDealer is offline   Reply With Quote
Old 12-12-2025, 09:25 AM   #14
philja
Addict
philja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enoughphilja will become famous soon enough
 
Posts: 313
Karma: 516
Join Date: Nov 2015
Location: Europe EEC
Device: Kindle Fire HD6 & HD8
Quote:
Originally Posted by DiapDealer View Post
Lots of insight into the feature in the thread where its inclusion was first discussed:

https://www.mobileread.com/forums/sh...d.php?t=369497
Thanks for that, DiapDealer. Env Variables are not something I have had a need for so I missed that thread.

Quote:
Originally Posted by BeckyEbook View Post
Use the Force plugin, Luke.
Thanks also to Becky for the plugin. That saves a load of effort.
philja is offline   Reply With Quote
Old 12-12-2025, 09:37 AM   #15
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,970
Karma: 208569852
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
There are a few (mostly Qt-related) variables that are not set soon enough when using env-vars.txt via Sigil, but not very many. And of course our own SIGIL_PREFS_DIR variable cannot be set using env-vars.txt (since the prefs directory needs to be known before env-vars.txt can be processed). Most work just fine, though.
DiapDealer is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Why drag and drop stopped working fartang Library Management 23 12-23-2024 09:41 AM
Drag & Drop stopped working Iskariot Calibre 1 03-06-2016 06:27 AM
Drag and Drop not working anymore pietro Calibre 0 08-15-2014 01:21 PM
Drag and drop to add books not working. Stumbl Library Management 6 02-16-2011 09:31 PM
Drag and Drop not working mazzeltjes Calibre 2 01-15-2009 06:32 PM


All times are GMT -4. The time now is 05:20 PM.


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