update 更新表格设置
This commit is contained in:
@ -3,7 +3,7 @@ from Model.Position import Real_Position, Detection_Position
|
||||
from enum import Enum
|
||||
from COM.COM_Robot import RobotClient
|
||||
from Model.RobotModel import CMDInstructRequest
|
||||
from Vision.camera_coordinate_dete import Detection
|
||||
#from Vision.camera_coordinate_dete import Detection
|
||||
|
||||
|
||||
class FeedStatus(Enum):
|
||||
@ -35,10 +35,11 @@ class FeedingConfig:
|
||||
|
||||
|
||||
class Feeding():
|
||||
def __init__(self,robotClient:RobotClient,detection:Detection):
|
||||
def __init__(self,robotClient:RobotClient,detection):
|
||||
self.feedConfig = None
|
||||
self.feedStatus = FeedStatus.FNone
|
||||
self.robotClient = robotClient
|
||||
self.detection = detection
|
||||
pass
|
||||
|
||||
def run(self):
|
||||
@ -90,14 +91,16 @@ class Feeding():
|
||||
|
||||
# 黄老师给我的xyz和法向量
|
||||
target_position, noraml_base = getPosition(*xyz, *uvw,rotation)
|
||||
self.feedConfig.feedLine.take_position = Real_Position().init_position(*target_position,*noraml_base)
|
||||
self.feedConfig.feedLine.take_position = Real_Position().init_position(*target_position[:3],*noraml_base)
|
||||
self.sendTargPosition(self.feedConfig.feedLine.take_position)
|
||||
else:
|
||||
print("打印日志,保存失败图像")
|
||||
pass # 发送拍照获取坐标 并 开始移动
|
||||
|
||||
|
||||
elif self.feedStatus == FeedStatus.FTake:
|
||||
if self.feedConfig.feedLine.take_position != None and self.feedConfig.feedLine.take_position.compare(real_position):
|
||||
self.feedStatus = FeedStatus.FSafeF
|
||||
self.sendTargPosition(self.feedConfig.feedLine.safe_position)
|
||||
pass #打开吸嘴并返回
|
||||
|
||||
elif self.feedStatus == FeedStatus.FSafeF:
|
||||
|
||||
@ -1,21 +1,21 @@
|
||||
[FeedLine1]
|
||||
SafePosition_x=0
|
||||
SafePosition_y=0
|
||||
SafePosition_z=0
|
||||
SafePosition_u=0
|
||||
SafePosition_v=0
|
||||
SafePosition_z=1
|
||||
SafePosition_u=2
|
||||
SafePosition_v=3
|
||||
SafePosition_w=0
|
||||
PhotoPosition_x=0
|
||||
PhotoPosition_y=0
|
||||
PhotoPosition_z=0
|
||||
PhotoPosition_u=0
|
||||
PhotoPosition_z=5
|
||||
PhotoPosition_u=4
|
||||
PhotoPosition_v=0
|
||||
PhotoPosition_w=0
|
||||
FeedPosition_x=0
|
||||
FeedPosition_y=0
|
||||
FeedPosition_z=0
|
||||
FeedPosition_y=7
|
||||
FeedPosition_z=6
|
||||
FeedPosition_u=0
|
||||
FeedPosition_v=0
|
||||
FeedPosition_v=7
|
||||
FeedPosition_w=0
|
||||
|
||||
|
||||
|
||||
@ -44,4 +44,5 @@ class Real_Position(Position):
|
||||
self.Z = Z
|
||||
self.U = U
|
||||
self.V = V
|
||||
self.W = W
|
||||
self.W = W
|
||||
return self
|
||||
@ -1,4 +1,8 @@
|
||||
from enum import Enum
|
||||
|
||||
from Model.Position import Real_Position
|
||||
|
||||
|
||||
class MoveType(Enum):
|
||||
AXIS = 4
|
||||
WORLD = 10
|
||||
@ -65,6 +69,10 @@ class DataAddress:
|
||||
self.axis_4 = float(a4)
|
||||
self.axis_5 = float(a5)
|
||||
|
||||
def getRealPosition(self):
|
||||
real_position = Real_Position().init_position(self.world_0,self.world_1,self.world_2,self.world_3,self.world_4,self.world_5)
|
||||
return real_position
|
||||
|
||||
|
||||
def setAngle(self,a0,a1,a2,a3,a4,a5):
|
||||
pass
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
|
||||
[Robot_Feed]
|
||||
IPAddress=192.168.3.5
|
||||
Port=8114
|
||||
Port=8113
|
||||
j1_min=-150
|
||||
j1_max=+150
|
||||
j2_min=-150
|
||||
|
||||
181
app.py
181
app.py
@ -3,15 +3,18 @@ import json
|
||||
import queue
|
||||
import sys
|
||||
from multiprocessing import Process
|
||||
|
||||
from PyQt5.uic.properties import QtWidgets
|
||||
from PySide6.QtCore import QThread, Signal, Slot, QObject, QEvent
|
||||
from PySide6.QtGui import QIntValidator, QStandardItemModel, QStandardItem, Qt
|
||||
from PySide6.QtWidgets import QApplication, QMainWindow, QPushButton, QLabel
|
||||
from PySide6.QtWidgets import QApplication, QMainWindow, QPushButton, QLabel, QHeaderView, QTableWidget, \
|
||||
QTableWidgetItem, QWidget, QHBoxLayout, QAbstractItemView
|
||||
from datetime import datetime
|
||||
|
||||
import Constant
|
||||
from CU.Command import FeedCommand
|
||||
from CU.Feeding import FeedLine, FeedingConfig, Feeding, FeedStatus
|
||||
from Vision.camera_coordinate_dete import Detection
|
||||
#from Vision.camera_coordinate_dete import Detection
|
||||
from ui_untitled import Ui_MainWindow
|
||||
from COM.COM_Robot import RobotClient
|
||||
from Expection import Error_Code
|
||||
@ -34,6 +37,7 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
self.init_Run()
|
||||
self.init_robot_info()
|
||||
self.init_FeedLine()
|
||||
|
||||
self.start_Runing()
|
||||
|
||||
|
||||
@ -80,51 +84,21 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
|
||||
# self.horizontalSlider_J1.sliderReleased
|
||||
self.pushButton_startFeed.clicked.connect(self.send_startFeed_button_click)
|
||||
self.pushButton_stack_feedSet.clicked.connect(self.send_stack_feedSet_button_click)
|
||||
self.pushButton_stack_feedControl.clicked.connect(lambda _, index=0: self.send_stack_feedSet_button_click(index))
|
||||
self.pushButton_stack_feedSet.clicked.connect(lambda _,index=1:self.send_stack_feedSet_button_click(index))
|
||||
|
||||
|
||||
self.horizontalSlider_feedingNum.blockSignals(True)
|
||||
self.horizontalSlider_feedingNum.setMinimum(0)
|
||||
|
||||
model = QStandardItemModel(4, 6, self) # 4行6列
|
||||
|
||||
# 设置第一层表头
|
||||
model.setHorizontalHeaderLabels(['', '个人信息', '', '', '工作信息', ''])
|
||||
|
||||
# 设置第二层表头
|
||||
itemA = QStandardItem("x")
|
||||
itemA.setTextAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||
model.setItem(0, 0, itemA)
|
||||
model.setItem(0, 1, QStandardItem("y"))
|
||||
model.setItem(0, 2, QStandardItem("z"))
|
||||
model.setItem(0, 3, QStandardItem("u"))
|
||||
model.setItem(0, 4, QStandardItem("v"))
|
||||
model.setItem(0, 5, QStandardItem("w"))
|
||||
|
||||
# 填充表格数据
|
||||
data = [
|
||||
["Alice", "25", "New York", "Developer", "ABC Corp", "$100,000"],
|
||||
["Bob", "30", "Los Angeles", "Designer", "XYZ Ltd", "$90,000"],
|
||||
["Charlie", "22", "Chicago", "Analyst", "MNO Inc", "$80,000"],
|
||||
["David", "28", "Miami", "Manager", "PQR LLC", "$110,000"]
|
||||
]
|
||||
|
||||
for row_idx, row_data in enumerate(data):
|
||||
for col_idx, item in enumerate(row_data):
|
||||
model.setItem(row_idx + 1, col_idx, QStandardItem(item))
|
||||
|
||||
# 合并单元格以创建多级表头效果
|
||||
self.tableView_feedSeting.setSpan(0, 0, 1, 3) # "个人信息" 跨越三列
|
||||
self.tableView_feedSeting.setSpan(0, 3, 1, 3) # "工作信息" 跨越三列
|
||||
|
||||
# 设置模型到表视图
|
||||
self.tableView_feedSeting.setModel(model)
|
||||
self.lineEdit_speed.hide()
|
||||
|
||||
|
||||
def init_Run(self):
|
||||
self.robotClient = None
|
||||
self.configReader = configparser.ConfigParser()
|
||||
self.detection = Detection()
|
||||
self.detection = None# Detection()
|
||||
self.command_position_quene = Queue()
|
||||
self.status_address = DataAddress()
|
||||
self.feedLine_dict = {}
|
||||
@ -138,6 +112,7 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
self.robotClient = RobotClient(ip, port, self.command_position_quene, self.status_address)
|
||||
self.feeding = Feeding(self.robotClient,self.detection) # 临时
|
||||
self.last_time=time.time()
|
||||
|
||||
try:
|
||||
self.robotClient.CreatConnect()
|
||||
except:
|
||||
@ -148,6 +123,71 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
else:
|
||||
return Error_Code.SYS_NETERROR
|
||||
|
||||
def init_seting_frame(self):
|
||||
|
||||
rows = len(self.feedLine_dict.keys())+2
|
||||
self.tableWidget_feedSeting.setRowCount(rows)
|
||||
self.tableWidget_feedSeting.setColumnCount(19)
|
||||
# 设置第一重表头的合并 (三列一组)
|
||||
self.tableWidget_feedSeting.setSpan(0, 1, 1, 6) # 合并前3列
|
||||
self.tableWidget_feedSeting.setSpan(0, 7, 1, 6) # 合并后3列
|
||||
self.tableWidget_feedSeting.setSpan(0, 13, 1, 6) # 合并后3列
|
||||
|
||||
|
||||
|
||||
btn_safe = QPushButton("获取安全位置")
|
||||
|
||||
widget_safe = QWidget()
|
||||
layout_safe = QHBoxLayout()
|
||||
layout_safe.addWidget(btn_safe)
|
||||
# 调整布局的间距,使之更紧凑
|
||||
layout_safe.setContentsMargins(0, 0, 0, 0)
|
||||
# 将布局设置到 QWidget 容器中
|
||||
widget_safe.setLayout(layout_safe)
|
||||
|
||||
btn_photo = QPushButton("获取拍照位置")
|
||||
widget_photo = QWidget()
|
||||
layout_photo = QHBoxLayout()
|
||||
layout_photo.addWidget(btn_photo)
|
||||
# 调整布局的间距,使之更紧凑
|
||||
layout_photo.setContentsMargins(0, 0, 0, 0)
|
||||
# 将布局设置到 QWidget 容器中
|
||||
widget_photo.setLayout(layout_photo)
|
||||
|
||||
|
||||
btn_feed = QPushButton("获取投料位置")
|
||||
widget_feed = QWidget()
|
||||
layout_feed = QHBoxLayout()
|
||||
layout_feed.addWidget(btn_feed)
|
||||
# 调整布局的间距,使之更紧凑
|
||||
layout_feed.setContentsMargins(0, 0, 0, 0)
|
||||
# 将布局设置到 QWidget 容器中
|
||||
widget_feed.setLayout(layout_feed)
|
||||
|
||||
|
||||
btn_safe.clicked.connect(self.send_get_safe_position_button_click)
|
||||
btn_photo.clicked.connect(self.send_get_photo_position_button_click)
|
||||
btn_feed.clicked.connect(self.send_get_feed_position_button_click)
|
||||
# 添加第一重表头项
|
||||
|
||||
self.tableWidget_feedSeting.setCellWidget(0, 1, widget_safe)
|
||||
self.tableWidget_feedSeting.setCellWidget(0, 7, widget_photo)
|
||||
self.tableWidget_feedSeting.setCellWidget(0, 13, widget_feed) # 设置在合并的第2组
|
||||
|
||||
self.tableWidget_feedSeting.setSelectionBehavior(QTableWidget.SelectRows)
|
||||
self.tableWidget_feedSeting.setAutoScroll(True)
|
||||
# 添加第二重表头
|
||||
self.tableWidget_feedSeting.setHorizontalHeaderLabels(['header','X1','Y1','Z1','U1','V1','W1','X2','Y2','Z2','U2','V2','W2','X3','Y3','Z3','U3','V3','W3'])
|
||||
self.tableWidget_feedSeting.hideColumn(0)
|
||||
# 填充数据行
|
||||
for row,(feed_line_key,feed_line)in enumerate(self.feedLine_dict.items()):
|
||||
self.tableWidget_feedSeting.setItem(row+1, 0, QTableWidgetItem(feed_line_key))
|
||||
self.set_position_to_tabel(row+1, 0, feed_line.safe_position)
|
||||
self.set_position_to_tabel(row+1, 1, feed_line.photo_position)
|
||||
self.set_position_to_tabel(row+1, 2, feed_line.feed_position)
|
||||
|
||||
# 禁用自动表头
|
||||
self.tableWidget_feedSeting.verticalHeader().setVisible(True)
|
||||
|
||||
def init_FeedLine(self):
|
||||
line_count = self.configReader.get('Robot_Feed', 'LineCount', fallback=0)
|
||||
@ -158,30 +198,30 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
photo_position = Real_Position()
|
||||
feed_position = Real_Position()
|
||||
|
||||
safe_position.X = int(self.configReader.get(line_str, 'SafePosition_x', fallback=0))
|
||||
safe_position.Y = int(self.configReader.get(line_str, 'SafePosition_y', fallback=0))
|
||||
safe_position.Z = int(self.configReader.get(line_str, 'SafePosition_z', fallback=0))
|
||||
safe_position.U = int(self.configReader.get(line_str, 'SafePosition_u', fallback=0))
|
||||
safe_position.V = int(self.configReader.get(line_str, 'SafePosition_v', fallback=0))
|
||||
safe_position.W = int(self.configReader.get(line_str, 'SafePosition_w', fallback=0))
|
||||
safe_position.X = float(self.configReader.get(line_str, 'SafePosition_x', fallback=0))
|
||||
safe_position.Y = float(self.configReader.get(line_str, 'SafePosition_y', fallback=0))
|
||||
safe_position.Z = float(self.configReader.get(line_str, 'SafePosition_z', fallback=0))
|
||||
safe_position.U = float(self.configReader.get(line_str, 'SafePosition_u', fallback=0))
|
||||
safe_position.V = float(self.configReader.get(line_str, 'SafePosition_v', fallback=0))
|
||||
safe_position.W = float(self.configReader.get(line_str, 'SafePosition_w', fallback=0))
|
||||
|
||||
photo_position.X = int(self.configReader.get(line_str, 'PhotoPosition_x', fallback=0))
|
||||
photo_position.Y = int(self.configReader.get(line_str, 'PhotoPosition_y', fallback=0))
|
||||
photo_position.Z = int(self.configReader.get(line_str, 'PhotoPosition_z', fallback=0))
|
||||
photo_position.U = int(self.configReader.get(line_str, 'PhotoPosition_u', fallback=0))
|
||||
photo_position.V = int(self.configReader.get(line_str, 'PhotoPosition_v', fallback=0))
|
||||
photo_position.W = int(self.configReader.get(line_str, 'PhotoPosition_w', fallback=0))
|
||||
photo_position.X = float(self.configReader.get(line_str, 'PhotoPosition_x', fallback=0))
|
||||
photo_position.Y = float(self.configReader.get(line_str, 'PhotoPosition_y', fallback=0))
|
||||
photo_position.Z = float(self.configReader.get(line_str, 'PhotoPosition_z', fallback=0))
|
||||
photo_position.U = float(self.configReader.get(line_str, 'PhotoPosition_u', fallback=0))
|
||||
photo_position.V = float(self.configReader.get(line_str, 'PhotoPosition_v', fallback=0))
|
||||
photo_position.W = float(self.configReader.get(line_str, 'PhotoPosition_w', fallback=0))
|
||||
|
||||
|
||||
feed_position.X = int(self.configReader.get(line_str, 'FeedPosition_x', fallback=0))
|
||||
feed_position.Y = int(self.configReader.get(line_str, 'FeedPosition_y', fallback=0))
|
||||
feed_position.Z = int(self.configReader.get(line_str, 'FeedPosition_z', fallback=0))
|
||||
feed_position.U = int(self.configReader.get(line_str, 'FeedPosition_u', fallback=0))
|
||||
feed_position.V = int(self.configReader.get(line_str, 'FeedPosition_v', fallback=0))
|
||||
feed_position.W = int(self.configReader.get(line_str, 'FeedPosition_w', fallback=0))
|
||||
feed_position.X = float(self.configReader.get(line_str, 'FeedPosition_x', fallback=0))
|
||||
feed_position.Y = float(self.configReader.get(line_str, 'FeedPosition_y', fallback=0))
|
||||
feed_position.Z = float(self.configReader.get(line_str, 'FeedPosition_z', fallback=0))
|
||||
feed_position.U = float(self.configReader.get(line_str, 'FeedPosition_u', fallback=0))
|
||||
feed_position.V = float(self.configReader.get(line_str, 'FeedPosition_v', fallback=0))
|
||||
feed_position.W = float(self.configReader.get(line_str, 'FeedPosition_w', fallback=0))
|
||||
|
||||
self.feedLine_dict[str(i+1)] = FeedLine(safe_position, photo_position, feed_position)
|
||||
|
||||
self.init_seting_frame()
|
||||
pass
|
||||
|
||||
def init_robot_info(self):
|
||||
@ -316,8 +356,8 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
self.horizontalSlider_feedingNum.setValue(0)
|
||||
self.label_maxNum.setText(self.lineEdit_num.text())
|
||||
|
||||
def send_stack_feedSet_button_click(self):
|
||||
self.stackedWidget_feed.setCurrentIndex(1)
|
||||
def send_stack_feedSet_button_click(self,index):
|
||||
self.stackedWidget_feed.setCurrentIndex(index)
|
||||
|
||||
|
||||
|
||||
@ -366,6 +406,25 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
print(request_command)
|
||||
self.robotClient.add_sendQuene(request_command)
|
||||
|
||||
def send_get_safe_position_button_click(self):
|
||||
real_position = self.robotClient.status_model.getRealPosition()
|
||||
row_i = self.tableWidget_feedSeting.currentRow()
|
||||
head = self.tableWidget_feedSeting.item(row_i, 0).text()
|
||||
self.feedLine_dict[head].safe_position.init_position(real_position.X,real_position.Y,real_position.Z,real_position.U,real_position.V,real_position.W)
|
||||
self.set_position_to_tabel(row_i,0,real_position)
|
||||
|
||||
def send_get_photo_position_button_click(self):
|
||||
real_position = self.robotClient.status_model.getRealPosition()
|
||||
row_i = self.tableWidget_feedSeting.currentRow()
|
||||
head = self.tableWidget_feedSeting.item(row_i, 0).text()
|
||||
self.feedLine_dict[head].photo_position.init_position(real_position.X, real_position.Y, real_position.Z, real_position.U, real_position.V, real_position.W)
|
||||
self.set_position_to_tabel(row_i, 1, real_position)
|
||||
def send_get_feed_position_button_click(self):
|
||||
real_position = self.robotClient.status_model.getRealPosition()
|
||||
row_i = self.tableWidget_feedSeting.currentRow()
|
||||
head = self.tableWidget_feedSeting.item(row_i, 0).text()
|
||||
self.feedLine_dict[head].feed_position.init_position(real_position.X, real_position.Y, real_position.Z, real_position.U, real_position.V, real_position.W)
|
||||
self.set_position_to_tabel(row_i, 2, real_position)
|
||||
|
||||
def run(self):
|
||||
while True:
|
||||
@ -417,7 +476,13 @@ class MainWindow(QMainWindow,Ui_MainWindow):
|
||||
self.label_j5.setText(str(self.status_address.axis_4))
|
||||
self.label_j6.setText(str(self.status_address.axis_5))
|
||||
|
||||
|
||||
def set_position_to_tabel(self,row_i,position_j,real_Position:Real_Position):
|
||||
self.tableWidget_feedSeting.setItem(row_i, position_j*6+1, QTableWidgetItem(str(real_Position.X)))
|
||||
self.tableWidget_feedSeting.setItem(row_i, position_j*6+1+1, QTableWidgetItem(str(real_Position.Y)))
|
||||
self.tableWidget_feedSeting.setItem(row_i, position_j*6+2+1, QTableWidgetItem(str(real_Position.Z)))
|
||||
self.tableWidget_feedSeting.setItem(row_i, position_j*6+3+1, QTableWidgetItem(str(real_Position.U)))
|
||||
self.tableWidget_feedSeting.setItem(row_i, position_j*6+4+1, QTableWidgetItem(str(real_Position.V)))
|
||||
self.tableWidget_feedSeting.setItem(row_i, position_j*6+5+1, QTableWidgetItem(str(real_Position.W)))
|
||||
|
||||
def set_label_status_style(self, connected: bool):
|
||||
if connected:
|
||||
|
||||
@ -18,7 +18,7 @@ from PySide6.QtGui import (QBrush, QColor, QConicalGradient, QCursor,
|
||||
from PySide6.QtWidgets import (QApplication, QComboBox, QFrame, QHeaderView,
|
||||
QLabel, QLineEdit, QMainWindow, QPushButton,
|
||||
QSizePolicy, QSlider, QStackedWidget, QTabWidget,
|
||||
QTableView, QTextEdit, QWidget)
|
||||
QTableWidget, QTableWidgetItem, QTextEdit, QWidget)
|
||||
import resources_rc
|
||||
|
||||
class Ui_MainWindow(object):
|
||||
@ -163,10 +163,10 @@ class Ui_MainWindow(object):
|
||||
"\n"
|
||||
"")
|
||||
self.horizontalSlider_feedingNum.setOrientation(Qt.Orientation.Horizontal)
|
||||
self.label_maxNum_2 = QLabel(self.frame_6)
|
||||
self.label_maxNum_2.setObjectName(u"label_maxNum_2")
|
||||
self.label_maxNum_2.setGeometry(QRect(800, 160, 31, 21))
|
||||
self.label_maxNum_2.setStyleSheet(u"font: 9pt \"\u6977\u4f53\";")
|
||||
self.label_maxNum = QLabel(self.frame_6)
|
||||
self.label_maxNum.setObjectName(u"label_maxNum")
|
||||
self.label_maxNum.setGeometry(QRect(800, 160, 31, 21))
|
||||
self.label_maxNum.setStyleSheet(u"font: 9pt \"\u6977\u4f53\";")
|
||||
self.frame_7 = QFrame(self.frame_6)
|
||||
self.frame_7.setObjectName(u"frame_7")
|
||||
self.frame_7.setGeometry(QRect(500, 190, 331, 281))
|
||||
@ -808,33 +808,9 @@ class Ui_MainWindow(object):
|
||||
self.stackedWidget_feed.addWidget(self.page_6)
|
||||
self.page_7 = QWidget()
|
||||
self.page_7.setObjectName(u"page_7")
|
||||
self.tableView_feedSeting = QTableView(self.page_7)
|
||||
self.tableView_feedSeting.setObjectName(u"tableView_feedSeting")
|
||||
self.tableView_feedSeting.setGeometry(QRect(20, 10, 871, 461))
|
||||
self.tableView_feedSeting.setStyleSheet(u"QTableWidget {\n"
|
||||
" background-color: #f0f0f0; /* \u8868\u683c\u80cc\u666f\u8272 */\n"
|
||||
" gridline-color: #d0d0d0; /* \u7f51\u683c\u7ebf\u989c\u8272 */\n"
|
||||
" border: 1px solid #d0d0d0; /* \u8fb9\u6846\u989c\u8272 */\n"
|
||||
" }\n"
|
||||
" QTableWidget::item {\n"
|
||||
" padding: 10px; /* \u5355\u5143\u683c\u5185\u8fb9\u8ddd */\n"
|
||||
" border: none; /* \u5355\u5143\u683c\u8fb9\u6846 */\n"
|
||||
" }\n"
|
||||
" QTableWidget::item:selected {\n"
|
||||
" background-color: #a0a0ff; /* \u9009\u4e2d\u5355\u5143\u683c\u80cc\u666f\u8272 */\n"
|
||||
" color: white; /* \u9009\u4e2d\u5355\u5143\u683c\u5b57\u4f53\u989c\u8272 */\n"
|
||||
" }\n"
|
||||
" QHeaderView::section {\n"
|
||||
" background-color: #d0d0ff; /* \u8868\u5934\u80cc\u666f\u8272 */\n"
|
||||
" color: black; /* \u8868\u5934\u5b57\u4f53\u989c\u8272 */\n"
|
||||
" p"
|
||||
"adding: 5px; /* \u8868\u5934\u5185\u8fb9\u8ddd */\n"
|
||||
" border: 1px solid #d0d0d0; /* \u8868\u5934\u8fb9\u6846\u989c\u8272 */\n"
|
||||
" }\n"
|
||||
" QTableCornerButton::section {\n"
|
||||
" background-color: #d0d0ff; /* \u5de6\u4e0a\u89d2\u6309\u94ae\u7684\u80cc\u666f\u8272 */\n"
|
||||
" border: 1px solid #d0d0d0; /* \u5de6\u4e0a\u89d2\u6309\u94ae\u7684\u8fb9\u6846\u989c\u8272 */\n"
|
||||
" }")
|
||||
self.tableWidget_feedSeting = QTableWidget(self.page_7)
|
||||
self.tableWidget_feedSeting.setObjectName(u"tableWidget_feedSeting")
|
||||
self.tableWidget_feedSeting.setGeometry(QRect(10, 10, 871, 501))
|
||||
self.stackedWidget_feed.addWidget(self.page_7)
|
||||
self.tabWidget.addTab(self.tab, "")
|
||||
self.tab_2 = QWidget()
|
||||
@ -889,7 +865,7 @@ class Ui_MainWindow(object):
|
||||
self.retranslateUi(MainWindow)
|
||||
|
||||
self.tabWidget.setCurrentIndex(0)
|
||||
self.stackedWidget_feed.setCurrentIndex(0)
|
||||
self.stackedWidget_feed.setCurrentIndex(1)
|
||||
self.stackedWidget_num.setCurrentIndex(0)
|
||||
|
||||
|
||||
@ -903,7 +879,7 @@ class Ui_MainWindow(object):
|
||||
self.pushButton_stack_feedSet.setText(QCoreApplication.translate("MainWindow", u"\u6295\u6599\u8bbe\u7f6e", None))
|
||||
self.pushButton_8.setText(QCoreApplication.translate("MainWindow", u"IO\u8c03\u8bd5", None))
|
||||
self.label_5.setText("")
|
||||
self.label_maxNum_2.setText(QCoreApplication.translate("MainWindow", u"10", None))
|
||||
self.label_maxNum.setText(QCoreApplication.translate("MainWindow", u"10", None))
|
||||
self.label_j1_min.setText(QCoreApplication.translate("MainWindow", u"-10", None))
|
||||
self.label_j1_max.setText(QCoreApplication.translate("MainWindow", u"+10", None))
|
||||
self.label_j2_min.setText(QCoreApplication.translate("MainWindow", u"-150", None))
|
||||
|
||||
33
untitled.ui
33
untitled.ui
@ -125,7 +125,7 @@ border-radius: 10px;</string>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
<number>1</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="page_6">
|
||||
<widget class="QFrame" name="frame_2">
|
||||
@ -1757,40 +1757,15 @@ font: 10pt "楷体";
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="page_7">
|
||||
<widget class="QTableView" name="tableView_feedSeting">
|
||||
<widget class="QTableWidget" name="tableWidget_feedSeting">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>871</width>
|
||||
<height>461</height>
|
||||
<height>501</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">QTableWidget {
|
||||
background-color: #f0f0f0; /* 表格背景色 */
|
||||
gridline-color: #d0d0d0; /* 网格线颜色 */
|
||||
border: 1px solid #d0d0d0; /* 边框颜色 */
|
||||
}
|
||||
QTableWidget::item {
|
||||
padding: 10px; /* 单元格内边距 */
|
||||
border: none; /* 单元格边框 */
|
||||
}
|
||||
QTableWidget::item:selected {
|
||||
background-color: #a0a0ff; /* 选中单元格背景色 */
|
||||
color: white; /* 选中单元格字体颜色 */
|
||||
}
|
||||
QHeaderView::section {
|
||||
background-color: #d0d0ff; /* 表头背景色 */
|
||||
color: black; /* 表头字体颜色 */
|
||||
padding: 5px; /* 表头内边距 */
|
||||
border: 1px solid #d0d0d0; /* 表头边框颜色 */
|
||||
}
|
||||
QTableCornerButton::section {
|
||||
background-color: #d0d0ff; /* 左上角按钮的背景色 */
|
||||
border: 1px solid #d0d0d0; /* 左上角按钮的边框颜色 */
|
||||
}</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
</widget>
|
||||
|
||||
Reference in New Issue
Block a user