<?xml version="1.0" encoding="UTF-8"?>
<display window-flags="sticky, below">
<meta>
 author="Maxin B. John"
 name="CPU load Display"
 version="0.1"
 category="uncategorized"
 description="A widget to show the use of Control"
</meta>
<!-- the interface id for each controls can be obtained from the gDesklets program -->
  <control id="mysystem" interface="ISystem:4zcicmk4botcub7iypo46t2l7-2"/>

  <label id="mylabel" font="Mono 1cm" color="red"/>

  <script > <![CDATA[
def timer():

    load = mysystem.cpu_load
    Dsp.mylabel.value = "%s" % (load)
    return True

# call the timer every 1000ms = 1s
add_timer(1000, timer)

  ]] > </script>

</display>

