Kaydet (Commit) c63324e0 authored tarafından Keith Curtis's avatar Keith Curtis Kaydeden (comit) Jan Holesovsky

hidpi: Nicer painting of the waved lines.

Change-Id: I8773b47967bc1aa8cf33b9a1edc4f826291d3554
üst c3bd4353
......@@ -5306,6 +5306,18 @@ void OutputDevice::DrawWaveLine( const Point& rStartPos, const Point& rEndPos,
nWaveHeight = 3;
nStartY++;
nEndY++;
if (mnDPIScaleFactor > 1)
{
nStartY++; //Shift down an additional pixel to create more visual separation.
nWaveHeight *= mnDPIScaleFactor;
//5 pixels looks better than 6.
if (mnDPIScaleFactor == 2 && nWaveHeight == 6)
{
nWaveHeight = 5;
}
}
}
else if( nStyle == WAVE_SMALL )
{
......@@ -5316,13 +5328,13 @@ void OutputDevice::DrawWaveLine( const Point& rStartPos, const Point& rEndPos,
else // WAVE_FLAT
nWaveHeight = 1;
// #109280# make sure the waveline does not exceed the descent to avoid paint problems
ImplFontEntry* pFontEntry = mpFontEntry;
if( nWaveHeight > pFontEntry->maMetric.mnWUnderlineSize )
nWaveHeight = pFontEntry->maMetric.mnWUnderlineSize;
// #109280# make sure the waveline does not exceed the descent to avoid paint problems
ImplFontEntry* pFontEntry = mpFontEntry;
if( nWaveHeight > pFontEntry->maMetric.mnWUnderlineSize )
nWaveHeight = pFontEntry->maMetric.mnWUnderlineSize;
ImplDrawWaveLine(nStartX, nStartY, 0, 0,
nEndX-nStartX, nWaveHeight * mnDPIScaleFactor,
nEndX-nStartX, nWaveHeight,
mnDPIScaleFactor, nOrientation, GetLineColor());
if( mpAlphaVDev )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment