keepassxreboot / keepassxc

KeePassXC is a cross-platform community-driven port of the Windows application “Keepass Password Safe”.
https://keepassxc.org/
Other
21.39k stars 1.48k forks source link

Hitting Escape in a database pw entry closes the database #11199

Open RJVB opened 2 months ago

RJVB commented 2 months ago

Overview

Hitting escape when a database PW entry widget has the focus/input causes the database to be closed.

Steps to Reproduce

  1. Open one or more databases
  2. click in the PW (or key file) entry widgets
  3. hit the Escape key

Expected Behaviour

Nothing happens, or the entry gets cleared, or the focus is relinquished, anything but what happens now.

Actual Behaviour

The database is closed.

Context

This is confusing as the DB unlock screen looks way too similar between different databases. If you have multiple open that all live in the same directory (so the full paths shown in small font under Unlock KeePassXC Database are hard to tell apart) you can end up trying to "break in" into one of your own DBs, or you end up making modifications to the wrong one.

KeePassXC - 2.7.6 Revision: 9e119230

Operating System: Linux Desktop Env: KDE Windowing System: X11

PS: on a similar note, it can be confusing too that Ctrl-W closes the DB and not the window; a shortcut manager feature would be really welcome!

droidmonkey commented 2 months ago

Ctrl+W is the common shortcut to close a tab, Ctrl+Q is the common shortcut to quit the application. I agree the ESC key is too easy to smack and there is no question as to user intent.

This PR may help you with distinguishing between your databases: https://github.com/keepassxreboot/keepassxc/pull/10819

RJVB commented 2 months ago

On Monday August 26 2024 05:24:15 Jonathan White wrote:

Ctrl+W is the common shortcut to close a tab

It's also the common shortcut to close a window, which gets confusing if you're used to having applications that "close to the systray". The Ctrl-Shift-M shortcut for hiding isn't intuitive for me, but the main underlying argument is that things like shortcuts are personal (and the more so the longer you've been in computing; I still use F1/F2 for window front/back and F5 for iconify because that's what I "grew up" with).

,I agree the ESC key is too easy to smack and there is no question as to user intent.

No question what the intent is most likely NOT, indeed :)

This PR may help you with distinguishing between your databases: https://github.com/keepassxreboot/keepassxc/pull/10819

Thanks, I left a few observations. Can't say I liked the mock-ups shown but it would do the trick.

Still wouldn't work entirely in my situation though: I have a local copy of my DB and one on a NAS, with both open in the application. So the only distinguishing feature is the path, and even I have no brilliant ideas on how to improve discrimination here... other than maybe an indication if the DB is on a local or on a remote drive. There are ways to determine that (IIRC the Solid framework provides them).

WinnetouL commented 2 months ago

Hey @RJVB, just for my understanding. You open your database, then you click on any entry of the listed entries, so that it has the focus and the corresponding details appear at the bottom. And then you hit ESC and the database closes, so you have to unlock it again? Did I got that correctly?

RJVB commented 2 months ago

No. After that sequence of actions hitting Esc has no effect that I can see.

I meant just opening the DB file, or the KP window with one or more DB files opened but locked. Put the cursor in/focus on the password entry widget and then hitting Esc will close the file/tab. IMHO the only thing it should do is clear the entry widget, and possibly remove focus from it.

WinnetouL commented 2 months ago

ahh thanks I see!