Kaydet (Commit) 565340d4 authored tarafından Matteo Casalin's avatar Matteo Casalin

Fix tdf#100937: LO Freezed when I insert a very long text in...

... the Description box

The issue was triggered by ImpVclMEdit::Resize initially calling
TextEngine::SetMaxTextWidth() with a negative width (due to an initial
empty area, further "reduced" to take into account a vertical scroll
bar) and then with positive values in following iterations.
I preferred to consider such negative widths a no-op instead of
extending them to the "maximum" possible width.

Change-Id: I756652a30c23ebe6674e481e7d8d6e0d8ba45e75
üst 91b5e86d
......@@ -219,7 +219,7 @@ void TextEngine::SetMaxTextLen( sal_Int32 nLen )
void TextEngine::SetMaxTextWidth( long nMaxWidth )
{
if ( nMaxWidth != mnMaxTextWidth )
if ( nMaxWidth>=0 && nMaxWidth != mnMaxTextWidth )
{
mnMaxTextWidth = nMaxWidth;
FormatFullDoc();
......
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