Re: ctrl+tab switching



After having used it for a couple of days, I'm happy to report that it works well. (binds in ui/notebook.py & unbinds in resources/meld.css)
Thank you!

These shortcuts are mightily useful IMO... any chances an MR with these changes would get accepted?

cheers
Donjan


On 29.08.20 01:41, Kai wrote:
On Fri, 28 Aug 2020 at 19:40, Donjan Rodic <drodic phys ethz ch> wrote:
Now I'm not sure if the "next pane" concept refers to just that,
switching between left and right. Or if it actually should cycle through
the tabs that appear in the top row, which is what I want, as outlined
in the original post. That would be "notebook page" concept relevant to
the "notebook.set_current_page()" code, e.g. tabbing through 20
comparisons opened from a directory diff view.

Sorry, I misread the original post. You're right, and pane switching is not what you want.
 
I'm simply searching for a way to bind the Ctrl+Tab accelerator to
something like this pseudocode:

     notebook.set_current_page(get_current_page()+1)  # respectively -1

If you add

          bind "<Primary>Tab" { "change-current-page" (1) };
          bind "<Primary><Shift>Tab" { "change-current-page" (-1) };
to the CSS in notebook.py, the accelerators will mostly work, provided that focus is on a child of the notebook. You'll also need the CSS unbind. For me there appears to still be something catching Ctrl+Tab when the notebook isn't in the focus chain.

cheers,
Kai



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]