MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / PiuLabelComputeStyle

Function PiuLabelComputeStyle

modules/piu/All/piuLabel.c:80–101  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

78}
79
80void PiuLabelComputeStyle(PiuLabel* self, PiuApplication* application, PiuView* view)
81{
82 xsMachine* the = (*self)->the;
83 PiuContainer* container = (PiuContainer*)self;
84 PiuStyleLink* list = (*application)->styleList;
85 PiuStyleLink* chain = NULL;
86 while (container) {
87 PiuStyle* style = (*container)->style;
88 if (style) {
89 list = PiuStyleLinkMatch(the, list, chain, style);
90 chain = list;
91 }
92 container = (*container)->container;
93 }
94 if (chain) {
95 PiuStyle* result = PiuStyleLinkCompute(the, chain, application);
96 (*self)->computedStyle = result;
97 #ifdef piuGPU
98 PiuStyleBind((*self)->computedStyle, application, view);
99 #endif
100 }
101}
102
103void PiuLabelDictionary(xsMachine* the, void* it)
104{

Callers 2

PiuLabelBindFunction · 0.85
PiuLabelCascadeFunction · 0.85

Calls 3

PiuStyleLinkMatchFunction · 0.85
PiuStyleLinkComputeFunction · 0.85
PiuStyleBindFunction · 0.85

Tested by

no test coverage detected