mainwindow.ui 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <ui version="4.0">
  3. <class>MainWindow</class>
  4. <widget class="QMainWindow" name="MainWindow">
  5. <property name="geometry">
  6. <rect>
  7. <x>0</x>
  8. <y>0</y>
  9. <width>360</width>
  10. <height>288</height>
  11. </rect>
  12. </property>
  13. <property name="font">
  14. <font>
  15. <family>宋体</family>
  16. <pointsize>10</pointsize>
  17. </font>
  18. </property>
  19. <property name="windowTitle">
  20. <string>TCP Server</string>
  21. </property>
  22. <widget class="QWidget" name="centralWidget">
  23. <layout class="QVBoxLayout" name="verticalLayout">
  24. <item>
  25. <layout class="QHBoxLayout" name="horizontalLayout">
  26. <item>
  27. <widget class="QLabel" name="label_2">
  28. <property name="text">
  29. <string>监听地址</string>
  30. </property>
  31. <property name="alignment">
  32. <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  33. </property>
  34. </widget>
  35. </item>
  36. <item>
  37. <widget class="QComboBox" name="comboIP">
  38. <property name="minimumSize">
  39. <size>
  40. <width>130</width>
  41. <height>0</height>
  42. </size>
  43. </property>
  44. <property name="editable">
  45. <bool>true</bool>
  46. </property>
  47. <property name="duplicatesEnabled">
  48. <bool>false</bool>
  49. </property>
  50. <item>
  51. <property name="text">
  52. <string>127.0.0.1</string>
  53. </property>
  54. </item>
  55. </widget>
  56. </item>
  57. <item>
  58. <widget class="QLabel" name="label">
  59. <property name="text">
  60. <string>监听端口</string>
  61. </property>
  62. <property name="alignment">
  63. <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  64. </property>
  65. </widget>
  66. </item>
  67. <item>
  68. <widget class="QSpinBox" name="spinPort">
  69. <property name="minimum">
  70. <number>1</number>
  71. </property>
  72. <property name="maximum">
  73. <number>65535</number>
  74. </property>
  75. <property name="value">
  76. <number>10080</number>
  77. </property>
  78. </widget>
  79. </item>
  80. </layout>
  81. </item>
  82. <item>
  83. <layout class="QHBoxLayout" name="horizontalLayout_2">
  84. <item>
  85. <widget class="QLineEdit" name="editMsg"/>
  86. </item>
  87. <item>
  88. <widget class="QToolButton" name="btnSend">
  89. <property name="text">
  90. <string>发送消息</string>
  91. </property>
  92. </widget>
  93. </item>
  94. </layout>
  95. </item>
  96. <item>
  97. <widget class="QPlainTextEdit" name="plainTextEdit"/>
  98. </item>
  99. </layout>
  100. </widget>
  101. <widget class="QMenuBar" name="menuBar">
  102. <property name="geometry">
  103. <rect>
  104. <x>0</x>
  105. <y>0</y>
  106. <width>360</width>
  107. <height>24</height>
  108. </rect>
  109. </property>
  110. </widget>
  111. <widget class="QToolBar" name="mainToolBar">
  112. <property name="toolButtonStyle">
  113. <enum>Qt::ToolButtonTextUnderIcon</enum>
  114. </property>
  115. <attribute name="toolBarArea">
  116. <enum>TopToolBarArea</enum>
  117. </attribute>
  118. <attribute name="toolBarBreak">
  119. <bool>false</bool>
  120. </attribute>
  121. <addaction name="actStart"/>
  122. <addaction name="actStop"/>
  123. <addaction name="actClear"/>
  124. <addaction name="separator"/>
  125. <addaction name="actQuit"/>
  126. </widget>
  127. <widget class="QStatusBar" name="statusBar"/>
  128. <action name="actStart">
  129. <property name="icon">
  130. <iconset resource="res.qrc">
  131. <normaloff>:/images/images/620.bmp</normaloff>:/images/images/620.bmp</iconset>
  132. </property>
  133. <property name="text">
  134. <string>开始监听</string>
  135. </property>
  136. <property name="toolTip">
  137. <string>开始监听</string>
  138. </property>
  139. </action>
  140. <action name="actStop">
  141. <property name="enabled">
  142. <bool>false</bool>
  143. </property>
  144. <property name="icon">
  145. <iconset resource="res.qrc">
  146. <normaloff>:/images/images/624.bmp</normaloff>:/images/images/624.bmp</iconset>
  147. </property>
  148. <property name="text">
  149. <string>停止监听</string>
  150. </property>
  151. <property name="toolTip">
  152. <string>停止监听</string>
  153. </property>
  154. </action>
  155. <action name="actQuit">
  156. <property name="icon">
  157. <iconset resource="res.qrc">
  158. <normaloff>:/images/images/132.bmp</normaloff>:/images/images/132.bmp</iconset>
  159. </property>
  160. <property name="text">
  161. <string>退出</string>
  162. </property>
  163. <property name="toolTip">
  164. <string>退出本程序</string>
  165. </property>
  166. </action>
  167. <action name="actClear">
  168. <property name="icon">
  169. <iconset resource="res.qrc">
  170. <normaloff>:/images/images/212.bmp</normaloff>:/images/images/212.bmp</iconset>
  171. </property>
  172. <property name="text">
  173. <string>清空文本框</string>
  174. </property>
  175. <property name="toolTip">
  176. <string>清空文本框</string>
  177. </property>
  178. </action>
  179. <action name="actHostInfo">
  180. <property name="icon">
  181. <iconset resource="res.qrc">
  182. <normaloff>:/images/images/110.JPG</normaloff>:/images/images/110.JPG</iconset>
  183. </property>
  184. <property name="text">
  185. <string>本机地址</string>
  186. </property>
  187. <property name="toolTip">
  188. <string>获取本机地址</string>
  189. </property>
  190. </action>
  191. </widget>
  192. <layoutdefault spacing="6" margin="11"/>
  193. <resources>
  194. <include location="res.qrc"/>
  195. </resources>
  196. <connections>
  197. <connection>
  198. <sender>actQuit</sender>
  199. <signal>triggered()</signal>
  200. <receiver>MainWindow</receiver>
  201. <slot>close()</slot>
  202. <hints>
  203. <hint type="sourcelabel">
  204. <x>-1</x>
  205. <y>-1</y>
  206. </hint>
  207. <hint type="destinationlabel">
  208. <x>214</x>
  209. <y>164</y>
  210. </hint>
  211. </hints>
  212. </connection>
  213. </connections>
  214. </ui>