# HG changeset patch # User Edouard Tisserant # Date 1585653615 -7200 # Node ID 1695122a5e1680f6c0fbeeba3600715bced2fbb9 # Parent 3b4a1319da09b36493e650f6a0557898379bd905 SVGHMI: HMI:Switch now accepts boolean values 'true' and 'false' diff -r 3b4a1319da09 -r 1695122a5e16 svghmi/gen_index_xhtml.xslt --- a/svghmi/gen_index_xhtml.xslt Mon Mar 30 14:26:42 2020 +0200 +++ b/svghmi/gen_index_xhtml.xslt Tue Mar 31 13:20:15 2020 +0200 @@ -1249,7 +1249,7 @@ choices: [ - + { diff -r 3b4a1319da09 -r 1695122a5e16 svghmi/widget_switch.ysl2 --- a/svghmi/widget_switch.ysl2 Mon Mar 30 14:26:42 2020 +0200 +++ b/svghmi/widget_switch.ysl2 Tue Mar 31 13:20:15 2020 +0200 @@ -16,7 +16,7 @@ | // Hello Switch | }, | choices: [ - const "regex",!"'^(\"[^\"].*\"|\-?[0-9]+)(#.*)?$'"!; + const "regex",!"'^(\"[^\"].*\"|\-?[0-9]+|false|true)(#.*)?$'"!; foreach "$hmi_element/*[regexp:test(@inkscape:label,$regex)]" { const "literal", "regexp:match(@inkscape:label,$regex)[2]"; | {