Skip to content

Commit 2688fd0

Browse files
committed
Added new functions for text shaping to API, update TextInput cursor
1 parent 907ad5b commit 2688fd0

File tree

13 files changed

+822
-86
lines changed

13 files changed

+822
-86
lines changed

api.json

+65
Original file line numberDiff line numberDiff line change
@@ -1214,6 +1214,14 @@
12141214
"returns": {"type": "OptionFontRef"},
12151215
"fn_body": "callbackinfo.get_font_ref(node_id).into()"
12161216
},
1217+
"get_text_layout_options": {
1218+
"fn_args": [
1219+
{"self": "ref"},
1220+
{"node_id": "DomNodeId"}
1221+
],
1222+
"returns": {"type": "OptionResolvedTextLayoutOptions"},
1223+
"fn_body": "callbackinfo.get_text_layout_options(node_id).into()"
1224+
},
12171225
"shape_text": {
12181226
"doc": "Similar to `get_inline_text()`: If the node is a `Text` node, shape the `text` string with the same parameters as the current text and return the calculated InlineTextLayout. Necessary to calculate text cursor offsets and to detect when a line overflows content.",
12191227
"fn_args": [
@@ -1668,6 +1676,19 @@
16681676
{"css_path": {"type": "CssPath"}}
16691677
]
16701678
},
1679+
"ResolvedTextLayoutOptions": {
1680+
"external": "azul_impl::ui_solver::ResolvedTextLayoutOptions",
1681+
"struct_fields": [
1682+
{"font_size_px": {"type": "f32"}},
1683+
{"line_height": {"type": "OptionF32"}},
1684+
{"letter_spacing": {"type": "OptionF32"}},
1685+
{"word_spacing": {"type": "OptionF32"}},
1686+
{"tab_width": {"type": "OptionF32"}},
1687+
{"max_horizontal_width": {"type": "OptionF32"}},
1688+
{"leading": {"type": "OptionF32"}},
1689+
{"holes": {"type": "LogicalRectVec"}}
1690+
]
1691+
},
16711692
"Animation": {
16721693
"doc": "Animation struct to start a new animation",
16731694
"external": "azul_impl::callbacks::Animation",
@@ -10705,6 +10726,16 @@
1070510726
],
1070610727
"returns": {"type": "FontMetrics"},
1070710728
"fn_body": "azul_impl::text_layout::get_font_metrics_fontref(fontref)"
10729+
},
10730+
"shape_text": {
10731+
"doc": "Returns the text layout of the shaped text",
10732+
"fn_args": [
10733+
{"self": "ref"},
10734+
{"text": "Refstr"},
10735+
{"options": "ResolvedTextLayoutOptions"}
10736+
],
10737+
"returns": {"type": "InlineText"},
10738+
"fn_body": "azul_impl::text_layout::shape_text(fontref, text.as_str(), &options)"
1070810739
}
1070910740
}
1071010741
}
@@ -12014,6 +12045,17 @@
1201412045
"vec": {
1201512046
"doc": "Definition of azuls internal `Vec<*>` wrappers",
1201612047
"classes": {
12048+
"LogicalRectVec": {
12049+
"doc": "Wrapper over a Rust-allocated `Vec<LogicalRect>`",
12050+
"custom_destructor": true,
12051+
"external": "azul_core::window::LogicalRectVec",
12052+
"struct_fields": [
12053+
{ "ptr": { "type": "*const LogicalRect" } },
12054+
{ "len": { "type": "usize" } },
12055+
{ "cap": { "type": "usize" } },
12056+
{ "destructor": { "type": "LogicalRectVecDestructor" } }
12057+
]
12058+
},
1201712059
"NodeTypeIdInfoMapVec": {
1201812060
"doc": "Wrapper over a Rust-allocated `Vec<NodeTypeIdInfoMap>`",
1201912061
"custom_destructor": true,
@@ -12743,6 +12785,22 @@
1274312785
]
1274412786
}
1274512787
},
12788+
"LogicalRectVecDestructor": {
12789+
"external": "azul_core::window::LogicalRectVecDestructor",
12790+
"derive": ["Copy"],
12791+
"enum_fields": [
12792+
{"DefaultRust": {}},
12793+
{"NoDestructor": {}},
12794+
{"External": {"type": "LogicalRectVecDestructorType"}}
12795+
]
12796+
},
12797+
"LogicalRectVecDestructorType": {
12798+
"callback_typedef": {
12799+
"fn_args": [
12800+
{"type": "LogicalRectVec", "ref": "refmut"}
12801+
]
12802+
}
12803+
},
1274612804
"NodeTypeIdInfoMapVecDestructor": {
1274712805
"external": "crate::widgets::node_graph::NodeTypeIdInfoMapVecDestructor",
1274812806
"derive": ["Copy"],
@@ -13724,6 +13782,13 @@
1372413782
"option": {
1372513783
"doc": "Definition of azuls internal `Option<*>` wrappers",
1372613784
"classes": {
13785+
"OptionResolvedTextLayoutOptions": {
13786+
"external": "azul_impl::ui_solver::OptionResolvedTextLayoutOptions",
13787+
"enum_fields": [
13788+
{"None": {}},
13789+
{"Some": {"type": "ResolvedTextLayoutOptions"}}
13790+
]
13791+
},
1372713792
"OptionNodeGraphOnNodeAdded": {
1372813793
"external": "crate::widgets::node_graph::OptionOnNodeAdded",
1372913794
"enum_fields": [

api/c/azul.h

+102
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,10 @@ struct AzStyleFontFamilyVec;
178178
typedef struct AzStyleFontFamilyVec AzStyleFontFamilyVec;
179179
typedef void (*AzStyleFontFamilyVecDestructorType)(AzStyleFontFamilyVec* restrict A);
180180

181+
struct AzLogicalRectVec;
182+
typedef struct AzLogicalRectVec AzLogicalRectVec;
183+
typedef void (*AzLogicalRectVecDestructorType)(AzLogicalRectVec* restrict A);
184+
181185
struct AzNodeTypeIdInfoMapVec;
182186
typedef struct AzNodeTypeIdInfoMapVec AzNodeTypeIdInfoMapVec;
183187
typedef void (*AzNodeTypeIdInfoMapVecDestructorType)(AzNodeTypeIdInfoMapVec* restrict A);
@@ -2170,6 +2174,26 @@ union AzStyleFontFamilyVecDestructor {
21702174
};
21712175
typedef union AzStyleFontFamilyVecDestructor AzStyleFontFamilyVecDestructor;
21722176

2177+
enum AzLogicalRectVecDestructorTag {
2178+
AzLogicalRectVecDestructorTag_DefaultRust,
2179+
AzLogicalRectVecDestructorTag_NoDestructor,
2180+
AzLogicalRectVecDestructorTag_External,
2181+
};
2182+
typedef enum AzLogicalRectVecDestructorTag AzLogicalRectVecDestructorTag;
2183+
2184+
struct AzLogicalRectVecDestructorVariant_DefaultRust { AzLogicalRectVecDestructorTag tag; };
2185+
typedef struct AzLogicalRectVecDestructorVariant_DefaultRust AzLogicalRectVecDestructorVariant_DefaultRust;
2186+
struct AzLogicalRectVecDestructorVariant_NoDestructor { AzLogicalRectVecDestructorTag tag; };
2187+
typedef struct AzLogicalRectVecDestructorVariant_NoDestructor AzLogicalRectVecDestructorVariant_NoDestructor;
2188+
struct AzLogicalRectVecDestructorVariant_External { AzLogicalRectVecDestructorTag tag; AzLogicalRectVecDestructorType payload; };
2189+
typedef struct AzLogicalRectVecDestructorVariant_External AzLogicalRectVecDestructorVariant_External;
2190+
union AzLogicalRectVecDestructor {
2191+
AzLogicalRectVecDestructorVariant_DefaultRust DefaultRust;
2192+
AzLogicalRectVecDestructorVariant_NoDestructor NoDestructor;
2193+
AzLogicalRectVecDestructorVariant_External External;
2194+
};
2195+
typedef union AzLogicalRectVecDestructor AzLogicalRectVecDestructor;
2196+
21732197
enum AzNodeTypeIdInfoMapVecDestructorTag {
21742198
AzNodeTypeIdInfoMapVecDestructorTag_DefaultRust,
21752199
AzNodeTypeIdInfoMapVecDestructorTag_NoDestructor,
@@ -6260,6 +6284,14 @@ struct AzThreadWriteBackMsg {
62606284
};
62616285
typedef struct AzThreadWriteBackMsg AzThreadWriteBackMsg;
62626286

6287+
struct AzLogicalRectVec {
6288+
AzLogicalRect* ptr;
6289+
size_t len;
6290+
size_t cap;
6291+
AzLogicalRectVecDestructor destructor;
6292+
};
6293+
typedef struct AzLogicalRectVec AzLogicalRectVec;
6294+
62636295
struct AzInputOutputTypeIdVec {
62646296
AzInputOutputTypeId* ptr;
62656297
size_t len;
@@ -7452,6 +7484,18 @@ struct AzInlineTextContents {
74527484
};
74537485
typedef struct AzInlineTextContents AzInlineTextContents;
74547486

7487+
struct AzResolvedTextLayoutOptions {
7488+
float font_size_px;
7489+
AzOptionF32 line_height;
7490+
AzOptionF32 letter_spacing;
7491+
AzOptionF32 word_spacing;
7492+
AzOptionF32 tab_width;
7493+
AzOptionF32 max_horizontal_width;
7494+
AzOptionF32 leading;
7495+
AzLogicalRectVec holes;
7496+
};
7497+
typedef struct AzResolvedTextLayoutOptions AzResolvedTextLayoutOptions;
7498+
74557499
enum AzAnimationEasingTag {
74567500
AzAnimationEasingTag_Ease,
74577501
AzAnimationEasingTag_Linear,
@@ -8081,6 +8125,22 @@ struct AzTagIdToNodeIdMappingVec {
80818125
};
80828126
typedef struct AzTagIdToNodeIdMappingVec AzTagIdToNodeIdMappingVec;
80838127

8128+
enum AzOptionResolvedTextLayoutOptionsTag {
8129+
AzOptionResolvedTextLayoutOptionsTag_None,
8130+
AzOptionResolvedTextLayoutOptionsTag_Some,
8131+
};
8132+
typedef enum AzOptionResolvedTextLayoutOptionsTag AzOptionResolvedTextLayoutOptionsTag;
8133+
8134+
struct AzOptionResolvedTextLayoutOptionsVariant_None { AzOptionResolvedTextLayoutOptionsTag tag; };
8135+
typedef struct AzOptionResolvedTextLayoutOptionsVariant_None AzOptionResolvedTextLayoutOptionsVariant_None;
8136+
struct AzOptionResolvedTextLayoutOptionsVariant_Some { AzOptionResolvedTextLayoutOptionsTag tag; AzResolvedTextLayoutOptions payload; };
8137+
typedef struct AzOptionResolvedTextLayoutOptionsVariant_Some AzOptionResolvedTextLayoutOptionsVariant_Some;
8138+
union AzOptionResolvedTextLayoutOptions {
8139+
AzOptionResolvedTextLayoutOptionsVariant_None None;
8140+
AzOptionResolvedTextLayoutOptionsVariant_Some Some;
8141+
};
8142+
typedef union AzOptionResolvedTextLayoutOptions AzOptionResolvedTextLayoutOptions;
8143+
80848144
enum AzOptionVirtualKeyCodeComboTag {
80858145
AzOptionVirtualKeyCodeComboTag_None,
80868146
AzOptionVirtualKeyCodeComboTag_Some,
@@ -10343,6 +10403,9 @@ typedef struct AzCss AzCss;
1034310403
#define AzStyleFontFamilyVecDestructor_DefaultRust { .DefaultRust = { .tag = AzStyleFontFamilyVecDestructorTag_DefaultRust } }
1034410404
#define AzStyleFontFamilyVecDestructor_NoDestructor { .NoDestructor = { .tag = AzStyleFontFamilyVecDestructorTag_NoDestructor } }
1034510405
#define AzStyleFontFamilyVecDestructor_External(v) { .External = { .tag = AzStyleFontFamilyVecDestructorTag_External, .payload = v } }
10406+
#define AzLogicalRectVecDestructor_DefaultRust { .DefaultRust = { .tag = AzLogicalRectVecDestructorTag_DefaultRust } }
10407+
#define AzLogicalRectVecDestructor_NoDestructor { .NoDestructor = { .tag = AzLogicalRectVecDestructorTag_NoDestructor } }
10408+
#define AzLogicalRectVecDestructor_External(v) { .External = { .tag = AzLogicalRectVecDestructorTag_External, .payload = v } }
1034610409
#define AzNodeTypeIdInfoMapVecDestructor_DefaultRust { .DefaultRust = { .tag = AzNodeTypeIdInfoMapVecDestructorTag_DefaultRust } }
1034710410
#define AzNodeTypeIdInfoMapVecDestructor_NoDestructor { .NoDestructor = { .tag = AzNodeTypeIdInfoMapVecDestructorTag_NoDestructor } }
1034810411
#define AzNodeTypeIdInfoMapVecDestructor_External(v) { .External = { .tag = AzNodeTypeIdInfoMapVecDestructorTag_External, .payload = v } }
@@ -11067,6 +11130,8 @@ typedef struct AzCss AzCss;
1106711130
#define AzInstant_Tick(v) { .Tick = { .tag = AzInstantTag_Tick, .payload = v } }
1106811131
#define AzThreadReceiveMsg_WriteBack(v) { .WriteBack = { .tag = AzThreadReceiveMsgTag_WriteBack, .payload = v } }
1106911132
#define AzThreadReceiveMsg_Update(v) { .Update = { .tag = AzThreadReceiveMsgTag_Update, .payload = v } }
11133+
#define AzOptionResolvedTextLayoutOptions_None { .None = { .tag = AzOptionResolvedTextLayoutOptionsTag_None } }
11134+
#define AzOptionResolvedTextLayoutOptions_Some(v) { .Some = { .tag = AzOptionResolvedTextLayoutOptionsTag_Some, .payload = v } }
1107011135
#define AzOptionVirtualKeyCodeCombo_None { .None = { .tag = AzOptionVirtualKeyCodeComboTag_None } }
1107111136
#define AzOptionVirtualKeyCodeCombo_Some(v) { .Some = { .tag = AzOptionVirtualKeyCodeComboTag_Some, .payload = v } }
1107211137
#define AzOptionMouseState_None { .None = { .tag = AzOptionMouseStateTag_None } }
@@ -11321,6 +11386,10 @@ typedef struct AzCss AzCss;
1132111386
#define AzResultSvgXmlNodeSvgParseError_Err(v) { .Err = { .tag = AzResultSvgXmlNodeSvgParseErrorTag_Err, .payload = v } }
1132211387
#define AzResultSvgSvgParseError_Ok(v) { .Ok = { .tag = AzResultSvgSvgParseErrorTag_Ok, .payload = v } }
1132311388
#define AzResultSvgSvgParseError_Err(v) { .Err = { .tag = AzResultSvgSvgParseErrorTag_Err, .payload = v } }
11389+
AzLogicalRect AzLogicalRectVecArray[] = {};
11390+
#define AzLogicalRectVec_fromConstArray(v) { .ptr = &v, .len = sizeof(v) / sizeof(AzLogicalRect), .cap = sizeof(v) / sizeof(AzLogicalRect), .destructor = { .NoDestructor = { .tag = AzLogicalRectVecDestructorTag_NoDestructor, }, }, }
11391+
#define AzLogicalRectVec_empty { .ptr = &AzLogicalRectVecArray, .len = 0, .cap = 0, .destructor = { .NoDestructor = { .tag = AzLogicalRectVecDestructorTag_NoDestructor, }, }, }
11392+
1132411393
AzNodeTypeIdInfoMap AzNodeTypeIdInfoMapVecArray[] = {};
1132511394
#define AzNodeTypeIdInfoMapVec_fromConstArray(v) { .ptr = &v, .len = sizeof(v) / sizeof(AzNodeTypeIdInfoMap), .cap = sizeof(v) / sizeof(AzNodeTypeIdInfoMap), .destructor = { .NoDestructor = { .tag = AzNodeTypeIdInfoMapVecDestructorTag_NoDestructor, }, }, }
1132611395
#define AzNodeTypeIdInfoMapVec_empty { .ptr = &AzNodeTypeIdInfoMapVecArray, .len = 0, .cap = 0, .destructor = { .NoDestructor = { .tag = AzNodeTypeIdInfoMapVecDestructorTag_NoDestructor, }, }, }
@@ -11616,6 +11685,7 @@ extern DLLIMPORT AzOptionDomNodeId AzCallbackInfo_getNodeIdOfRootDataset(AzCallb
1161611685
extern DLLIMPORT AzOptionString AzCallbackInfo_getStringContents(const AzCallbackInfo* callbackinfo, AzDomNodeId node_id);
1161711686
extern DLLIMPORT AzOptionInlineText AzCallbackInfo_getInlineText(const AzCallbackInfo* callbackinfo, AzDomNodeId node_id);
1161811687
extern DLLIMPORT AzOptionFontRef AzCallbackInfo_getFontRef(const AzCallbackInfo* callbackinfo, AzDomNodeId node_id);
11688+
extern DLLIMPORT AzOptionResolvedTextLayoutOptions AzCallbackInfo_getTextLayoutOptions(const AzCallbackInfo* callbackinfo, AzDomNodeId node_id);
1161911689
extern DLLIMPORT AzOptionInlineText AzCallbackInfo_shapeText(const AzCallbackInfo* callbackinfo, AzDomNodeId node_id, AzString text);
1162011690
extern DLLIMPORT size_t AzCallbackInfo_getIndexInParent(AzCallbackInfo* restrict callbackinfo, AzDomNodeId node_id);
1162111691
extern DLLIMPORT AzOptionDomNodeId AzCallbackInfo_getParent(AzCallbackInfo* restrict callbackinfo, AzDomNodeId node_id);
@@ -11656,6 +11726,7 @@ extern DLLIMPORT void AzInlineWord_delete(AzInlineWord* restrict instance);
1165611726
extern DLLIMPORT void AzInlineTextContents_delete(AzInlineTextContents* restrict instance);
1165711727
extern DLLIMPORT void AzFocusTarget_delete(AzFocusTarget* restrict instance);
1165811728
extern DLLIMPORT void AzFocusTargetPath_delete(AzFocusTargetPath* restrict instance);
11729+
extern DLLIMPORT void AzResolvedTextLayoutOptions_delete(AzResolvedTextLayoutOptions* restrict instance);
1165911730
extern DLLIMPORT void AzAnimation_delete(AzAnimation* restrict instance);
1166011731
extern DLLIMPORT void AzIFrameCallbackReturn_delete(AzIFrameCallbackReturn* restrict instance);
1166111732
extern DLLIMPORT AzOptionGl AzRenderImageCallbackInfo_getGlContext(const AzRenderImageCallbackInfo* renderimagecallbackinfo);
@@ -12212,6 +12283,7 @@ extern DLLIMPORT void AzRawImageData_delete(AzRawImageData* restrict instance);
1221212283
extern DLLIMPORT void AzFontSource_delete(AzFontSource* restrict instance);
1221312284
extern DLLIMPORT AzFontRef AzFontRef_parse(AzFontSource source);
1221412285
extern DLLIMPORT AzFontMetrics AzFontRef_getFontMetrics(const AzFontRef* fontref);
12286+
extern DLLIMPORT AzInlineText AzFontRef_shapeText(const AzFontRef* fontref, AzRefstr text, AzResolvedTextLayoutOptions options);
1221512287
extern DLLIMPORT void AzFontRef_delete(AzFontRef* restrict instance);
1221612288
extern DLLIMPORT AzFontRef AzFontRef_deepCopy(AzFontRef* const instance);
1221712289
extern DLLIMPORT AzSvg AzSvg_fromString(AzString svg_string, AzSvgParseOptions parse_options);
@@ -12307,6 +12379,7 @@ extern DLLIMPORT AzString AzString_copyFromBytes(uint8_t ptr, size_t start, size
1230712379
extern DLLIMPORT AzString AzString_trim(const AzString* string);
1230812380
extern DLLIMPORT AzRefstr AzString_asRefstr(const AzString* string);
1230912381
extern DLLIMPORT void AzString_delete(AzString* restrict instance);
12382+
extern DLLIMPORT void AzLogicalRectVec_delete(AzLogicalRectVec* restrict instance);
1231012383
extern DLLIMPORT void AzNodeTypeIdInfoMapVec_delete(AzNodeTypeIdInfoMapVec* restrict instance);
1231112384
extern DLLIMPORT void AzInputOutputTypeIdInfoMapVec_delete(AzInputOutputTypeIdInfoMapVec* restrict instance);
1231212385
extern DLLIMPORT void AzNodeIdNodeMapVec_delete(AzNodeIdNodeMapVec* restrict instance);
@@ -12372,6 +12445,7 @@ extern DLLIMPORT void AzStyledNodeVec_delete(AzStyledNodeVec* restrict instance)
1237212445
extern DLLIMPORT void AzTagIdToNodeIdMappingVec_delete(AzTagIdToNodeIdMappingVec* restrict instance);
1237312446
extern DLLIMPORT void AzParentWithNodeDepthVec_delete(AzParentWithNodeDepthVec* restrict instance);
1237412447
extern DLLIMPORT void AzNodeDataVec_delete(AzNodeDataVec* restrict instance);
12448+
extern DLLIMPORT void AzOptionResolvedTextLayoutOptions_delete(AzOptionResolvedTextLayoutOptions* restrict instance);
1237512449
extern DLLIMPORT void AzOptionNodeGraphOnNodeAdded_delete(AzOptionNodeGraphOnNodeAdded* restrict instance);
1237612450
extern DLLIMPORT void AzOptionNodeGraphOnNodeRemoved_delete(AzOptionNodeGraphOnNodeRemoved* restrict instance);
1237712451
extern DLLIMPORT void AzOptionNodeGraphOnNodeGraphDragged_delete(AzOptionNodeGraphOnNodeGraphDragged* restrict instance);
@@ -17680,6 +17754,20 @@ bool AzStyleFontFamilyVecDestructor_matchMutExternal(AzStyleFontFamilyVecDestruc
1768017754
return valid;
1768117755
}
1768217756

17757+
bool AzLogicalRectVecDestructor_matchRefExternal(const AzLogicalRectVecDestructor* value, const AzLogicalRectVecDestructorType** restrict out) {
17758+
const AzLogicalRectVecDestructorVariant_External* casted = (const AzLogicalRectVecDestructorVariant_External*)value;
17759+
bool valid = casted->tag == AzLogicalRectVecDestructorTag_External;
17760+
if (valid) { *out = &casted->payload; } else { *out = 0; }
17761+
return valid;
17762+
}
17763+
17764+
bool AzLogicalRectVecDestructor_matchMutExternal(AzLogicalRectVecDestructor* restrict value, AzLogicalRectVecDestructorType* restrict * restrict out) {
17765+
AzLogicalRectVecDestructorVariant_External* restrict casted = (AzLogicalRectVecDestructorVariant_External* restrict)value;
17766+
bool valid = casted->tag == AzLogicalRectVecDestructorTag_External;
17767+
if (valid) { *out = &casted->payload; } else { *out = 0; }
17768+
return valid;
17769+
}
17770+
1768317771
bool AzNodeTypeIdInfoMapVecDestructor_matchRefExternal(const AzNodeTypeIdInfoMapVecDestructor* value, const AzNodeTypeIdInfoMapVecDestructorType** restrict out) {
1768417772
const AzNodeTypeIdInfoMapVecDestructorVariant_External* casted = (const AzNodeTypeIdInfoMapVecDestructorVariant_External*)value;
1768517773
bool valid = casted->tag == AzNodeTypeIdInfoMapVecDestructorTag_External;
@@ -18534,6 +18622,20 @@ bool AzNodeDataVecDestructor_matchMutExternal(AzNodeDataVecDestructor* restrict
1853418622
return valid;
1853518623
}
1853618624

18625+
bool AzOptionResolvedTextLayoutOptions_matchRefSome(const AzOptionResolvedTextLayoutOptions* value, const AzResolvedTextLayoutOptions** restrict out) {
18626+
const AzOptionResolvedTextLayoutOptionsVariant_Some* casted = (const AzOptionResolvedTextLayoutOptionsVariant_Some*)value;
18627+
bool valid = casted->tag == AzOptionResolvedTextLayoutOptionsTag_Some;
18628+
if (valid) { *out = &casted->payload; } else { *out = 0; }
18629+
return valid;
18630+
}
18631+
18632+
bool AzOptionResolvedTextLayoutOptions_matchMutSome(AzOptionResolvedTextLayoutOptions* restrict value, AzResolvedTextLayoutOptions* restrict * restrict out) {
18633+
AzOptionResolvedTextLayoutOptionsVariant_Some* restrict casted = (AzOptionResolvedTextLayoutOptionsVariant_Some* restrict)value;
18634+
bool valid = casted->tag == AzOptionResolvedTextLayoutOptionsTag_Some;
18635+
if (valid) { *out = &casted->payload; } else { *out = 0; }
18636+
return valid;
18637+
}
18638+
1853718639
bool AzOptionNodeGraphOnNodeAdded_matchRefSome(const AzOptionNodeGraphOnNodeAdded* value, const AzNodeGraphOnNodeAdded** restrict out) {
1853818640
const AzOptionNodeGraphOnNodeAddedVariant_Some* casted = (const AzOptionNodeGraphOnNodeAddedVariant_Some*)value;
1853918641
bool valid = casted->tag == AzOptionNodeGraphOnNodeAddedTag_Some;

0 commit comments

Comments
 (0)