14#include <emscripten/bind.h>
21 enum_<para::Affinity>(
"Affinity")
25 enum_<para::TextDecorationStyle>(
"DecorationStyle")
32 enum_<SkFontStyle::Slant>(
"FontSlant")
33 .value(
"Upright", SkFontStyle::Slant::kUpright_Slant)
34 .value(
"Italic", SkFontStyle::Slant::kItalic_Slant)
35 .value(
"Oblique", SkFontStyle::Slant::kOblique_Slant);
37 enum_<SkFontStyle::Weight>(
"FontWeight")
38 .value(
"Invisible", SkFontStyle::Weight::kInvisible_Weight)
39 .value(
"Thin", SkFontStyle::Weight::kThin_Weight)
40 .value(
"ExtraLight", SkFontStyle::Weight::kExtraLight_Weight)
41 .value(
"Light", SkFontStyle::Weight::kLight_Weight)
42 .value(
"Normal", SkFontStyle::Weight::kNormal_Weight)
43 .value(
"Medium", SkFontStyle::Weight::kMedium_Weight)
44 .value(
"SemiBold", SkFontStyle::Weight::kSemiBold_Weight)
45 .value(
"Bold", SkFontStyle::Weight::kBold_Weight)
46 .value(
"ExtraBold", SkFontStyle::Weight::kExtraBold_Weight)
47 .value(
"Black", SkFontStyle::Weight::kBlack_Weight)
48 .value(
"ExtraBlack", SkFontStyle::Weight::kExtraBlack_Weight);
50 enum_<SkFontStyle::Width>(
"FontWidth")
51 .value(
"UltraCondensed", SkFontStyle::Width::kUltraCondensed_Width)
52 .value(
"ExtraCondensed", SkFontStyle::Width::kExtraCondensed_Width)
53 .value(
"Condensed", SkFontStyle::Width::kCondensed_Width)
54 .value(
"SemiCondensed", SkFontStyle::Width::kSemiCondensed_Width)
55 .value(
"Normal", SkFontStyle::Width::kNormal_Width)
56 .value(
"SemiExpanded", SkFontStyle::Width::kSemiExpanded_Width)
57 .value(
"Expanded", SkFontStyle::Width::kExpanded_Width)
58 .value(
"ExtraExpanded", SkFontStyle::Width::kExtraExpanded_Width)
59 .value(
"UltraExpanded", SkFontStyle::Width::kUltraExpanded_Width);
61 enum_<para::PlaceholderAlignment>(
"PlaceholderAlignment")
63 .value(
"AboveBaseline", para::PlaceholderAlignment::kAboveBaseline)
64 .value(
"BelowBaseline", para::PlaceholderAlignment::kBelowBaseline)
69 enum_<para::RectHeightStyle>(
"RectHeightStyle")
77 enum_<para::RectWidthStyle>(
"RectWidthStyle")
81 enum_<para::TextAlign>(
"TextAlign")
85 .value(
"Justify", para::TextAlign::kJustify)
89 enum_<para::TextBaseline>(
"TextBaseline")
93 enum_<para::TextDirection>(
"TextDirection")
94 .value(
"LTR", para::TextDirection::kLtr)
95 .value(
"RTL", para::TextDirection::kRtl);
97 enum_<para::TextHeightBehavior>(
"TextHeightBehavior")
98 .value(
"All", para::TextHeightBehavior::kAll)
103 enum_<SkUnicode::LineBreakType>(
"LineBreakType")
@ kBaseline
Match the baseline of the placeholder with the baseline.
@ kIncludeLineSpacingBottom
@ kIncludeLineSpacingMiddle
EMSCRIPTEN_BINDINGS(ParagraphGen)