[PyQt] Alignment Issue in QStatusbar

Maurizio Berti maurizio.berti at gmail.com
Fri May 17 22:19:03 BST 2019


Il giorno ven 17 mag 2019 alle ore 04:25 Tong Zhang <warriorlance at gmail.com>
ha scritto:

> Hello,
>
> I'm trying to create add widgets into QStatusbar, as the attached
> screenshot shows, the first widget, which is a qtoolbutton and the second
> widget, which is a qlabel, is not aligned well. I want them vertically
> center aligned,  could somebody give me some hint? Thanks very much!
>

>From your code everything seems fine, but you should provide a minimal,
correct and reproducible example to better understand what might be going
on (my experience shows that what usually happens is that, once you
"reduce" the code for the example, you often find what actually is wrong by
yourself); it's also better to specify the environment you are running from
(Operating System, Python and Qt versions).

I tested it on Linux and Windows (through wine, though). From the look of
the attached screenshot it seems you might be running on Windows 10, and
unfortunately I cannot accurately test on that platform.

It could be a bug, but also it might depend on what you did with the
QStatusBar and the QToolButton (I can see an icon and a menu set, but maybe
you changed something else too).

Cheers,
Maurizio

-- 
È difficile avere una convinzione precisa quando si parla delle ragioni del
cuore. - "Sostiene Pereira", Antonio Tabucchi
http://www.jidesk.net
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20190517/2e763c69/attachment.html>


More information about the PyQt mailing list