Skip to content

Assorted layout fixes for the Preferences dialog

Hi,

This MR proposes several visual enhancements to the Preferences dialog, centered around:

  • the usage of form widgets, replacing the bespoke nested layouts and thus allowing automatic labeling of widgets
  • the usage of a new general pattern, KisWarningBlock, for rendering user warnings/information blocks
  • the usage of "comment" labels for the various instances of "needs restart" across the dialog

As part of this change, I've also applied a general replacement in .ui files, so that our spinboxes are considered as their real base class (Q(Double)SpinBox) instead of a QWidget when rendered in Qt Designer.

There's an additional, actual bugfix to the default tab in the General pane that was introduced in !1658 (merged). It mistakenly changed th default tab to the last instead of the first, possibly because the .ui was edited in Designer.

Before After
before_1 after_1
before_2 after_2
before_3 after_3
before_4 after_4
before_5 after_5 after_6
before_7 after_7
before_8 after_8

Test Plan

Build Krita and check that the warnings of "HDR Settings", "Resources", and "Canvas acceleration" are still rendered in their appropriate context. The rest of the widgets haven't been changed logically.

Formalities Checklist

  • I confirmed this builds.
  • I confirmed Krita ran and the relevant functions work.
  • I tested the relevant unit tests and can confirm they are not broken. (If not possible, don't hesitate to ask for help!)
  • I made sure my commits build individually and have good descriptions as per KDE guidelines.
  • I made sure my code conforms to the standards set in the HACKING file.
  • I can confirm the code is licensed and attributed appropriately, and that unattributed code is mine, as per KDE Licensing Policy.

Reminder: the reviewer is responsible for merging the patch, this is to ensure at the least two people can build the patch. In case a patch breaks the build, both the author and the reviewer should be contacted to fix the build. If this is not possible, the commits shall be reverted, and a notification with the reasoning and any relevant logs shall be sent to the mailing list, kimageshop@kde.org.

Merge request reports

Loading