Solved How can we disable Moving QWidget/QDialog from Title-bar?
-
I wanted to lock window from moving. Are there some kind of flag to disable moving?
-
Hi
There is no such flag, but you can remove the caption
with Qt::FramelessWindowHint.That said, can you explain a bit why you want such window
as if used as a main window, it would violate most user interface guidelines
and for me personally its an instant kill and uninstall.However, your use case might be special so a bit more information of the overall goal
would make it easier to suggest a good solution. -
Thanku @mrjj
I have solved the issue by usingbool nativeEvent(const QByteArray &eventType, void *message, long *result)
. I need this because i need to lock closing and movement of multiple opened windows. And user can enable and disable this feature. -
@TobbY
ok like a grid manager of sorts. fair enough :) -
@TobbY I know this topic is very old but I am facing the same issue and I would like to know how exactly you did that