From 5be8445f112b6b652c4c54227e8efa0f6b64cdd1 Mon Sep 17 00:00:00 2001 From: Gatis Paeglis Date: Tue, 25 Jul 2017 11:33:04 +0200 Subject: [PATCH] doc: minor cleanup in QPlatformWindow::setGeometry() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch amends a4c8129. This is more consistent with other parts in QPlatformWindow docs. Change-Id: I26d7a91849f3fde3ab2a0f3c81e00a5f9c830707 Reviewed-by: Jesus Fernandez Reviewed-by: Tor Arne Vestbø --- src/gui/kernel/qplatformwindow.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/gui/kernel/qplatformwindow.cpp b/src/gui/kernel/qplatformwindow.cpp index 5ece421ea5..ae39411729 100644 --- a/src/gui/kernel/qplatformwindow.cpp +++ b/src/gui/kernel/qplatformwindow.cpp @@ -122,11 +122,12 @@ QSurfaceFormat QPlatformWindow::format() const implementation of this function in any override of QPlatformWindow::setGeometry(), as QWindow::geometry() is expected to report back the set geometry until a confirmation (or rejection) of the new geometry comes back from the window manager and is reported - via handleGeometryChange(). + via QWindowSystemInterface::handleGeometryChange(). Window move/resizes can also be triggered spontaneously by the window manager, or as a response to an earlier requested move/resize via the Qt APIs. There is no need to call - this function from the window manager callback, instead call QPA::handleGeometryChange. + this function from the window manager callback, instead call + QWindowSystemInterface::handleGeometryChange(). The position(x, y) part of the rect might be inclusive or exclusive of the window frame as returned by frameMargins(). You can detect this in the plugin by checking