浏览代码

Merge pull request #232 from Unity-Technologies/fix_paragraph

Fix paragraph
/main
GitHub 3 年前
当前提交
a9fc2b47
共有 2 个文件被更改,包括 5 次插入5 次删除
  1. 8
      com.unity.uiwidgets/Runtime/ui/text.cs
  2. 2
      com.unity.uiwidgets/Runtime/widgets/widget_span.cs

8
com.unity.uiwidgets/Runtime/ui/text.cs


}
public void addPlaceholder(float width, float height, PlaceholderAlignment alignment,
TextBaseline baseline,
TextBaseline? baseline,
D.assert(alignment == PlaceholderAlignment.aboveBaseline ||
D.assert((alignment == PlaceholderAlignment.aboveBaseline ||
alignment == PlaceholderAlignment.baseline);
alignment == PlaceholderAlignment.baseline) ? baseline != null : true);
(int) baseline);
(int) (baseline ?? TextBaseline.alphabetic));
placeholderCount++;
placeholderScales.Add(item: scale);
}

2
com.unity.uiwidgets/Runtime/widgets/widget_span.cs


public override RenderComparison compareTo(InlineSpan other) {
if (this == other)
return RenderComparison.identical;
if (style.GetType() != GetType())
if (other.GetType() != GetType())
return RenderComparison.layout;
if ((style == null) != (other.style == null))
return RenderComparison.layout;

正在加载...
取消
保存