mainwidget.ui 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <ui version="4.0">
  3. <class>MainWidget</class>
  4. <widget class="QWidget" name="MainWidget">
  5. <property name="geometry">
  6. <rect>
  7. <x>0</x>
  8. <y>0</y>
  9. <width>967</width>
  10. <height>705</height>
  11. </rect>
  12. </property>
  13. <property name="windowTitle">
  14. <string>MainWidget</string>
  15. </property>
  16. <layout class="QVBoxLayout" name="verticalLayout_3" stretch="1,0,8">
  17. <item>
  18. <layout class="QHBoxLayout" name="horizontalLayout">
  19. <item>
  20. <widget class="QLabel" name="label_Logo">
  21. <property name="text">
  22. <string>SmartPDU</string>
  23. </property>
  24. </widget>
  25. </item>
  26. <item>
  27. <spacer name="horizontalSpacer">
  28. <property name="orientation">
  29. <enum>Qt::Horizontal</enum>
  30. </property>
  31. <property name="sizeHint" stdset="0">
  32. <size>
  33. <width>40</width>
  34. <height>20</height>
  35. </size>
  36. </property>
  37. </spacer>
  38. </item>
  39. <item>
  40. <widget class="QPushButton" name="pb_Debug">
  41. <property name="text">
  42. <string>调试模式</string>
  43. </property>
  44. </widget>
  45. </item>
  46. <item>
  47. <widget class="QLabel" name="label_2">
  48. <property name="text">
  49. <string>温度:</string>
  50. </property>
  51. </widget>
  52. </item>
  53. <item>
  54. <widget class="QLabel" name="label_3">
  55. <property name="text">
  56. <string>0</string>
  57. </property>
  58. <property name="alignment">
  59. <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  60. </property>
  61. </widget>
  62. </item>
  63. <item>
  64. <widget class="QLabel" name="label_5">
  65. <property name="text">
  66. <string>°C</string>
  67. </property>
  68. </widget>
  69. </item>
  70. <item>
  71. <widget class="QLabel" name="label">
  72. <property name="text">
  73. <string>湿度</string>
  74. </property>
  75. </widget>
  76. </item>
  77. <item>
  78. <widget class="QLabel" name="label_4">
  79. <property name="text">
  80. <string>0</string>
  81. </property>
  82. <property name="alignment">
  83. <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
  84. </property>
  85. </widget>
  86. </item>
  87. <item>
  88. <widget class="QLabel" name="label_6">
  89. <property name="text">
  90. <string>%</string>
  91. </property>
  92. </widget>
  93. </item>
  94. <item>
  95. <layout class="QVBoxLayout" name="verticalLayout">
  96. <item>
  97. <widget class="QLabel" name="label_Date">
  98. <property name="text">
  99. <string>2024年11月9日</string>
  100. </property>
  101. </widget>
  102. </item>
  103. <item>
  104. <widget class="QLabel" name="label_Time">
  105. <property name="text">
  106. <string>18:00:00</string>
  107. </property>
  108. <property name="alignment">
  109. <set>Qt::AlignCenter</set>
  110. </property>
  111. </widget>
  112. </item>
  113. </layout>
  114. </item>
  115. </layout>
  116. </item>
  117. <item>
  118. <widget class="Line" name="line_2">
  119. <property name="orientation">
  120. <enum>Qt::Horizontal</enum>
  121. </property>
  122. </widget>
  123. </item>
  124. <item>
  125. <widget class="QStackedWidget" name="stackedWidget">
  126. <property name="currentIndex">
  127. <number>1</number>
  128. </property>
  129. <widget class="QWidget" name="page">
  130. <layout class="QVBoxLayout" name="verticalLayout_4">
  131. <property name="spacing">
  132. <number>0</number>
  133. </property>
  134. <property name="leftMargin">
  135. <number>0</number>
  136. </property>
  137. <property name="topMargin">
  138. <number>0</number>
  139. </property>
  140. <property name="rightMargin">
  141. <number>0</number>
  142. </property>
  143. <property name="bottomMargin">
  144. <number>0</number>
  145. </property>
  146. <item>
  147. <layout class="QHBoxLayout" name="horizontalLayout_5" stretch="1,0,6">
  148. <item>
  149. <layout class="QVBoxLayout" name="verticalLayout_2" stretch="3,0,8,0,8,1,3">
  150. <item>
  151. <layout class="QHBoxLayout" name="horizontalLayout_2">
  152. <item>
  153. <widget class="QPushButton" name="pushButton">
  154. <property name="text">
  155. <string>L1</string>
  156. </property>
  157. </widget>
  158. </item>
  159. <item>
  160. <widget class="QPushButton" name="pushButton_2">
  161. <property name="text">
  162. <string>L2</string>
  163. </property>
  164. </widget>
  165. </item>
  166. <item>
  167. <widget class="QPushButton" name="pushButton_3">
  168. <property name="text">
  169. <string>L3</string>
  170. </property>
  171. </widget>
  172. </item>
  173. </layout>
  174. </item>
  175. <item>
  176. <widget class="QLabel" name="label_7">
  177. <property name="text">
  178. <string>总电压</string>
  179. </property>
  180. <property name="alignment">
  181. <set>Qt::AlignCenter</set>
  182. </property>
  183. </widget>
  184. </item>
  185. <item>
  186. <widget class="QGraphicsView" name="graphicsView"/>
  187. </item>
  188. <item>
  189. <widget class="QLabel" name="label_8">
  190. <property name="text">
  191. <string>总电流</string>
  192. </property>
  193. <property name="alignment">
  194. <set>Qt::AlignCenter</set>
  195. </property>
  196. </widget>
  197. </item>
  198. <item>
  199. <widget class="QGraphicsView" name="graphicsView_2"/>
  200. </item>
  201. <item>
  202. <layout class="QHBoxLayout" name="horizontalLayout_3">
  203. <item>
  204. <widget class="QLabel" name="label_9">
  205. <property name="text">
  206. <string>功率:</string>
  207. </property>
  208. </widget>
  209. </item>
  210. <item>
  211. <widget class="QLineEdit" name="lineEdit"/>
  212. </item>
  213. <item>
  214. <widget class="QLabel" name="label_10">
  215. <property name="text">
  216. <string>W</string>
  217. </property>
  218. </widget>
  219. </item>
  220. <item>
  221. <spacer name="horizontalSpacer_2">
  222. <property name="orientation">
  223. <enum>Qt::Horizontal</enum>
  224. </property>
  225. <property name="sizeHint" stdset="0">
  226. <size>
  227. <width>40</width>
  228. <height>20</height>
  229. </size>
  230. </property>
  231. </spacer>
  232. </item>
  233. <item>
  234. <widget class="QLabel" name="label_11">
  235. <property name="text">
  236. <string>耗电量:</string>
  237. </property>
  238. </widget>
  239. </item>
  240. <item>
  241. <widget class="QLineEdit" name="lineEdit_2"/>
  242. </item>
  243. <item>
  244. <widget class="QLabel" name="label_12">
  245. <property name="text">
  246. <string>Kw/h</string>
  247. </property>
  248. </widget>
  249. </item>
  250. </layout>
  251. </item>
  252. <item>
  253. <layout class="QHBoxLayout" name="horizontalLayout_4">
  254. <item>
  255. <widget class="QPushButton" name="pushButton_5">
  256. <property name="text">
  257. <string>全开</string>
  258. </property>
  259. </widget>
  260. </item>
  261. <item>
  262. <widget class="QPushButton" name="pushButton_4">
  263. <property name="text">
  264. <string>全关</string>
  265. </property>
  266. </widget>
  267. </item>
  268. </layout>
  269. </item>
  270. </layout>
  271. </item>
  272. <item>
  273. <widget class="Line" name="line">
  274. <property name="orientation">
  275. <enum>Qt::Vertical</enum>
  276. </property>
  277. </widget>
  278. </item>
  279. <item>
  280. <widget class="QTableWidget" name="tableWidget"/>
  281. </item>
  282. </layout>
  283. </item>
  284. </layout>
  285. </widget>
  286. <widget class="QWidget" name="page_2">
  287. <layout class="QVBoxLayout" name="verticalLayout_5" stretch="1,0,2">
  288. <item>
  289. <layout class="QHBoxLayout" name="horizontalLayout_10" stretch="0,0,0">
  290. <item>
  291. <layout class="QVBoxLayout" name="verticalLayout_6">
  292. <item>
  293. <widget class="QPushButton" name="pushButton_8">
  294. <property name="text">
  295. <string>L3</string>
  296. </property>
  297. </widget>
  298. </item>
  299. <item>
  300. <widget class="QPushButton" name="pushButton_7">
  301. <property name="text">
  302. <string>L2</string>
  303. </property>
  304. </widget>
  305. </item>
  306. <item>
  307. <widget class="QPushButton" name="pushButton_6">
  308. <property name="text">
  309. <string>L1</string>
  310. </property>
  311. </widget>
  312. </item>
  313. </layout>
  314. </item>
  315. <item>
  316. <layout class="QVBoxLayout" name="verticalLayout_9">
  317. <item>
  318. <layout class="QHBoxLayout" name="horizontalLayout_6">
  319. <item>
  320. <layout class="QVBoxLayout" name="verticalLayout_10">
  321. <item>
  322. <widget class="QLabel" name="label_13">
  323. <property name="text">
  324. <string>总电压</string>
  325. </property>
  326. <property name="alignment">
  327. <set>Qt::AlignCenter</set>
  328. </property>
  329. </widget>
  330. </item>
  331. <item>
  332. <widget class="QGraphicsView" name="graphicsView_3"/>
  333. </item>
  334. </layout>
  335. </item>
  336. <item>
  337. <layout class="QVBoxLayout" name="verticalLayout_8">
  338. <item>
  339. <widget class="QLabel" name="label_14">
  340. <property name="text">
  341. <string>总电流</string>
  342. </property>
  343. <property name="alignment">
  344. <set>Qt::AlignCenter</set>
  345. </property>
  346. </widget>
  347. </item>
  348. <item>
  349. <widget class="QGraphicsView" name="graphicsView_4"/>
  350. </item>
  351. </layout>
  352. </item>
  353. </layout>
  354. </item>
  355. <item>
  356. <layout class="QHBoxLayout" name="horizontalLayout_8">
  357. <item>
  358. <spacer name="horizontalSpacer_4">
  359. <property name="orientation">
  360. <enum>Qt::Horizontal</enum>
  361. </property>
  362. <property name="sizeHint" stdset="0">
  363. <size>
  364. <width>40</width>
  365. <height>20</height>
  366. </size>
  367. </property>
  368. </spacer>
  369. </item>
  370. <item>
  371. <widget class="QLabel" name="label_15">
  372. <property name="text">
  373. <string>功率:</string>
  374. </property>
  375. </widget>
  376. </item>
  377. <item>
  378. <widget class="QLineEdit" name="lineEdit_3"/>
  379. </item>
  380. <item>
  381. <widget class="QLabel" name="label_16">
  382. <property name="text">
  383. <string>W</string>
  384. </property>
  385. </widget>
  386. </item>
  387. <item>
  388. <spacer name="horizontalSpacer_3">
  389. <property name="orientation">
  390. <enum>Qt::Horizontal</enum>
  391. </property>
  392. <property name="sizeHint" stdset="0">
  393. <size>
  394. <width>40</width>
  395. <height>20</height>
  396. </size>
  397. </property>
  398. </spacer>
  399. </item>
  400. <item>
  401. <widget class="QLabel" name="label_17">
  402. <property name="text">
  403. <string>耗电量:</string>
  404. </property>
  405. </widget>
  406. </item>
  407. <item>
  408. <widget class="QLineEdit" name="lineEdit_4"/>
  409. </item>
  410. <item>
  411. <widget class="QLabel" name="label_18">
  412. <property name="text">
  413. <string>Kw/h</string>
  414. </property>
  415. </widget>
  416. </item>
  417. <item>
  418. <spacer name="horizontalSpacer_5">
  419. <property name="orientation">
  420. <enum>Qt::Horizontal</enum>
  421. </property>
  422. <property name="sizeHint" stdset="0">
  423. <size>
  424. <width>40</width>
  425. <height>20</height>
  426. </size>
  427. </property>
  428. </spacer>
  429. </item>
  430. </layout>
  431. </item>
  432. </layout>
  433. </item>
  434. <item>
  435. <layout class="QVBoxLayout" name="verticalLayout_7">
  436. <item>
  437. <widget class="QPushButton" name="pushButton_10">
  438. <property name="text">
  439. <string>全关</string>
  440. </property>
  441. </widget>
  442. </item>
  443. <item>
  444. <widget class="QPushButton" name="pushButton_9">
  445. <property name="text">
  446. <string>全开</string>
  447. </property>
  448. </widget>
  449. </item>
  450. </layout>
  451. </item>
  452. </layout>
  453. </item>
  454. <item>
  455. <widget class="Line" name="line_3">
  456. <property name="orientation">
  457. <enum>Qt::Horizontal</enum>
  458. </property>
  459. </widget>
  460. </item>
  461. <item>
  462. <widget class="QTableWidget" name="tableWidget_2"/>
  463. </item>
  464. </layout>
  465. </widget>
  466. <widget class="QWidget" name="page_3">
  467. <layout class="QGridLayout" name="gridLayout" rowstretch="2,1,0" columnstretch="3,1">
  468. <item row="0" column="0">
  469. <widget class="QGroupBox" name="groupBox">
  470. <property name="title">
  471. <string>数据接收</string>
  472. </property>
  473. <layout class="QVBoxLayout" name="verticalLayout_12">
  474. <item>
  475. <widget class="QPlainTextEdit" name="recive_Edit"/>
  476. </item>
  477. </layout>
  478. </widget>
  479. </item>
  480. <item row="0" column="1" rowspan="2">
  481. <layout class="QVBoxLayout" name="verticalLayout_11" stretch="1,0,0">
  482. <item>
  483. <widget class="QGroupBox" name="groupBox_2">
  484. <property name="title">
  485. <string>串口设置</string>
  486. </property>
  487. <layout class="QGridLayout" name="gridLayout_2" columnstretch="0,1">
  488. <item row="2" column="0">
  489. <widget class="QLabel" name="label_21">
  490. <property name="text">
  491. <string>数 据 位</string>
  492. </property>
  493. <property name="alignment">
  494. <set>Qt::AlignCenter</set>
  495. </property>
  496. </widget>
  497. </item>
  498. <item row="3" column="0">
  499. <widget class="QLabel" name="label_22">
  500. <property name="text">
  501. <string>停 止 位</string>
  502. </property>
  503. <property name="alignment">
  504. <set>Qt::AlignCenter</set>
  505. </property>
  506. </widget>
  507. </item>
  508. <item row="2" column="1">
  509. <widget class="QComboBox" name="databit_CB">
  510. <item>
  511. <property name="text">
  512. <string>8</string>
  513. </property>
  514. </item>
  515. <item>
  516. <property name="text">
  517. <string>7</string>
  518. </property>
  519. </item>
  520. <item>
  521. <property name="text">
  522. <string>6</string>
  523. </property>
  524. </item>
  525. <item>
  526. <property name="text">
  527. <string>5</string>
  528. </property>
  529. </item>
  530. </widget>
  531. </item>
  532. <item row="4" column="0">
  533. <widget class="QLabel" name="label_23">
  534. <property name="text">
  535. <string>校 验 位</string>
  536. </property>
  537. <property name="alignment">
  538. <set>Qt::AlignCenter</set>
  539. </property>
  540. </widget>
  541. </item>
  542. <item row="1" column="0">
  543. <widget class="QLabel" name="label_20">
  544. <property name="text">
  545. <string>波 特 率</string>
  546. </property>
  547. <property name="alignment">
  548. <set>Qt::AlignCenter</set>
  549. </property>
  550. </widget>
  551. </item>
  552. <item row="3" column="1">
  553. <widget class="QComboBox" name="stopbit_CB">
  554. <item>
  555. <property name="text">
  556. <string>1</string>
  557. </property>
  558. </item>
  559. <item>
  560. <property name="text">
  561. <string>1.5</string>
  562. </property>
  563. </item>
  564. <item>
  565. <property name="text">
  566. <string>2</string>
  567. </property>
  568. </item>
  569. </widget>
  570. </item>
  571. <item row="0" column="0">
  572. <widget class="QLabel" name="label_19">
  573. <property name="text">
  574. <string>端 口</string>
  575. </property>
  576. <property name="alignment">
  577. <set>Qt::AlignCenter</set>
  578. </property>
  579. </widget>
  580. </item>
  581. <item row="0" column="1">
  582. <widget class="QComboBox" name="serialCB"/>
  583. </item>
  584. <item row="1" column="1">
  585. <widget class="QComboBox" name="baudrate_CB">
  586. <item>
  587. <property name="text">
  588. <string>1200</string>
  589. </property>
  590. </item>
  591. <item>
  592. <property name="text">
  593. <string>2400</string>
  594. </property>
  595. </item>
  596. <item>
  597. <property name="text">
  598. <string>4800</string>
  599. </property>
  600. </item>
  601. <item>
  602. <property name="text">
  603. <string>9600</string>
  604. </property>
  605. </item>
  606. <item>
  607. <property name="text">
  608. <string>19200</string>
  609. </property>
  610. </item>
  611. <item>
  612. <property name="text">
  613. <string>38400</string>
  614. </property>
  615. </item>
  616. <item>
  617. <property name="text">
  618. <string>57600</string>
  619. </property>
  620. </item>
  621. <item>
  622. <property name="text">
  623. <string>115200</string>
  624. </property>
  625. </item>
  626. </widget>
  627. </item>
  628. <item row="5" column="0" colspan="2">
  629. <widget class="QPushButton" name="Button_checkserial">
  630. <property name="text">
  631. <string>检测串口</string>
  632. </property>
  633. </widget>
  634. </item>
  635. <item row="4" column="1">
  636. <widget class="QComboBox" name="checkbit_CB">
  637. <item>
  638. <property name="text">
  639. <string>无</string>
  640. </property>
  641. </item>
  642. <item>
  643. <property name="text">
  644. <string>Odd</string>
  645. </property>
  646. </item>
  647. <item>
  648. <property name="text">
  649. <string>Even</string>
  650. </property>
  651. </item>
  652. </widget>
  653. </item>
  654. <item row="6" column="0" colspan="2">
  655. <widget class="QPushButton" name="Button_openserial">
  656. <property name="text">
  657. <string>打开串口</string>
  658. </property>
  659. </widget>
  660. </item>
  661. </layout>
  662. </widget>
  663. </item>
  664. <item>
  665. <widget class="QGroupBox" name="groupBox_3">
  666. <property name="title">
  667. <string>接收设置</string>
  668. </property>
  669. <layout class="QGridLayout" name="gridLayout_4">
  670. <item row="0" column="0">
  671. <widget class="QCheckBox" name="check_hex_recive">
  672. <property name="text">
  673. <string>HEX接收</string>
  674. </property>
  675. </widget>
  676. </item>
  677. <item row="0" column="1">
  678. <widget class="QCheckBox" name="check_changeline">
  679. <property name="text">
  680. <string>自动换行</string>
  681. </property>
  682. </widget>
  683. </item>
  684. <item row="1" column="0">
  685. <widget class="QCheckBox" name="check_timestamp">
  686. <property name="text">
  687. <string>时间戳</string>
  688. </property>
  689. </widget>
  690. </item>
  691. <item row="1" column="1">
  692. <widget class="QPushButton" name="Button_clearrecive">
  693. <property name="text">
  694. <string>清空接收</string>
  695. </property>
  696. </widget>
  697. </item>
  698. </layout>
  699. </widget>
  700. </item>
  701. <item>
  702. <widget class="QGroupBox" name="groupBox_4">
  703. <property name="title">
  704. <string>发送设置</string>
  705. </property>
  706. <layout class="QGridLayout" name="gridLayout_3" columnstretch="2,1,1">
  707. <item row="0" column="0">
  708. <widget class="QCheckBox" name="check_hexsend">
  709. <property name="text">
  710. <string>HEX发送</string>
  711. </property>
  712. </widget>
  713. </item>
  714. <item row="0" column="1" colspan="2">
  715. <widget class="QCheckBox" name="check_sendnewline">
  716. <property name="text">
  717. <string>发送新行</string>
  718. </property>
  719. </widget>
  720. </item>
  721. <item row="1" column="0">
  722. <widget class="QCheckBox" name="check_autosend">
  723. <property name="text">
  724. <string>自动发送</string>
  725. </property>
  726. </widget>
  727. </item>
  728. <item row="1" column="1">
  729. <widget class="QSpinBox" name="spin_sendtime"/>
  730. </item>
  731. <item row="1" column="2">
  732. <widget class="QLabel" name="label_24">
  733. <property name="text">
  734. <string>ms</string>
  735. </property>
  736. </widget>
  737. </item>
  738. <item row="2" column="0">
  739. <widget class="QPushButton" name="Button_tx">
  740. <property name="text">
  741. <string>发送</string>
  742. </property>
  743. </widget>
  744. </item>
  745. <item row="2" column="1" colspan="2">
  746. <widget class="QPushButton" name="Button_cleartx">
  747. <property name="text">
  748. <string>清空</string>
  749. </property>
  750. </widget>
  751. </item>
  752. </layout>
  753. </widget>
  754. </item>
  755. </layout>
  756. </item>
  757. <item row="1" column="0">
  758. <widget class="QGroupBox" name="groupBox_5">
  759. <property name="title">
  760. <string>数据发送</string>
  761. </property>
  762. <layout class="QVBoxLayout" name="verticalLayout_13">
  763. <item>
  764. <widget class="QPlainTextEdit" name="send_Edit"/>
  765. </item>
  766. </layout>
  767. </widget>
  768. </item>
  769. <item row="2" column="0">
  770. <layout class="QHBoxLayout" name="horizontalLayout_7"/>
  771. </item>
  772. </layout>
  773. </widget>
  774. </widget>
  775. </item>
  776. </layout>
  777. </widget>
  778. <resources/>
  779. <connections/>
  780. </ui>