GNOME Bugzilla – Bug 323730
Alt+Num shortcut to switch tab to become Ctrl+Shift+Page[Up|Down]
Last modified: 2006-01-03 13:54:34 UTC
GTK+'s shortcut for changing tabs in a GtkNotebook is Ctrl+PageUp or Ctrl+PageDown. However, these shortcuts are reserved for moving the cursor to the beginning/end of a paragraph. Fine. But how about making the tab-switching Ctrl+Shift+PageUp or Ctrl+Shift+PageDown. I've seen GTK+ terminals that do this to allow the others to be used my any apps. It seems to be to be closer and more intuitive.
well, we ctrl+alt+pgUp/pgDown already does that. Is there a strong reason to make that ctrl+shfit?
Well, seeing that all the shortcuts in the menus go from Ctrl+Foo to Ctrl+Shift+Foo (e.g. Save and Save As), it would make more sense to me. If it were Ctrl+Shift, I would not have even gotten to this point; I didn't think to try Ctrl+Alt at all. (There is only one Ctrl+Alt shortcut that I can see in the menus, but many Ctrl+Shift ones.)
*** Bug 323974 has been marked as a duplicate of this bug. ***
Note that Ctrl+Shit+PageUp/PageDow are used by GtkTextView to move the cursor to beginning/end of a paragraph selecting the text from the begining/end of the paragraph to the current cursor position. Ctrl+Alt+PgUp/PgDown is the default keybining used by gtk+ in this case. Closing as NOTABUG.
I dont understand why bug 323974 is a dupe of this one? Bug 323974 isn't about a specific keyboard shortcut but about having gedit and gnome-terminal to use the same shortcut for shifting between tabs - for consistensy.
(In reply to comment #4) > Ctrl+Alt+PgUp/PgDown is the default keybining used by gtk+ in this case. You mean gedit, right? GTK+'s default, as already mentioned, is Ctrl+PageUp/PageDn. (In reply to comment #5) > I dont understand why bug 323974 is a dupe of this one? > > Bug 323974 isn't about a specific keyboard shortcut but about having gedit and > gnome-terminal to use the same shortcut for shifting between tabs - for > consistensy. One could argue that this is what I'm saying too. In fact, I would agree with the reporter of that bug. The fact that gedit's shortcuts override the GTK+ default (not just gnome-terminal's) of using Ctrl+PageUp/Dn to switch tabs is a big usability no-no, IMO. Overriding the GTK+ default seems like it should only be done if it's really necessary.
No, I mean Ctrl+Alt+PageUp/PageDn are GTK+'s default when a tab contains a GtkTextView, so gedit is _not_ overriding the GTK+ default. If you don't trust me read the following code in gtk_notebook_class_init (http://cvs.gnome.org/viewcvs/gtk%2B/gtk/gtknotebook.c?view=markup) gtk_binding_entry_add_signal (binding_set, GDK_Page_Up, GDK_CONTROL_MASK, "change_current_page", 1, G_TYPE_INT, -1); gtk_binding_entry_add_signal (binding_set, GDK_Page_Down, GDK_CONTROL_MASK, "change_current_page", 1, G_TYPE_INT, 1); gtk_binding_entry_add_signal (binding_set, GDK_Page_Up, GDK_CONTROL_MASK | GDK_MOD1_MASK, "change_current_page", 1, G_TYPE_INT, -1); gtk_binding_entry_add_signal (binding_set, GDK_Page_Down, GDK_CONTROL_MASK | GDK_MOD1_MASK, "change_current_page", 1, G_TYPE_INT, 1); I agree that the fact gedit and gnome-terminal use different shortcut for moving between tabs is not very good. But, as I already said, gedit cannot use such binding since it is already used by GtkTextView and so the alternative one is used. At the same time, it seems gnome-terminal is using the alternative Ctrl+Alt+PageUp/PageDown keybinding to add an escape sequence. BTW, I have just checked on by Ubuntu Breezy and gnome-terminal is not using Ctrl+Shift+PageUp/PageDown, but simply Ctrl+PageUp/PageDown that is the other default binding to shift between tabs.
(In reply to comment #7) > No, I mean Ctrl+Alt+PageUp/PageDn are GTK+'s default when a tab contains a > GtkTextView, so gedit is _not_ overriding the GTK+ default. Ah, OK. So it's GTK+'s fault. :P > I agree that the fact gedit and gnome-terminal use different shortcut for > moving between tabs is not very good. > > But, as I already said, gedit cannot use such binding since it is already used > by GtkTextView and so the alternative one is used. I guess that's hard to avoid, since the notebook and textview aren't necessarily used together all that often. I'm kinda out of ideas as to what else would work. I guess that's why it is the way it is. :)