[Ctk-developers] ctkSliderWidget on ctkPopUpWidget: spinbox never gets keyboard focus

Julien Finet julien.finet at kitware.com
Fri Nov 15 22:52:22 UTC 2013


Hi Miklos,

I've noticed that odd behavior but I haven't found the time to investigate
much further than what you already did.
My gut feeling is that it can't get focus because the popup window is not
"active" (only 1 window can be active at a time ?).
You might have to play with activateWindow() or something like that.

Hth,
Julien.



On Fri, Nov 15, 2013 at 12:28 PM, Miklos Espak <espakm at gmail.com> wrote:

> Hi,
>
> I have a drop down control panel with some slider widgets on it.
>
> If I click into the spinbox, it should get the keyboard focus and the
> cursor should start blinking, but it does not. I can select the number by
> mouse, but cannot type anything into it.
>
> If I place the control panel on an ordinary QWidget, all works fine.
>
> I added an event filter to the line edit of the spin box to see if it gets
> the mouse pressed event. It does. But it does not get the FocusIn event. If
> I put the control panel an a QWidget, then the ctkDoubleSpinBox gets the
> FocusIn event.
>
> Has anybody tried to use a ctkDoubleSpinBox or similar on a ctkPopUpWidget?
>
> Any idea, why there the no FocusIn event is not emitted / received if the
> spinbox is on a popup widget, even if the mouse press event definitely
> arrives to the line edit?
>
> Cheers,
> Miklos
>
>
> _______________________________________________
> Ctk-developers mailing list
> Ctk-developers at commontk.org
> http://public.kitware.com/cgi-bin/mailman/listinfo/ctk-developers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/ctk-developers/attachments/20131115/c3e85f3d/attachment.htm>


More information about the Ctk-developers mailing list