Opened 11 years ago

Closed 11 years ago

#3909 closed Enhancement (fixed)

keyboard shortcut for "Add URL"

Reported by: cantabile Owned by: jordan
Priority: Normal Milestone: 2.20
Component: Qt Client Version: 2.13
Severity: Trivial Keywords:
Cc:

Description

Hi,

I would like to have keyboard short-cuts for "Add URL", "Preferences" and "Set location". Ctrl-U, Ctrl-Shift-P and Ctrl-L, respectively, are not currently used and they seem adequate. Attached are three patches which implement this.

Attachments (7)

shortcut-add-url.diff (407 bytes) - added by cantabile 11 years ago.
ctrl-u as shortcut for "add url"
shortcut-preferences.diff (424 bytes) - added by cantabile 11 years ago.
ctrl-shift-p as shortcut for "preferences"
shortcut-set-location.diff (427 bytes) - added by cantabile 11 years ago.
ctrl-l as shortcut for "set location"
shortcut-magnet.diff (426 bytes) - added by cantabile 11 years ago.
ctrl-m as shortcut for "copy magnet link to clipboard" - gtk client already has this
shortcut-verify.diff (412 bytes) - added by cantabile 11 years ago.
ctrl-v as shortcut for "verify local data" - gtk client already has this
shortcut-gtk-add-url.diff (1.0 KB) - added by cantabile 11 years ago.
in the gkt client: ctrl-u as shortcut for "add url"
shortcut-gtk-set-location.diff (1.1 KB) - added by cantabile 11 years ago.
in the gkt client: ctrl-l as shortcut for "set location"

Download all attachments as: .zip

Change History (16)

Changed 11 years ago by cantabile

ctrl-u as shortcut for "add url"

Changed 11 years ago by cantabile

ctrl-shift-p as shortcut for "preferences"

Changed 11 years ago by cantabile

ctrl-l as shortcut for "set location"

comment:3 in reply to: ↑ 1 ; follow-up: Changed 11 years ago by jordan

Replying to ijuxda:

Is there any reason why not to use alt-p for the preferences shortcut?

Transmission doesn't have a shortcut for the preferences dialog because the HIG's list of standard menu/shortcuts recommends not using one. Look at a sampling of GNOME applications -- conforming apps don't use a shortcut for the preferences dialog's menuitem.

comment:4 in reply to: ↑ 2 Changed 11 years ago by ijuxda

Replying to cantabile:

I don't really care for short-cuts using (only) Alt - in my opinion Alt should be reserved for &accelerators.

Point taken.

comment:5 in reply to: ↑ 3 ; follow-up: Changed 11 years ago by ijuxda

Replying to jordan:

Transmission doesn't have a shortcut for the preferences dialog because the HIG's list of standard menu/shortcuts recommends not using one. Look at a sampling of GNOME applications -- conforming apps don't use a shortcut for the preferences dialog's menuitem.

I thought this ticket was about the QT client. Does the gnome hig apply to QT applications?

comment:6 in reply to: ↑ 5 ; follow-up: Changed 11 years ago by jordan

Replying to ijuxda:

Replying to jordan:

Transmission doesn't have a shortcut for the preferences dialog because the HIG's list of standard menu/shortcuts recommends not using one. Look at a sampling of GNOME applications -- conforming apps don't use a shortcut for the preferences dialog's menuitem.

I thought this ticket was about the QT client. Does the gnome hig apply to QT applications?

The Qt and GTK+ versions of Transmission try to share the same shortcuts. Also, KDE applications don't have a shortcut for the options dialog, either.

comment:7 in reply to: ↑ 6 Changed 11 years ago by cantabile

Replying to jordan:

The Qt and GTK+ versions of Transmission try to share the same shortcuts.

I compared the short-cuts in the gtk and qt interfaces and made a few more patches to synchronise them. :) I'm not sure the two patches for the gtk interface belong here, though.

Changed 11 years ago by cantabile

ctrl-m as shortcut for "copy magnet link to clipboard" - gtk client already has this

Changed 11 years ago by cantabile

ctrl-v as shortcut for "verify local data" - gtk client already has this

Changed 11 years ago by cantabile

in the gkt client: ctrl-u as shortcut for "add url"

Changed 11 years ago by cantabile

in the gkt client: ctrl-l as shortcut for "set location"

comment:8 follow-up: Changed 11 years ago by jordan

Hm, transmission probably shouldn't be using Ctrl-M for anything -- isn't that a carriage return? :)

comment:9 in reply to: ↑ 8 Changed 11 years ago by cantabile

Replying to jordan:

Hm, transmission probably shouldn't be using Ctrl-M for anything -- isn't that a carriage return? :)

I didn't know that. In urxvt, xterm, the tty and gvim, ctrl-m has, apparently, the same effect as pressing enter. In other (gtk2 and qt) applications, it seems to have no effect, unless it's bound to an action (for example in galculator). The "other" apps were geany, medit, pyroom, kid3 and vanilla transmission-qt 2.13. :)

comment:10 Changed 11 years ago by jordan

  • Milestone changed from None Set to 2.20
  • Status changed from new to assigned
  • Summary changed from keyboard shortcuts for "Add URL", "Preferences" and "Set location" to keyboard shortcut for "Add URL"

Cantabile, thanks for your feedback and for the patches.

  • Preferences: I'm going to not add an accelerator for this, for the reasons listed above.
  • Location: This is more of a judgement call, since there's less guidance from the HIG and other applications. However my intuition is that "Set Location" is probably not called frequently enough to warrant its own accelerator.
  • Verify Local Data: Thanks for spotting this. synchronized between GTK+ and Qt for 2.20.
  • Open URL: Sounds good. added for 2.20.
  • Magnet Link: Ctrl-M was probably a bad choice. Rather than copying that bad choice to the Qt client, it should be removed from the GTK+ client. So the question becomes, does it need an accelerator at all? As with "Set Location," I suspect the answer is "no." Removed for 2.20.

I'm not sure how to mark 1/3 or 1/2 of a ticket as "fixed" and the rest as "wontfix" or "invalid", so instead I'll comment on it here, modify the summary, and mark the ticket as fixed.

comment:11 Changed 11 years ago by jordan

  • Resolution set to fixed
  • Status changed from assigned to closed
Note: See TracTickets for help on using tickets.