This fixes various problems I've run into while trying to use Fusion 360 in wine.
- stacking issues in unmanaged mode
- I also attempted to apply the same fix for managed mode, but it looks difficult to do this in a way that plays well with window managers; I think it's best left up to them to keep override_redirect windows at the top of the stack)
- when the window manager sets our state to withdrawn, tell the window that it's been minimized, since the semantics are very similar
- the last one is a hack because I don't really know what to do about it, when clicking on the floating popups, they gain focus, which causes wine to incorrectly make them managed and that breaks everything
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2343
Today, test_TxGetNaturalSize() creates a pop-up window with a fixed size
(extent) of 100 x 100. The test function then proceeds to compute the
natural size of rich edit control that fits the sample text
"TestSomeText" and compare it to the RECT calculated by DrawText.
It appears that this test fails if the text width exceeds the width of
the test window's client area. In this case, DrawText() with
DT_WORDBREAK breaks the text into the two lines due to text wrapping;
however, Rich Edit's ITextServices::TxGetNaturalSize implementation does
not seem to perform text wrapping on overflow. This results in extent
mismatch.
In conclusion, the test may fail if the rendered width of the sample
text "TestSomeText" is larger than what the test expects. This depends
on the current font used for DEFAULT_GUI_FONT.
Fix this by omitting the DT_WORDBREAK flag for the DrawText() call in
_check_txgetnaturalsize().
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=54637
--
v2: riched20/tests: Don't specify DT_WORDBREAK in _check_txgetnaturalsize().
https://gitlab.winehq.org/wine/wine/-/merge_requests/2335
Today, test_TxGetNaturalSize() creates a pop-up window with a fixed size
(extent) of 100 x 100. The test function then proceeds to compute the
natural size of rich edit control that fits the sample text
"TestSomeText" and compare it to the RECT calculated by DrawText.
It appears that this test fails if the text width exceeds the width of
the test window's client area. In this case, DrawText() with
DT_WORDBREAK breaks the text into the two lines due to text wrapping;
however, Rich Edit's ITextServices::TxGetNaturalSize implementation does
not seem to perform text wrapping on overflow. This results in extent
mismatch.
In conclusion, the test may fail if the rendered width of the sample
text "TestSomeText" is larger than what the test expects. This depends
on the current font used for DEFAULT_GUI_FONT.
Fix this by omitting the DT_WORDBREAK flag for the DrawText() call in
_check_txgetnaturalsize().
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=54637
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2335