[PATCH] KDialog::groupSpacingHint()

Luciano Montanaro mikelima at gmail.com
Mon Oct 6 08:17:50 BST 2008

On Mon, Oct 6, 2008 at 8:48 AM, Parker Coates <parker.coates at gmail.com> wrote:
> Hello,
> The latest KDE HIG offers using a vertical space of 16 pixels as an
> additional method of grouping logically related items in a dialog. [1]
> Rather than have this 16 pixel value hardcoded in dozens of different
> dialogs, I propose adding a groupSpacingHint() method to the KDialog
> class. [2] This is a static method that returns a constant in the same
> vein as KDialog::marginHint() and KDialog::spacingHint().
> The attached patch adds such a method. Any comments?
> Parker

Having a method to get the spacing is good, since it is something that
should not be hardcoded
(think higher resolution displays or small devices). But wouldn't it
be better to be a property of the style?

In this way it would be possible to use smaller spaces on small
screen/small resolution displays, with a customized style.

Other than that, why is this size specified in pixels? I think the
font size should be involved in its calculation.

Can it be expressed in function of the x height of the "normal" font,
or the linespacing of the "normal" font?

Luciano Montanaro

Anyone who is capable of getting themselves made President should on
no account be allowed to do the job. -- Douglas Adams

More information about the kde-core-devel mailing list