Skip to content

Commit 76d264e

Browse files
[SkParagraph] Convert the height override flag in text styles (flutter#14283)
1 parent b7c947d commit 76d264e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

third_party/txt/src/skia/paragraph_builder_skia.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ skt::ParagraphStyle TxtToSkia(const ParagraphStyle& txt) {
4949
text_style.setFontStyle(MakeSkFontStyle(txt.font_weight, txt.font_style));
5050
text_style.setFontSize(SkDoubleToScalar(txt.font_size));
5151
text_style.setHeight(SkDoubleToScalar(txt.height));
52+
text_style.setHeightOverride(txt.has_height_override);
5253
text_style.setFontFamilies({SkString(txt.font_family.c_str())});
5354
text_style.setLocale(SkString(txt.locale.c_str()));
5455
skia.setTextStyle(text_style);
@@ -103,6 +104,7 @@ skt::TextStyle TxtToSkia(const TextStyle& txt) {
103104
skia.setLetterSpacing(SkDoubleToScalar(txt.letter_spacing));
104105
skia.setWordSpacing(SkDoubleToScalar(txt.word_spacing));
105106
skia.setHeight(SkDoubleToScalar(txt.height));
107+
skia.setHeightOverride(txt.has_height_override);
106108

107109
skia.setLocale(SkString(txt.locale.c_str()));
108110
if (txt.has_background) {

0 commit comments

Comments
 (0)