Summary: | Create a new partition: Wrong tab order if LUKS encryption is enabled | ||
---|---|---|---|
Product: | [Applications] partitionmanager | Reporter: | LaughingMan <lingm+kdebugs> |
Component: | general | Assignee: | Andrius Štikonas <andrius> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | kevin.kofler |
Priority: | NOR | ||
Version First Reported In: | 24.08.2 | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/system/partitionmanager/-/commit/81fc2370b8121dfe886e516443c72000de81e888 | Version Fixed In: | |
Sentry Crash Report: |
Description
LaughingMan
2024-10-11 17:08:09 UTC
Git commit 81fc2370b8121dfe886e516443c72000de81e888 by Andrius Štikonas. Committed on 11/10/2024 at 21:08. Pushed by stikonas into branch 'master'. Improve tab order in partition create dialog. Unfortunately, there doesn't seem to be an easy way to change tab order of KNewPasswordWidget. M +20 -17 src/gui/sizedialogwidgetbase.ui https://invent.kde.org/system/partitionmanager/-/commit/81fc2370b8121dfe886e516443c72000de81e888 "Unfortunately, there doesn't seem to be an easy way to change tab order of KNewPasswordWidget." Does that mean the tab order for the password field will still be wrong? :/ That's really the one I cared about more. Only noticed that the checkbox also has the wrong order while filing this report. Originally I tried to tab to the next text box after typing my password. (In reply to LaughingMan from comment #2) > "Unfortunately, there doesn't seem to be an easy way to change tab order of > KNewPasswordWidget." > > Does that mean the tab order for the password field will still be wrong? :/ > > That's really the one I cared about more. Only noticed that the checkbox > also has the wrong order while filing this report. Originally I tried to tab > to the next text box after typing my password. Unfortunately yes, but I don't see any way to specify tab order for it. Qt designer didn't have any option to set order on it. I then tried to hack around .ui file manually, by adding tabstop there but it still didn't work (perhaps unsurprisingly). Have you tried setting it programmatically from the code using QWidget::setTabOrder (https://doc.qt.io/qt-6/qwidget.html#setTabOrder)? If that does not work, you can try to use QObject introspection to get the KPasswordLineEdit embedded in the KNewPasswordWidget: KPasswordLineEdit *passwordLineEdit = m_EditPassphrase->findChild<KPasswordLineEdit *>(QString(), Qt::FindDirectChildrenOnly); and then playing around with that, maybe: m_EditPassphrase->setFocusProxy(passwordLineEdit); setTabOrder(…, m_EditPassphrase); // now that it has a valid focus proxy set I also think this needs to be reported against KNewPasswordWidget. All widgets ought to support setting the tab order. (In reply to Kevin Kofler from comment #4) > Have you tried setting it programmatically from the code using > QWidget::setTabOrder (https://doc.qt.io/qt-6/qwidget.html#setTabOrder)? > > If that does not work, you can try to use QObject introspection to get the > KPasswordLineEdit embedded in the KNewPasswordWidget: > KPasswordLineEdit *passwordLineEdit = > m_EditPassphrase->findChild<KPasswordLineEdit *>(QString(), > Qt::FindDirectChildrenOnly); > and then playing around with that, maybe: > m_EditPassphrase->setFocusProxy(passwordLineEdit); > setTabOrder(…, m_EditPassphrase); // now that it has a valid focus proxy set > > I also think this needs to be reported against KNewPasswordWidget. All > widgets ought to support setting the tab order. Yeah, I agree. I'll open a bug against KNewPasswordWidget a bit later. Widgetsaddons bug: https://bugs.kde.org/show_bug.cgi?id=494624 Kevin, I think I tried setting QWidget::setTabOrder yesterday if I remember correctly and it didn't work. I have not tried to use QObject introspection yet, but let's see if #494624 gets some responses. |