Review Request 127424: KCompletionBox popup gets full window decoration on Windows

Kai Uwe Broulik kde at privat.broulik.de
Sat Mar 19 20:56:21 UTC 2016



> On März 19, 2016, 1:22 nachm., Thomas Lübking wrote:
> > "Loose focus" is the complete wrong concept anyway.
> > It makes kickoff and various other plasmashell elements barely usable w/ any but the click-to-focus policy (implicit hide)
> > 
> > Try adding Qt::FramelessWindowHint (Qt::X11BypassWindowManagerHint should be Qt::BypassWindowManagerHint anyway)
> > 
> > PS: it's rather worrysome that Qt::Popup fails since it *is* set for the QComboBox dropdown. May point an implementation weakeness/bug in this class.
> 
> Dominik Haumann wrote:
>     Unfortunatey, also does not work... The popup stays, does not close, and typing does not insert text into the KLineEdit anymore (we don't see any blinking cursor).
> 
> Thomas Lübking wrote:
>     i did not mean "alongside Qt::Popup" - if you need to hint this as tooltip for somewhat useful behavior, either the class or QWidget/5 is seriously fucked up.
> 
> Dominik Haumann wrote:
>     ...I'm not sure what you are suggesting: Fact is, right now, we don't have another fix than reverting to the original code.
>     It would also work to add a #ifdef, but given that temporary workarounds tend to become pernanent ones, this is probably the worst solution.
>     
>     So what is the proper fix / approach we can take here?
> 
> Anthony Fieroni wrote:
>     http://doc.qt.io/qt-5/qt.html#WindowType-enum
>     q->setWindowFlags(Qt::ToolTip | Qt::BypassWindowManagerHint | Qt::FramelessWindowHint);
>     or 
>     q->activateWindow();
>     *(i.e., no keyboard input unless you call QWidget::activateWindow() manually).*
> 
> Anthony Fieroni wrote:
>     I mean Window :)
>     q->setWindowFlags(Qt::Window | Qt::BypassWindowManagerHint | Qt::FramelessWindowHint);
> 
> Dominik Haumann wrote:
>     Just tested
>     
>         q->setWindowFlags(Qt::Window | Qt::BypassWindowManagerHint | Qt::FramelessWindowHint);
>     
>     Does not work either: We get no window decoration, which is good, but KLineEdit looses focus (no blinking cursor, no new typed text), and it is hard to make the popup disappear again.
>     
>     Maybe this is a bug in the implementation of KCompletionBox and/or KLineEditor. Fact is, though, that it at least worked for applications before.
>     
>     I could not find a call of activateWindow()...

Does Qt::WindowDoesNotAcceptFocus help?


- Kai Uwe


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/127424/#review93716
-----------------------------------------------------------


On März 19, 2016, 8:56 nachm., Dominik Haumann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/127424/
> -----------------------------------------------------------
> 
> (Updated März 19, 2016, 8:56 nachm.)
> 
> 
> Review request for KDE Frameworks, kdewin, kwin, and Marco Martin.
> 
> 
> Repository: kcompletion
> 
> 
> Description
> -------
> 
> In https://git.reviewboard.kde.org/r/127191/ the KCompletionBox WindowFlags were change from Qt::ToolTip to Qt::Window.
> 
> As consequence, the completion popup of the Kate command line gets a full window decoration, which is obviously wrong, see attached screenshot.
> 
> Changing the type to Qt::Popup shows the proper popup, but key presses are not forwarded, so typing is not possible, and additionally, on losing focus the popup keeps staying open.
> Therefore, this patch reverts the type back to Qt::ToolTip.
> 
> Better fixes are of course welcome ;) Any ideas?
> 
> 
> Diffs
> -----
> 
>   src/kcompletionbox.cpp 005aff8 
> 
> Diff: https://git.reviewboard.kde.org/r/127424/diff/
> 
> 
> Testing
> -------
> 
> Works on Windows as expected.
> 
> 
> File Attachments
> ----------------
> 
> Completion Popup
>   https://git.reviewboard.kde.org/media/uploaded/files/2016/03/19/7be64cad-6d95-46b8-9caa-41b41a135ca1__kate2015.png
> 
> 
> Thanks,
> 
> Dominik Haumann
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-windows/attachments/20160319/ae377264/attachment.html>


More information about the Kde-windows mailing list