svghmi/widget_list.ysl2
author Edouard Tisserant
Wed, 06 Oct 2021 10:45:06 +0200
changeset 3333 dd49e4055a10
parent 3241 fe945f1f48b7
child 3320 9fe5b4a04acc
permissions -rw-r--r--
Fixed two exceptions happening when interacting with viewer(s) in debug mode, when debug data is still not initialized.
// widget_list.ysl2
widget_desc("List") {
    // TODO
}

widget_defs("List") {
    |     items: {
    foreach "$hmi_element/*[@inkscape:label]" {
    |         «@inkscape:label»: "«@id»",
    }
    |     },
}

widget_defs("TextStyleList") {
    // TODO
}

widget_defs("TextStyleList") {
    |     styles: {
    foreach "$hmi_element/*[@inkscape:label]" {
        const "style", "func:refered_elements(.)[self::svg:text]/@style";
    |         «@inkscape:label»: "«$style»",
    }
    |     },
}