svghmi/widget_list.ysl2
author Edouard Tisserant
Thu, 01 Apr 2021 15:56:19 +0200
branchsvghmi
changeset 3218 76f1cd1291f4
parent 3185 9038655c1b18
child 3232 7bdb766c2a4d
permissions -rw-r--r--
SVGHMI: Fixed last i18n changes meant to allow checking changes in PO files. Was making build exception when no PO files available.
// widget_list.ysl2

template "widget[@type='List']", mode="widget_defs" {
    param "hmi_element";
    |     items: {
    foreach "$hmi_element/*[@inkscape:label]" {
    |         «@inkscape:label»: "«@id»",
    }
    |     },
}

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