I found a way to have variables in the pyvcp XML

its a feature called ENTITY

<?XML version='1.0' encoding='UTF-8'?>
<!DOCTYPE pyvcp [
  <!ENTITY hbarw "250">          \
  <!ENTITY myfont "'Arial'">      these are vars
  <!ENTITY tsz1 "10">           /
  <!ENTITY bgclr "'yellow'">   /
  <!ENTITY nfmt "'{:.2f}'">   /
]>

<pyvcp>
    <table>
    <tablesticky sticky="new"/>
    <tablerow/>

        <bar>
            <halpin>"proc01"</halpin>
            <min_>0</min_>
            <max_>.5</max_>
            <canvas_height>122</canvas_height>
            <canvas_width>82</canvas_width>
            <bar_height>120</bar_height>
            <bar_width>30</bar_width>
            <nfmt>'{:.2f}'</nfmt>          this format pattern didnt work using ENTITY :-(
            <bgcolor>&bgclr;</bgcolor>     use var this way    &varname;
            <fillcolor>'red'</fillcolor>
            <font>&myfont;</font>          var
            <fontsize>&tsz1;</fontsize>    var

        </bar>

  ...

not quite xslt but maybe handy

tomp



_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to