Hi,
While working on my personal shortcut system in darktable, I noticed that I could not assign a shortcut to the button in the snapshots module to show image and snapshot side by side. Have I missed something, is this intentional or should I report a bug?
DT 5.3.0-git857 from OBS, on Linux Mint.
I searched for this to. Not there. You can assign the action to āshow/toggle on the last snapshotā.
So I activate the side by side button manually , without activating a snapshot. Then use the shortcut to do what you ask. Just keep the side side button turned on.
Best wishes.
Yes, thatās certainly possible, but it only brings us half way there. And as long as most buttons can have shortcuts, why not all of them? Maybe @dterrahe, who made the button can chime in?
That just needs a
dt_action_define(DT_ACTION(self), NULL,
N_("side-by-side"), d->sidebyside_button, &dt_action_def_toggle);
As a non programmer I feel very much lost now⦠![]()
I guess one may add this somewhere in the code, build a new dt and test?
Would love to learn to do this, by the way.
Maybe not even to perform this myself but at least to better understand what you programmers are doing!
Kind regards, Jetze
Letās just hope @dterrahe does the magic and wait for the resultš
Yep. One would do this immediately after sidebyside_button was created.
I could easily submit this change to the codebase. But these are also the simple changes that a newcomer might have a look at. Possibly there are other buttons that are currently not shortcuttable. So the āprojectā here would be to find similar situations and deal with all in one go.
Any takers?
Iāll start with a guess⦠around maybe just after line 871 in snapshots.c ??
If I have time I will try to test it laterā¦
Will at first try to find the code⦠would be a first for meā¦
Any time after 866 and before the end of the function.
Look at other uses of dt_action_define to get āa feel for itā. This is a relatively simple case of āif it works, you did it rightā. Of course there may still be a little bit of ātasteā in how to name actions. And if there are many of them in one module, one might want to group them in a section. Stuff like that. But that would all be reviewed once a (draft) PR is submitted.
And to be clear, Iām not saying there are any other instances like this to be found anymore. Maybe I took care of all of them in the past. But it would be a useful check to do.
I missed the āside by sideā part. Ignore me. ![]()
I could not assign a shortcut to this buttons.
DT: 5.3.0+882~g916b7e4c99




I tried awhile ago, and it seems the only one available for shortcuts is the āactiveā group (maybe the quick access one, but canāt remember for sure). I wanted to make a shortcut to my own personal groups.
