Commit c5efc361 authored by KirillovIlya's avatar KirillovIlya

Fixed bug #31921. Исправлен баг с расстоянием между строк AtLeast.

parent 5434c199
......@@ -2260,14 +2260,15 @@ CParaLineMetrics.prototype =
}
case linerule_AtLeast:
{
var LineGap1 = ParaPr.Spacing.Line;
var LineGap2 = TextAscent + TextDescent;
var TargetLineGap = ParaPr.Spacing.Line;
var TextLineGap = TextAscent + TextDescent;
var RealLineGap = this.Ascent + this.Descent;
// Специальный случай, когда в строке нет никакого текста
if ( Math.abs( LineGap2 ) < 0.001 )
if (Math.abs(TextLineGap) < 0.001 || RealLineGap >= TargetLineGap)
LineGap = 0;
else
LineGap = Math.max( LineGap1, LineGap2 ) - ( TextAscent + TextDescent );
LineGap = TargetLineGap - RealLineGap;
break;
}
......
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