Changing default in QToolBar::buttonStyle
Kevin Ottens
ervin+bluesystems at kde.org
Tue Aug 13 05:59:27 UTC 2013
On Monday 12 August 2013 18:06:41 Àlex Fiestas wrote:
> Hi there
>
> One of the tasks that I'm working on is "Make QToolBar use KDE settings",
> which include the buttonStyle.
>
> For those that don't know, the buttonStyle is whether the QToolButton
> created by QToolBar will have text along side, bottom, only text or no text
> at all.
>
> While Qt is prepared to update this based on the loaded QStyle, it will only
> do that if QToolBar::toolButtonStyle is set to Qt::ToolButtonFollowStyle
> which is not the default (Qt::ToolButtonIconOnly is).
>
> At first I thought on making this configurable somehow within Qt, or even
> updating/forcing it within our QPT (which is perfectly possible), but after
> seeing what the outcome is, I have discarded it:
>
> Some of the most common Qt only application with the setting changed:
>
> http://wstaw.org/m/2013/08/12/smplayer-style.png
> http://wstaw.org/m/2013/08/12/smplayer-icons.png
>
> http://wstaw.org/m/2013/08/12/scribus-style.png
> http://wstaw.org/m/2013/08/12/scribus-icons1.png
>
> http://wstaw.org/m/2013/08/12/qgit-style1.png
> http://wstaw.org/m/2013/08/12/qgit-icons.png
>
> http://wstaw.org/m/2013/08/12/designer-style.png
> http://wstaw.org/m/2013/08/12/designer-icons2.png
>
> As you can see, they completely break if we change the default :/
Now that I see it my reaction is "duh of course..."
> Since what we want is to offer QToolBar as an alternative to KToolBar for
> our app developers that don't want XMLGui we can do the following:
>
> 1-Modify Qt documentation to show Qt::ToolButtonFollowStyle in QToolBar and
> QMainWindow documentation
> 2-Update Qt example:
> http://qt-project.org/doc/qt-5.1/qtwidgets/mainwindows-application.html
> 3-Add information in KDE5PORTING ?
>
> What do you think?
I would say: go for it.
We obviously can't enforce the default like that, so let's make it better
documented all around.
Regards.
--
Kévin Ottens, http://ervin.ipsquad.net
Sponsored by BlueSystems and KDAB to work on KDE Frameworks
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20130813/8c4c62cd/attachment.sig>
More information about the Kde-frameworks-devel
mailing list