diff options
author | Tor Lillqvist <tml@collabora.com> | 2021-08-31 15:02:48 +0300 |
---|---|---|
committer | Szymon Kłos <szymon.klos@collabora.com> | 2021-10-01 15:02:23 +0200 |
commit | cf5b3a3359856bbd36e4bb52cdfa66179583a711 (patch) | |
tree | de0ef468bb44b2924b330977775b8cd9855faf31 /vcl | |
parent | b54d216bf5e0c46f51caa39a8d83737bf2f02909 (diff) |
Stopgap workaround for misspelling wavy underline drawing bug on iOS
Explicity make the rectangle white before drawing the red wavy line.
Sure, this means that it looks bad if the document background colour
is not white. Better than how it looks currently, though, with the
rectangle containing the wavy underline ending up (for unknown
reasons) black. And most documents have a white background.
Change-Id: I92b2246bbdbd1404e4c48292c3610d1582a56163
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121370
Tested-by: Tor Lillqvist <tml@collabora.com>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122906
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/outdev/textline.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/vcl/source/outdev/textline.cxx b/vcl/source/outdev/textline.cxx index 7b1ca2dede0b..48654a94cb6e 100644 --- a/vcl/source/outdev/textline.cxx +++ b/vcl/source/outdev/textline.cxx @@ -1080,6 +1080,11 @@ void OutputDevice::DrawWaveLine(const Point& rStartPos, const Point& rEndPos, to pVirtDev->SetOutputSizePixel( Size( nWordLength, nWaveHeight * 2 ), false ); pVirtDev->SetLineColor( GetLineColor() ); pVirtDev->SetBackground( Wallpaper( COL_TRANSPARENT ) ); +#ifdef IOS + // Stopgap workaround for some bug in the iOS-specific vcl code. + pVirtDev->SetFillColor( COL_WHITE ); + pVirtDev->DrawRect( tools::Rectangle( 0, 0, pVirtDev->GetOutputSize().Width(), pVirtDev->GetOutputSize().Height() ) ); +#endif pVirtDev->ImplDrawWaveLineBezier( 0, 0, nWordLength, 0, nWaveHeight, fOrientation, nLineWidth ); rLineCache.insert( pVirtDev->GetBitmapEx( Point( 0, 0 ), pVirtDev->GetOutputSize() ), GetLineColor(), nLineWidth, nWaveHeight, nWordLength, aWavylinebmp ); } |