Cooperation/ChatWidget.ui

Fri, 11 Mar 2011 16:51:57 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Fri, 11 Mar 2011 16:51:57 +0100
changeset 945
8cd4d08fa9f6
parent 816
53e282890577
child 2223
054c285dab38
child 2287
886b1fd60739
permissions
-rw-r--r--

Made code mostly PEP 8 compliant (except all whitespace and line length).

<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
 <class>ChatWidget</class>
 <widget class="QWidget" name="ChatWidget">
  <property name="geometry">
   <rect>
    <x>0</x>
    <y>0</y>
    <width>300</width>
    <height>600</height>
   </rect>
  </property>
  <property name="windowTitle">
   <string>Chat</string>
  </property>
  <layout class="QVBoxLayout" name="verticalLayout_2">
   <item>
    <widget class="QGroupBox" name="usersGroup">
     <property name="sizePolicy">
      <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
       <horstretch>0</horstretch>
       <verstretch>1</verstretch>
      </sizepolicy>
     </property>
     <property name="title">
      <string>Users</string>
     </property>
     <layout class="QVBoxLayout" name="verticalLayout">
      <item>
       <widget class="QListWidget" name="usersList">
        <property name="focusPolicy">
         <enum>Qt::NoFocus</enum>
        </property>
        <property name="contextMenuPolicy">
         <enum>Qt::CustomContextMenu</enum>
        </property>
       </widget>
      </item>
     </layout>
    </widget>
   </item>
   <item>
    <widget class="QGroupBox" name="chatGroup">
     <property name="sizePolicy">
      <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
       <horstretch>0</horstretch>
       <verstretch>2</verstretch>
      </sizepolicy>
     </property>
     <property name="title">
      <string>Chat</string>
     </property>
     <layout class="QGridLayout" name="gridLayout_2">
      <item row="0" column="0" colspan="2">
       <widget class="QTextEdit" name="chatEdit">
        <property name="focusPolicy">
         <enum>Qt::NoFocus</enum>
        </property>
        <property name="contextMenuPolicy">
         <enum>Qt::CustomContextMenu</enum>
        </property>
        <property name="readOnly">
         <bool>true</bool>
        </property>
       </widget>
      </item>
      <item row="1" column="0">
       <widget class="QLineEdit" name="messageEdit">
        <property name="toolTip">
         <string>Enter the text to send</string>
        </property>
       </widget>
      </item>
      <item row="1" column="1">
       <widget class="QToolButton" name="clearMessageButton">
        <property name="focusPolicy">
         <enum>Qt::NoFocus</enum>
        </property>
        <property name="toolTip">
         <string>Press to clear the message text</string>
        </property>
        <property name="text">
         <string>...</string>
        </property>
       </widget>
      </item>
      <item row="2" column="0" colspan="2">
       <widget class="QPushButton" name="sendButton">
        <property name="toolTip">
         <string>Press to send the text above</string>
        </property>
        <property name="text">
         <string>Send</string>
        </property>
       </widget>
      </item>
     </layout>
    </widget>
   </item>
   <item>
    <widget class="QGroupBox" name="sharingGroup">
     <property name="enabled">
      <bool>false</bool>
     </property>
     <property name="title">
      <string>Share Editor</string>
     </property>
     <layout class="QHBoxLayout" name="horizontalLayout">
      <item>
       <spacer name="horizontalSpacer_2">
        <property name="orientation">
         <enum>Qt::Horizontal</enum>
        </property>
        <property name="sizeHint" stdset="0">
         <size>
          <width>76</width>
          <height>20</height>
         </size>
        </property>
       </spacer>
      </item>
      <item>
       <widget class="QToolButton" name="shareButton">
        <property name="enabled">
         <bool>false</bool>
        </property>
        <property name="toolTip">
         <string>Press to toggle the shared status of the current editor</string>
        </property>
        <property name="text">
         <string>...</string>
        </property>
        <property name="checkable">
         <bool>true</bool>
        </property>
       </widget>
      </item>
      <item>
       <widget class="QToolButton" name="startEditButton">
        <property name="enabled">
         <bool>false</bool>
        </property>
        <property name="toolTip">
         <string>Press to start a shared edit</string>
        </property>
        <property name="text">
         <string>...</string>
        </property>
        <property name="checkable">
         <bool>true</bool>
        </property>
       </widget>
      </item>
      <item>
       <widget class="QToolButton" name="sendEditButton">
        <property name="enabled">
         <bool>false</bool>
        </property>
        <property name="toolTip">
         <string>Press to end the edit and send the changes</string>
        </property>
        <property name="text">
         <string>...</string>
        </property>
       </widget>
      </item>
      <item>
       <widget class="QToolButton" name="cancelEditButton">
        <property name="enabled">
         <bool>false</bool>
        </property>
        <property name="toolTip">
         <string>Press to cancel the shared edit</string>
        </property>
        <property name="text">
         <string>...</string>
        </property>
       </widget>
      </item>
      <item>
       <spacer name="horizontalSpacer">
        <property name="orientation">
         <enum>Qt::Horizontal</enum>
        </property>
        <property name="sizeHint" stdset="0">
         <size>
          <width>75</width>
          <height>20</height>
         </size>
        </property>
       </spacer>
      </item>
     </layout>
    </widget>
   </item>
   <item>
    <widget class="QGroupBox" name="connectGroup">
     <property name="title">
      <string>Connection</string>
     </property>
     <layout class="QVBoxLayout" name="verticalLayout_3">
      <item>
       <layout class="QHBoxLayout" name="horizontalLayout_3">
        <item>
         <widget class="QLabel" name="label_2">
          <property name="text">
           <string>Host:</string>
          </property>
         </widget>
        </item>
        <item>
         <widget class="QComboBox" name="hostEdit">
          <property name="sizePolicy">
           <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
            <horstretch>0</horstretch>
            <verstretch>0</verstretch>
           </sizepolicy>
          </property>
          <property name="toolTip">
           <string>Enter the host and port to connect to in the form &quot;host:port&quot;</string>
          </property>
          <property name="editable">
           <bool>true</bool>
          </property>
          <property name="insertPolicy">
           <enum>QComboBox::InsertAtTop</enum>
          </property>
          <property name="sizeAdjustPolicy">
           <enum>QComboBox::AdjustToMinimumContentsLength</enum>
          </property>
         </widget>
        </item>
        <item>
         <widget class="QToolButton" name="clearHostButton">
          <property name="focusPolicy">
           <enum>Qt::NoFocus</enum>
          </property>
          <property name="toolTip">
           <string>Press to clear the host</string>
          </property>
          <property name="text">
           <string>...</string>
          </property>
         </widget>
        </item>
       </layout>
      </item>
      <item>
       <layout class="QHBoxLayout" name="horizontalLayout_4">
        <item>
         <widget class="QPushButton" name="clearHostsButton">
          <property name="toolTip">
           <string>Press to clear the hosts list</string>
          </property>
          <property name="text">
           <string>Clear</string>
          </property>
         </widget>
        </item>
        <item>
         <widget class="QPushButton" name="connectButton">
          <property name="enabled">
           <bool>false</bool>
          </property>
          <property name="sizePolicy">
           <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
            <horstretch>0</horstretch>
            <verstretch>0</verstretch>
           </sizepolicy>
          </property>
          <property name="text">
           <string/>
          </property>
          <property name="autoDefault">
           <bool>false</bool>
          </property>
         </widget>
        </item>
        <item>
         <widget class="E5Led" name="connectionLed" native="true">
          <property name="toolTip">
           <string>Shows the connection status</string>
          </property>
         </widget>
        </item>
       </layout>
      </item>
     </layout>
    </widget>
   </item>
   <item>
    <widget class="QGroupBox" name="serverGroup">
     <property name="title">
      <string>Server</string>
     </property>
     <layout class="QHBoxLayout" name="horizontalLayout_2">
      <item>
       <widget class="QLabel" name="label_4">
        <property name="text">
         <string>Port:</string>
        </property>
       </widget>
      </item>
      <item>
       <widget class="QSpinBox" name="serverPortSpin">
        <property name="toolTip">
         <string>Enter the server port</string>
        </property>
        <property name="minimum">
         <number>1025</number>
        </property>
        <property name="maximum">
         <number>65535</number>
        </property>
        <property name="singleStep">
         <number>1</number>
        </property>
        <property name="value">
         <number>42000</number>
        </property>
       </widget>
      </item>
      <item>
       <widget class="QPushButton" name="serverButton">
        <property name="sizePolicy">
         <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
          <horstretch>0</horstretch>
          <verstretch>0</verstretch>
         </sizepolicy>
        </property>
        <property name="text">
         <string/>
        </property>
        <property name="autoDefault">
         <bool>false</bool>
        </property>
       </widget>
      </item>
      <item>
       <widget class="E5Led" name="serverLed" native="true">
        <property name="toolTip">
         <string>Shows the status of the server</string>
        </property>
       </widget>
      </item>
     </layout>
    </widget>
   </item>
  </layout>
 </widget>
 <customwidgets>
  <customwidget>
   <class>E5Led</class>
   <extends>QWidget</extends>
   <header>E5Gui/E5Led.h</header>
   <container>1</container>
  </customwidget>
 </customwidgets>
 <tabstops>
  <tabstop>serverButton</tabstop>
  <tabstop>serverPortSpin</tabstop>
  <tabstop>hostEdit</tabstop>
  <tabstop>connectButton</tabstop>
  <tabstop>clearHostsButton</tabstop>
  <tabstop>shareButton</tabstop>
  <tabstop>startEditButton</tabstop>
  <tabstop>sendEditButton</tabstop>
  <tabstop>cancelEditButton</tabstop>
  <tabstop>messageEdit</tabstop>
  <tabstop>sendButton</tabstop>
 </tabstops>
 <resources/>
 <connections>
  <connection>
   <sender>clearHostButton</sender>
   <signal>pressed()</signal>
   <receiver>hostEdit</receiver>
   <slot>clearEditText()</slot>
   <hints>
    <hint type="sourcelabel">
     <x>279</x>
     <y>651</y>
    </hint>
    <hint type="destinationlabel">
     <x>221</x>
     <y>653</y>
    </hint>
   </hints>
  </connection>
  <connection>
   <sender>clearMessageButton</sender>
   <signal>pressed()</signal>
   <receiver>messageEdit</receiver>
   <slot>clear()</slot>
   <hints>
    <hint type="sourcelabel">
     <x>274</x>
     <y>488</y>
    </hint>
    <hint type="destinationlabel">
     <x>241</x>
     <y>489</y>
    </hint>
   </hints>
  </connection>
 </connections>
</ui>

eric ide

mercurial