octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #53276] GUI: undocked panes cannot be moved, o


From: Dan Sebald
Subject: [Octave-bug-tracker] [bug #53276] GUI: undocked panes cannot be moved, or resized along upper border
Date: Wed, 4 Apr 2018 17:56:58 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:55.0) Gecko/20100101 Firefox/55.0

Follow-up Comment #77, bug #53276 (project octave):

@Rik: If you have a little bit of time, perhaps you could experiment with the
toplevel windows trying to get the full decorations on your version of KDE. 
The code where this takes place is very short.  It's this hunk from
octave_dock_widget.cc:


  // make the widget floating
  void
  octave_dock_widget::make_window (bool)
  {
    // prevent follow-up calls by clearing state variable
    m_waiting_for_mouse_button_release = false;

    // the widget has to be reparented (parent = 0), preferably
    // from a non-toplevel widget otherwise may not have full
    // decorations, e.g., no taskbar icon and always in front
    setFloating (false);
// Remove after thorough testing 3/20/18    m_parent->removeDockWidget
(this);
    setParent (0, Qt::Window | Qt::CustomizeWindowHint | Qt::WindowTitleHint
|
               Qt::WindowMinMaxButtonsHint | Qt::WindowCloseButtonHint);


It's surprisingly tricky code.  That routine should be executed whenever there
is a float-button-press, double-click-on-title-bar or
drag-panel-outside-GUI-window.  Use a debugger, or put some comments in like


std::cerr << "parent: " << parent() << "\n";


before (should be non-zero parent) and after the setParent(0) to make sure
that the window's parent is in fact 0 after, etc.  You might try putting that
step back in that explicitly removes the widget from the QMainWindow.  The
issue I was coming across originally is that without doing that
setFloating(false) first the conversion was from a floated QDockWidget to a
floated toplevel window and all that happened was a parent change, no
decorations change...just like you are currently seeing.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?53276>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]