https://bugs.winehq.org/show_bug.cgi?id=54637
Bug ID: 54637 Summary: riched20:txtsrv - test_TxGetNaturalSize fails if system GUI font's glyph widths are wider than expected by the test Product: Wine Version: 8.3 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: richedit Assignee: wine-bugs@winehq.org Reporter: jinoh.kang.kr@gmail.com CC: huw@codeweavers.com, jzeng@codeweavers.com Regression SHA1: 6e264bbd1ddf0d271d4506462ecd4f20f4a20597 Distribution: ---
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.
Omitting DT_WORDWRAP for the DrawText() call seems to fix this test failure.
https://bugs.winehq.org/show_bug.cgi?id=54637
Jinoh Kang jinoh.kang.kr@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |regression, source, | |testcase
https://bugs.winehq.org/show_bug.cgi?id=54637
Jinoh Kang jinoh.kang.kr@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |f54a1dac64c89aea3fe02ae8c0d | |6eef43a0aa117 Resolution|--- |FIXED Status|UNCONFIRMED |RESOLVED
--- Comment #1 from Jinoh Kang jinoh.kang.kr@gmail.com --- Fix committed.
https://bugs.winehq.org/show_bug.cgi?id=54637
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #2 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 8.4.