Valentina stops accepting input on defocus - Gentoo Linux/KDE/KWin

Issue #303 resolved
Susan Spencer created an issue

Defocusing when a tool window is open makes Valentina stop accepting inputs

This is Valentina 0.3.1 on Gentoo Linux (running ~amd64, freshly updated), built with Qt 5.4.1, running under KDE 4 with KWin 4.11.17 or 4.11.19 on the standard server version 1.17.1. KWin acts as compositor, with OpenGL support from the built-in GPU in the Core i7-2640M CPU. KWin is configured with click-to-focus policy.

  1. Start Valentina.
  2. Click the "Add a new pattern piece" button.
  3. In the "Measurements" window, choose "Use for creation pattern standard measurement table".
  4. When the "Standard table" window appears, move focus away from Valentina (by clicking the desktop background, clicking another window or alt-tabbing).
  5. The "Standard table" window disappears, and the main window no longer accepts any input, not even closing the window. To kill it, run "killall valentina" from a shell.

This also happens with other tool windows, e.g.: 1. Create a new pattern piece. 2. Click the "Point at distance and angle" button. 3. Click the default point, "A". 4. Click anywhere on the canvas. 5. The "Point at distance and angle" window appears. 6. Move focus away from Valentina. The "Point at distance and angle" window disappears, and the main window no longer accepts any input.

No output appears in the shell where Valentina was started, but after the bug manifests, every click on the unresponsive main Valentina window results in two identical lines appearing in ~/.xsession-errors:

kwin(2136) KWin::Workspace::takeActivity: takeActivity: not shown kwin(2136) KWin::Workspace::takeActivity: takeActivity: not shown

One strange detail is that "xlsclients -al", which shows all my other open windows, never lists Valentina, neither before nor after the bug manifests

Comments (11)

  1. Susan Spencer reporter

    I followed the steps above to move focus away from Valentina and did not encounter any input problems. I'm using Ubuntu 14.04 64bit.

    This may be a problem with Gentoo's KDE/KWin window manager. Ubuntu uses Unity. Arch uses LXDE.

    KWin apparently has problems working with Mesa9 & 10 (mesa 8 is the latest version it can work with), problems with Intel graphics cards, some people have to disable 'Desktop effects' to keep java-based programs from hanging, and other seemingly random issues with KWin.

    Similar to this issue?

    Related to this issue?

  2. Roman Telezhynskyi repo owner

    I still think it is not our bug. We should have section "Known problems" in WIKI.

  3. Susan Spencer reporter

    Here is the user's input, after digging a bit into kwin:

    "So I did a little more digging, and it seems that this is indeed a KWin bug. It seems Valentina was first to hit it since it's the first application I've ever seen that has created a modal tool window.

    See for the bug report.

    Until that's been fixed, making the window normal by removing the line

    this->setWindowFlags(Qt::Tool | Qt::WindowTitleHint | Qt::WindowCloseButtonHint | Qt::CustomizeWindowHint);

    from the function

    src/app/dialogs/app/dialogstandardmeasurements.cpp: DialogStandardMeasurements::DialogStandardMeasurements()

    makes the problem go away. Unsetting "Hide utility windows for inactive applications" in KWin also works.

  4. Log in to comment