MeeGo 1.2 Harmattan Developer Documentation Develop for the Nokia N9

batterypublisher.ui Example File

battery-charge/battery-publisher/batterypublisher.ui
 <?xml version="1.0" encoding="UTF-8"?>
 <ui version="4.0">
  <class>BatteryPublisher</class>
  <widget class="QDialog" name="BatteryPublisher">
   <property name="geometry">
    <rect>
     <x>0</x>
     <y>0</y>
     <width>400</width>
     <height>125</height>
    </rect>
   </property>
   <property name="windowTitle">
    <string>Battery Publisher</string>
   </property>
   <layout class="QGridLayout" name="gridLayout">
    <item row="0" column="0">
     <widget class="QLabel" name="label">
      <property name="text">
       <string>Empty</string>
      </property>
     </widget>
    </item>
    <item row="0" column="1">
     <spacer name="horizontalSpacer">
      <property name="orientation">
       <enum>Qt::Horizontal</enum>
      </property>
      <property name="sizeHint" stdset="0">
       <size>
        <width>322</width>
        <height>20</height>
       </size>
      </property>
     </spacer>
    </item>
    <item row="0" column="2">
     <widget class="QLabel" name="label_2">
      <property name="text">
       <string>Full</string>
      </property>
     </widget>
    </item>
    <item row="1" column="0" colspan="3">
     <widget class="QSlider" name="batteryCharge">
      <property name="maximum">
       <number>100</number>
      </property>
      <property name="singleStep">
       <number>5</number>
      </property>
      <property name="pageStep">
       <number>25</number>
      </property>
      <property name="value">
       <number>50</number>
      </property>
      <property name="orientation">
       <enum>Qt::Horizontal</enum>
      </property>
      <property name="tickPosition">
       <enum>QSlider::TicksBothSides</enum>
      </property>
      <property name="tickInterval">
       <number>25</number>
      </property>
     </widget>
    </item>
    <item row="4" column="0" colspan="3">
     <widget class="QDialogButtonBox" name="buttonBox">
      <property name="orientation">
       <enum>Qt::Horizontal</enum>
      </property>
      <property name="standardButtons">
       <set>QDialogButtonBox::Close</set>
      </property>
     </widget>
    </item>
    <item row="3" column="0" colspan="3">
     <spacer name="verticalSpacer">
      <property name="orientation">
       <enum>Qt::Vertical</enum>
      </property>
      <property name="sizeHint" stdset="0">
       <size>
        <width>20</width>
        <height>40</height>
       </size>
      </property>
     </spacer>
    </item>
    <item row="2" column="0" colspan="3">
     <widget class="QCheckBox" name="charging">
      <property name="text">
       <string>Charging</string>
      </property>
     </widget>
    </item>
   </layout>
  </widget>
  <resources/>
  <connections>
   <connection>
    <sender>buttonBox</sender>
    <signal>accepted()</signal>
    <receiver>BatteryPublisher</receiver>
    <slot>accept()</slot>
    <hints>
     <hint type="sourcelabel">
      <x>252</x>
      <y>152</y>
     </hint>
     <hint type="destinationlabel">
      <x>157</x>
      <y>156</y>
     </hint>
    </hints>
   </connection>
   <connection>
    <sender>buttonBox</sender>
    <signal>rejected()</signal>
    <receiver>BatteryPublisher</receiver>
    <slot>reject()</slot>
    <hints>
     <hint type="sourcelabel">
      <x>320</x>
      <y>152</y>
     </hint>
     <hint type="destinationlabel">
      <x>286</x>
      <y>156</y>
     </hint>
    </hints>
   </connection>
  </connections>
 </ui>