from PyQt5 import QtCore, QtGui, QtWidgets
import sys, time,os
import qtawesome
from PyQt5.QtWidgets import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
# 图片二进制化
image = b'\x89PNG\r\n\x1a\n\x00\x00\x00\rIHDR\x00\x00\x00\xc8\x00\x00\x00\xc8\x08\x06\x00\x00\x00\xadX\xae\x9e\x00' \
b'\x00\x11\x0fIDATx^\xed\x9dylU\xc5\x17\xc7O\x03A\x16QA\xd9\xca"R\x16\x85\xba"\x15\\JT\x90U\x92\xa2\x82%\xe8' \
b'\x1f\xe2\x06\x05\x81\x08\xc6"\xad\x11\xb0\x80\xd4\x18\x81\x04\x04\nh\x02\x88\xca\x12\x8dF\xc5hZ\xd0(5a\xb1' \
b'\xa8`\x01E[\x01\xd9\x94\xa5E\x91\x9a\xf3~y\x86\x1f\xde\xf2\xce,\xf7u\xfa\xe6{\x92\xc6\x18\xce\x9c\x99\xf3' \
b'\x99\xf9\xbe\xfb\xee\xbdg\xe6%UUUU\x91\x03\xf6\xfb\xef\xbf\xd3\xbe}\xfbh\xff\xfe\xfdt\xe0\xc0\x01:r\xe4\x08' \
b'\x1d?~\x9cN\x9e<I\x15\x15\x15\x0e\x8c\x10C\xb0M\xa0A\x83\x06\xd4\xa8Q#j\xdc\xb815m\xda\x94Z\xb6l\x19\xf9k' \
b'\xdf\xbe=]|\xf1\xc5\xb6\xbb\xd3\x8a\x97T\x93\x02\xd9\xb1c\x07\x95\x94\x94Pii)\x1d:tH+\x014JL\x02\xcd\x9a5' \
b'\xa3\xce\x9d;Sjj*]}\xf5\xd55\x96d\xdc\x05\xc2W\x88\xa2\xa2"\xda\xbau+\xae\x0c56\xed\xb5\xab\xe3\x86\r\x1b' \
b'\xd2\xcd7\xdfL\xe9\xe9\xe9t\xf9\xe5\x97\xc7u\xf0q\x13\xc8\x9e={\xe8\xe3\x8f?\xa6\x9d;w\xc65At\x96X\x04\xbau' \
b'\xebF\xfd\xfb\xf7\xa76m\xda\xc4%\xb1\xd0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X\x9c#\x00\x8187%\x18\x90K\x04 \x10\x97f\x03cq\x8e\x00' \
b'\x04\xe2\xdc\x94`@.\x11\x80@\\\x9a\r\x8c\xc59\x02\x10\x88sS\x82\x01\xb9D\x00\x02qi60\x16\xe7\x08@ \xceM\t' \
b'\x06\xe4\x12\x01\x08\xc4\xa5\xd9\xc0X\x9c#\x00\x8187%\x18\x90K\x04 \x10\x97f\x03cq\x8e\x00\x04R\xcd\x94\xf0' \
b'\x1e\x80\x92\x92\x12+\'\x80\xf3o\xd9\xa5\xa6\xa6\x8a\'\xbf\xa2\xa2"\xd2\xb7\xee>\x04qG\t\xe8\xc8\'\xf73k\xfe' \
b'\xbd\x0e\x1b\x06\x81\x04P,++\xa3\xfc\xfc|\x1b|\xff\x8d\xc1"\xe1\xddi\x12\xe3\x12i\x16\tL\x9f\x00\xb3f\xe6' \
b'\xa6\x06\x81\x04\x10\xe4C\x8c\x8b\x8a\x8aL\xd9\xfe\xa7}NNN\xccO6\xfe\x1dF>\xd9\x0ffF ==\x9d222\xcc\x82\x10' \
b'\x11\x04\x12\x80\x90\x7fjz\xf7\xee\xdd\xc6p\xcf\x0f\xc0?\x19\xdc\xb1c\xc7\x0b\xc6\xfd\xf0\xc3\x0f\xe9\xa3' \
b'\x8f>\xb2\xde\xb7o\x01SRRh\xec\xd8\xb1\xc6iC \x10\x88\xf1"r1\x00\x04\x120+\xb6\xb6\xdc\xe2\n\xe2\xe2\x92W' \
b'\x1b\x13\x04\x02\x81\xa8\xad\x18\xcf\xbc!\x10\x08\xc4\xb3%\xaf\x96.\x04\x02\x81\xa8\xad\x18\xcf\xbc!\x10' \
b'\x08\xc4\xb3%\xaf\x96.\x04\x02\x81\xa8\xad\x18\xcf\xbc!\x10\x08\xc4\xb3%\xaf\x96.\x04\x02\x81\xa8\xad\x18' \
b'\xcf\xbc!\x90\x10\x05RPP\x10)\x16\xb4m\x927\xe9\xb6~e\xd5\xf6\xd8k[<.X\x1c5j\x94\xf1\xb0\xf1&=\x00\xe1\xe6' \
b'\xcd\x9bi\xd5\xaaU\xc6p\xcf\r\xc0?(\xca\x07s\xc72\xae\xe0\xe5\x13\xc5af\x04233)--\xcd,\x08j\xb1\x82\xf9q%-' \
b'\xffN\xbb\xad\xab\x08\xffnb\xef\xde\xbd#\x7f\x12\xe3bI\x16\xa9\xc9/\xfdJ\xfaIT\x1f\xbez\x8c\x181\x82\xb8\xf4' \
b'\xdd\xd4p\x051%\x88\xf6\tM\x00\x02I\xe8\xe9Er\xa6\x04 \x10S\x82h\x9f\xd0\x04 \x90\x84\x9e^$gJ\x00\x021%\x88' \
b'\xf6\tM\x00\x02I\xe8\xe9Er\xa6\x04 \x10S\x82h\x9f\xd0\x04 \x90\x84\x9e^$gJ\x00\x021%\x88\xf6\tM\x00\x02I' \
b'\xe8\xe9Er\xa6\x04 \x10S\x82h\x9f\xd0\x04 \x90\x84\x9e^$gJ\x00\x021%\x88\xf6\tM\x00\x02I\xe8\xe9Er\xa6\x04 ' \
b'\x90j\x08\xf2\xd9\xbc|N\xae\r\xe3\x93\xc6{\xf4\xe8\x11\xf3\xd8\xd1h_\xdcoqq1\x0e\xb0\xd6\x84\x7f\xed\xb5\xd7' \
b'\x12\x9f\xcdk\xc3 \x90\x00\x8aa\x1c \xcd"\xe1\xc3\xabc\x19\xefE\xe1\xd3\xddaf\x04\x1ey\xe4\x11b\xa1\x98\x1a' \
b'\x04\x12@\x907K\xf1\'\xb8m\x93\x1c\xc9\x1f\xc6nF\xdby\xd4\x86x|\xc5\xe6MS\xa6\x06\x81\x04\x10\xc4\xd9\xbc' \
b'\xa6\xcb\xaa\xe6\xdb\xe3\xd0\x86\x809\xc0\xe1\xd55\xbf0]\x19\x01\x04\x02\x81\xb8\xb2\x16\x9d\x1c\x07\x04' \
b'\x02\x818\xb90]\x19\x14\x04\x02\x81\xb8\xb2\x16\x9d\x1c\x07\x04\x02\x818\xb90]\x19\x14\x04\x02\x81\xb8\xb2' \
b'\x16\x9d\x1c\x07\x04\x02\x818\xb90]\x19\x14\x04\x02\x81\xb8\xb2\x16\x9d\x1c\x07\x04\x02\x818\xb90]\x19\x14' \
b'\x04\x12\xa2@Pj\xe2\xca2\xd7\x1f\x07JMB\x14H\x18\xc5\x8a|\x80unnn\xcc\x19G\xb1bLD"\x07\x14+\x86(\x10\x0e' \
b'\xcdE\x83,\x14^\xb0\xa6\xc6\x95\xbc|\x14\x7f\xc7\x8e\x1dE\xa1JKK#\xfd\xf3O!\xc0\xd4\x08\xf0\x89\xee\\\xc5k' \
b'\xe3\xa7\x0f\xb8g\x14+\xaa\xf1\x87\xb7g\x04 \x10\xcf&\x1c\xe9\xaa\x11\x80@\xd4x\xc1\xdb3\x02\x10\x88g\x13' \
b'\x8et\xd5\x08@ j\xbc\xe0\xed\x19\x01\x08\xc4\xb3\tG\xbaj\x04 \x105^\xf0\xf6\x8c\x00\x04\xe2\xd9\x84#]5\x02' \
b'\x10\x88\x1a/x{F\x00\x02\xf1l\xc2\x91\xae\x1a\x01\x08D\x8d\x17\xbc=#\x00\x81x6\xe1HW\x8d\x00\x04\xa2\xc6' \
b'\x0b\xde\x9e\x11\x80@.0\xe1\\\xc9[^^n\xbc$x\xf3\x8e\x8e\xed\xde\xbd[\xa7\x99\xd7m\x92\x93\x93\x89+zm\x19' \
b'\x04\x12@\x92\x85\xb1j\xd5*k\xa7\xbb\xf3\x84\xf1i\xe3\xfd\xfb\xf7\x17\xcd\xdb\xfa\xf5\xeb#\xe5\xee6J\xedE' \
b'\x1d&\x98\x13\x97\xbbgffZ\x11\n\x04\x12\xb08\xc28@\x9aE\x92\x97\x97\x17s)\xf2\x1e\x90\xe9\xd3\xa7\xc7\xf4' \
b'\x83\xc3\x85\t\xb0@l\xec\t\x81@\x028\x17\x14\x14PII\x89\xf55\x98\x95\x95\x15s\xd3Taa!\xf1\x15\x04fF 55\x95F' \
b'\x8d\x1ae\x16\x04\x1b\xa6\x82\xf9\xe1tw\xe3uU\xe3\x01phC\xc0\x14\xe0t\xf7\x1a_\x97\xce\x0c\x00\x02\x81@\x9cY' \
b'\x8c.\x0e\x04\x02\x81@\\\\\x97\xce\x8c\t\x02\x81@\x9cY\x8c.\x0e\x04\x02\x81@\\\\\x97\xce\x8c\t\x02\x81@\x9cY' \
b'\x8c.\x0e\x04\x02\x81@\\\\\x97\xce\x8c\t\x02\x81@\x9cY\x8c.\x0e\x04\x02\x81@\\\\\x97\xce\x8c\t\x02\tQ \xeb' \
b'\xd6\xad\xa3\xa2\xa2"\xeb\x93\x9d\x93\x93C|N\xef\x85,\x8c\x83\xb3\xad\'R\x0b\x02rqhFF\x86\xf1HQ\x8b\x15\x80' \
b'\xb0\xac\xac\x8c\xf2\xf3\xf3\x8d\xe1\x9e\x1b\x80\xcb\xb0\'O\x9e,\x8a\x99\x9d\x9dM\x95\x95\x95"_8\x05\x13' \
b'\x984i\x12\xb5n\xdd\xda\x18\x0f\x04R\rB.5\xe7Os\x1b\'\xac\xf3Dq\t\xb6\x8aq\xdf,T\x98\x1a\x81\xe8\xe9\xee' \
b'\xb1\xae\xd4\xd2\xa8\x10\x88\x94\x14\xfc\xbc$\x00\x81x9\xedHZJ\x00\x02\x91\x92\x82\x9f\x97\x04 \x10/\xa7' \
b'\x1dIK\t@ RR\xf0\xf3\x92\x00\x04\xe2\xe5\xb4#i)\x01\x08DJ\n~^\x12\x80@\xbc\x9cv$-%\x00\x81HI\xc1\xcfK\x02' \
b'\x10\x88\x97\xd3\x8e\xa4\xa5\x04 \x10))\xf8yI\x00\x02\xf1r\xda\x91\xb4\x94\x00\x04"%\x05?/\t@ ^N;\x92\x96' \
b'\x12\x80@\xa4\xa4\xe0\xe7%\x01\x08\xc4\xcbiG\xd2R\x02\x10\x88\x94\x14\xfc\xbc$\x00\x81x9\xedHZJ\x00\x02\x91' \
b'\x92\x82\x9f\x97\x04 \x10/\xa7\x1dIK\t@ RR\xf0\xf3\x92\x00\x04\xe2\xe5\xb4#i)\x01\x08DJ\n~^\x12\x80@\xbc' \
b'\x9cv$-%\x00\x81HI\xc1\xcfK\x02\x10\x88\x97\xd3\x8e\xa4\xa5\x04 \x10))\xf8yI\x00\x02\xf1r\xda\x91\xb4\x94' \
b'\x00\x04"%\x05?/\t@ ^N;\x92\x96\x12\x80@\xa4\xa4\xe0\xe7%\x01\x08\xc4\xcbiG\xd2R\x02\x10\x88\x94\x14\xfc' \
b'\xbc$\x00\x81x9\xedHZJ\x00\x02\x91\x92\x82\x9f\x97\x04 \x10/\xa7\x1dIK\t@ RR\xf0\xf3\x92\x00\x04\xe2\xe5' \
b'\xb4#i)\x01\x08DJ\n~^\x12\x80@\xbc\x9cv$-%\x00\x81HI\xc1\xcfK\x02\x10\x88\x97\xd3\x8e\xa4\xa5\x04 \x10))' \
b'\xf8yI\x00\x02\xf1r\xda\x91\xb4\x94\x00\x04"%\x05?/\t@ ^N;\x92\x96\x12pN 3g\xce\xa4\x83\x07\x0fJ\xc7\xff' \
b'\x7f~\xed\xda\xb5\xa3\x89\x13\'j\xb5E#\x10\x08"`"\x90\xe6\xcd\x9bSvv\xb6\x08lRUUU\x95\xc43??\x9f\xca\xca' \
b'\xca$\xae\xff\xf1\xb9\xe2\x8a+\xe8\xb9\xe7\x9e\xd3j\x8bF \x10D\xe0\xc5\x17_\xa4C\x87\x0ei\xc1i\xd3\xa6\r=' \
b'\xfd\xf4\xd3\xa2\xb6b\x81\xcc\x9b7\x8f\xf6\xec\xd9#\nz\xbeS\xbdz\xf5h\xf6\xec\xd9Zm\xd1\x08\x04\x82\x08' \
b'\xf0\x02?{\xf6\xac\x16\x9c\x94\x94\x14\x1a;v\xac\xa8\xadX \x8b\x16-\xa2\xef\xbe\xfbN\x144\xc8\x89\xaf@u\xea' \
b'\xd4\xd1n\x8f\x86 \x10%PYY)\xfe\x8a\x14D\xad[\xb7n\xf4\xe8\xa3\x8f\x8a\x80\x8a\x05\xf2\xe6\x9bo\xd2W_}%\n' \
b'\x1a\xe44f\xcc\x18\xea\xd4\xa9\x93v{4\x04\x81(\x81\x9d;w\x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91p9\xc0\xe1\xc3\x87\x8d\x07' \
b'\x85\x00 \xa0K\x80\xabu\xb3\xb2\xb2\xac\x88\x83\xc7`\xe5\n\x12M\xe6\xc4\x89\x13\xb4`\xc1\x02*//\xd7\xcd' \
b'\x0f\xed@@\x9b\x00\x97-q\xf9\x92\xee\x13\xabP\xeeA\xce\x0f\xca\xf7$K\x96,\xa1\xd2\xd2R\xedD\xd1\x10\x04T' \
b'\t\xe8\xbe)\x8f\xd5\x8f\xd5+H\xb43~\t\xb4z\xf5j\xda\xbcys\xac\xfe\xf1\xef `D\x80_ \x0f\x1e<\x98\xf8\x89U' \
b'\x18\x16\x8a@\xa2\x03\xb5\xb1=2\x8c\xa4\x1131\x08\xf0\xb6\xd9\x91#GR\xd7\xae]CK(T\x81\xf0\xa8\xf9\xc9\x16' \
b'\xef!\xb6Y\xdc\x18\x1a\r\x04\xae\x15\x04\xf8\xaa\xc1g\x1b\xf0\x95\xa3a\xc3\x86\xa1\x8e9t\x81DG\xcf\x05h' \
b'\x1b6l\x08\xa5\x10-TB\x08\xee\x14\x81\xee\xdd\xbb\xd3\xddw\xdf\x1d\xb7\xcdvq\x13H\x94\xf2\xaf\xbf\xfeJ' \
b'\x85\x85\x85\xb4u\xebV\xe2\x1bz\x18\x08\xc4"p\xc9%\x97\x10\x0b\x83\xcf\xb2\xe2\x83?\xe2iq\x17\xc8\xb9\xc9m' \
b'\xdf\xbe\x9dx\xc7\x18?\xf1:r\xe4H<\xf3F_\x8e\x13\xe0\xed\xd8\xfc\xd8\xf6\xba\xeb\xae#>K\xb7\xa6\xacF\x05rn' \
b'\xd2|\xaf\xf2\xf3\xcf?\x13_a\xb8\x04\x9a\xff\xff\xf8\xf1\xe3\x91#^L\x0e\t\xab)\xb0\xe876\x01\xbe\x7fh\xd4' \
b'\xa8\x11\xf1\xa1\x82\xbc\xa5\xa1E\x8b\x16\xd4\xb2eK\xe22\x91\xb0\xef-b\x8f\xee\x7f\x1e\xff\x00\xe4F\xe2' \
b'{\x87\xf5Hl\x00\x00\x00\x00IEND\xaeB`\x82'
day_date = time.strftime("%Y%m%d", time.localtime())
def new_data():
with open(r'data/data%s.txt' % day_date, 'w',encoding='utf8') as read_data:
pass
with open(r'data/wanc%s.txt' % day_date, 'w') as read_data:
pass
def dataWrite(list_date):
if list_date != [''] and list_date != '/n':
for i in list_date:
with open(r'data/data%s.txt' %day_date, 'a+',encoding='utf8') as add_data:
add_data.write(i + '\n')
def dataRead():
with open(r'data/data%s.txt' %day_date, 'r+',encoding='utf8') as read_data:
values = read_data.readlines()
value = list()
for i in values:
if i[-1:] == '\n':
if len(i) != 1:
value.append(i[:-1])
else:
value.append(i)
list1 = list(x for x in range(len(value)))
values_dict = dict(zip(list1, value))
return values_dict
def dataDelete(list_date):
with open(r'data/data%s.txt' %day_date, 'w',encoding='utf8') as add_data:
for i in list_date:
add_data.writelines(str(i) + '\n')
def write_wanc(wanc_add):
with open(r'data/wanc%s.txt' % day_date, 'a+',encoding='utf8') as add_data:
for i in wanc_add:
add_data.writelines(str(i) + '\n')
def read_wanc(*args):
if args == ():
with open(r'data/wanc%s.txt' % day_date, 'r',encoding='utf8') as read_data:
values = read_data.readlines()
value = list()
for i in values:
if i[-1:] == '\n':
if len(i) != 1:
value.append(i[:-1])
else:
value.append(i)
list1 = list(x for x in range(len(value)))
values_dict = dict(zip(list1, value))
return values_dict
else:
with open(r'data/%s.txt' % ('wanc'+args[0]), 'r', encoding='utf8') as read_data:
values = read_data.readlines()
value = list()
for i in values:
if i[-1:] == '\n':
if len(i) != 1:
value.append(i[:-1])
else:
value.append(i)
list1 = list(x for x in range(len(value)))
values_dict = dict(zip(list1, value))
return values_dict
def time_write(*args):
with open(r'data/%s.txt' % ('time' + args[0]), 'r', encoding='utf8') as read_data:
pass
class MainUi(QtWidgets.QMainWindow):
def __init__(self):
super().__init__()
new_data()
self.init_ui()
self.tuopan()
self.func()
# # 右击事件
# # 将ContextMenuPolicy设置为Qt.CustomContextMenu
# # 否则无法使用customContextMenuRequested信号
# self.setContextMenuPolicy(QtCore.Qt.CustomContextMenu)
# self.customContextMenuRequested.connect(self.rightMenuShow)
# 创建系统托盘
def tuopan(self):
icon = QPixmap()
icon.loadFromData(image)
self.tb = QSystemTrayIcon()
self.icon = QIcon(icon) # 设置托盘图标
self.tb.setIcon(self.icon)
self.mens = QMenu() # 创建菜单
m1 = QAction('退出', self)
# 绑定菜单信号事件
m1.triggered.connect(QCoreApplication.instance().quit)
self.mens.addAction(m1) # 添加菜单
# 双击事件
self.tb.activated[QSystemTrayIcon.ActivationReason].connect(self.iconActivated)
self.tb.setContextMenu(self.mens) # 绑定菜单
self.tb.show()
# 双击隐藏和显示
def iconActivated(self, reason):
if reason == QSystemTrayIcon.DoubleClick:
if self.isHidden():
self.show()
else:
self.hide()
def mousePressEvent(self, event):
if event.button() == Qt.LeftButton:
self.m_flag = True
self.m_Position = event.globalPos() - self.pos() # 获取鼠标相对窗口的位置
event.accept()
self.setCursor(QCursor(Qt.OpenHandCursor)) # 更改鼠标图标
def mouseMoveEvent(self, QMouseEvent):
try:
if Qt.LeftButton and self.m_flag:
self.move(QMouseEvent.globalPos() - self.m_Position) # 更改窗口位置
QMouseEvent.accept()
except AttributeError as ae:
pass
def mouseReleaseEvent(self, QMouseEvent):
self.m_flag = False
self.setCursor(QCursor(Qt.ArrowCursor))
def init_ui(self):
self.setFixedSize(340, 750)
# self.resize(360,750)
self.main_widget = QtWidgets.QWidget() # 创建窗口主部件
self.main_layout = QtWidgets.QGridLayout() # 创建主部件的网格布局
self.main_widget.setLayout(self.main_layout) # 设置窗口主部件布局为网格布局
self.main_widget.setObjectName('main_widget')
self.setCentralWidget(self.main_widget) # 设置窗口主部件
self.setWindowFlags(Qt.ToolTip) # 隐藏任务栏图标
# 设置上方部件
self.up_widget = QtWidgets.QWidget()
self.up_layout = QtWidgets.QGridLayout()
self.main_layout.addWidget(self.up_widget, 0, 0, 2, 6)
self.up_widget.setLayout(self.up_layout)
# self.up_layout.setSpacing(0) # 总体间距
# self.up_layout.setHorizontalSpacing(0) # 水平间距
self.up_layout.setVerticalSpacing(30) # 垂直间距
# 设置下方部件
self.down_widget = QWidget()
self.down_layout = QGridLayout()
self.down_widget.setLayout(self.down_layout)
self.main_layout.addWidget(self.down_widget, 2, 0, 10, 6)
self.setWindowFlag(QtCore.Qt.FramelessWindowHint) # 隐藏边框
self.setWindowOpacity(0.5) # 设置窗口透明度
self.setAttribute(QtCore.Qt.WA_TranslucentBackground) # 设置窗口背景透明
# 设置圆角
self.main_widget.setStyleSheet('''
QWidget#main_widget{
background:black;
border-radius:16px
}
''')
# 消除上下两个部件的空隙
self.main_layout.setSpacing(0)
# 添加标题
self.label_title = QLabel(' 小仙女专用便签')
self.up_layout.addWidget(self.label_title, 0, 0, 1, 5)
self.label_title.setStyleSheet("color:white;")
self.label_title.setFont(QFont('微软雅黑', 11, 70))
# 退出按钮
self.exitBtn = QPushButton('✕')
self.exitBtn.setFont(QFont('黑体', 15))
self.exitBtn.setObjectName('exitBtn')
self.exitBtn.setFixedSize(25, 25)
self.up_layout.addWidget(self.exitBtn, 0, 6, )
self.exitBtn.setStyleSheet("border:none;color:white;background:black;")
self.exitBtn.clicked.connect(QCoreApplication.instance().quit)
# 最小化按钮
self.minimizeBtn = QPushButton('__')
self.minimizeBtn.setObjectName('minimizeBtn')
self.minimizeBtn.setFixedSize(25, 25)
self.up_layout.addWidget(self.minimizeBtn, 0, 5, )
self.minimizeBtn.setStyleSheet("border:none;color:white;background:black;")
self.minimizeBtn.clicked.connect(self.hide) # 最小化到托盘
# 输入框添加功能
self.Tip_lineEdit = QLineEdit()
self.Tip_lineEdit.setPlaceholderText('+小仙女今天想要吃些什么呢?')
self.Tip_lineEdit.setFont(QFont('微软雅黑', 10, 70))
self.up_layout.addWidget(self.Tip_lineEdit, 1, 0, 1, 6)
self.Tip_lineEdit.setAlignment(Qt.AlignCenter)
self.Tip_lineEdit.setFixedSize(310, 35)
self.Tip_lineEdit.setStyleSheet("border:0px groove gray;"
"border-radius:10px;padding:2px 3px;"
"color:blue")
# editingFinished 当编辑文本结束时,这个信号就会发射
self.Tip_lineEdit.editingFinished.connect(self.func)
self.cboxopen = QPushButton('选择完成事件')
self.down_layout.addWidget(self.cboxopen, 0, 5, 1, 5)
self.cboxopen.setStyleSheet("border:none;color:white;background:black;")
self.cboxopen.setFixedSize(100, 20)
self.cboxopen.clicked.connect(self.cbox_open)
self.cboxopen.show()
# 选择完成,添加下拉列表
self.cbox = QComboBox()
self.cbox.setToolTip('请标记已完成的项目') # 提示气泡
self.down_layout.addWidget(self.cbox, 0, 5, 1, 5)
self.cbox.setFixedSize(100, 20)
self.cbox.activated.connect(self.wancheng)
self.cbox.setStyleSheet("border:none;color:white;background:black;")
self.cbox.hide()
# 切换完成按钮
self.btn_add = QPushButton('查看已完成')
self.down_layout.addWidget(self.btn_add, 0, 4, 1, 1)
self.btn_add.setFixedSize(90, 20)
self.btn_add.clicked.connect(self.a)
self.btn_add.setStyleSheet("border:none;color:white;background:black;")
# 创建用于存放lable的字典
self.label_value = {}
for i in range(13):
self.label_value[i] = QLabel()
self.label_value[i].setTextInteractionFlags(Qt.TextSelectableByMouse)
# 样式顺序,颜色,字体大小,边框,圆角,文字距离,行间距
self.label_value[i].setStyleSheet("color:white;font-size:14px;"
"border-bottom:1px solid #FFFFFF;"
"border-radius:1px;"
"padding-top:14px;"
"margin:2px")
self.label_value[i].setAlignment(Qt.AlignLeft) # 设置文本左对齐
self.label_value[i].setWordWrap(1) # 允许换行
self.down_layout.addWidget(self.label_value[i], i + 1, 0, 1, 10)
self.wanc_widget = QWidget()
self.wanc_layout = QGridLayout()
self.wanc_layout.setVerticalSpacing(6)
self.wanc_widget.setLayout(self.wanc_layout)
self.main_layout.addWidget(self.wanc_widget, 2, 0, 10, 6)
#第二界面返回主界面按钮
self.test_btn = QPushButton('返回待完成')
self.test_btn.clicked.connect(self.b)
self.test_btn.setFixedSize(90, 20)
self.test_btn.setStyleSheet("border:none;color:white;background:black;")
self.wanc_layout.addWidget(self.test_btn, 0, 3, 1, 1)
self.wanc_widget.hide()
# # 查看历史完成记录
self.hist_cbox = QComboBox()
self.wanc_layout.addWidget(self.hist_cbox, 0, 0, 1, 3)
self.hist_cbox.setFixedSize(80, 20)
self.hist_cbox.activated.connect(self.hist_trans)
self.hist_cbox.setStyleSheet("border:none;color:white;background:black;")
self.hist_cbox.hide()
## 查看历史已完成按钮
self.hist_btn = QPushButton('选择查看日期')
self.wanc_layout.addWidget(self.hist_btn,0,0,1,3)
self.hist_btn.setFixedSize(80,20)
self.hist_btn.setStyleSheet("border:none;color:white;background:black;")
self.hist_btn.show()
self.hist_btn.clicked.connect(self.hist_cbox_open)
# 第二界面完成label
self.label_wanc = {}
for i in range(13):
self.label_wanc[i] = QLabel()
# 样式顺序,颜色,字体大小,边框,圆角,文字距离,行间距
self.label_wanc[i].setStyleSheet("color:white;font-size:14px;"
"border-bottom:1px solid #FFFFFF;"
"border-radius:1px;"
"padding-top:14px;"
"margin:2px")
self.label_wanc[i].setAlignment(Qt.AlignLeft) # 设置文本左对齐
self.label_wanc[i].setWordWrap(1) # 允许换行
self.wanc_layout.addWidget(self.label_wanc[i], i + 1, 0, 1, 8)
def cbox_open(self):
self.cbox.show()
self.cboxopen.hide()
def hist_trans(self):
flie_date = self.hist_cbox.currentText()
for i in self.label_wanc.keys():
self.label_wanc[i].setText('')
for x, y in read_wanc(flie_date).items():
self.label_wanc[x].setText(y)
self.hist_cbox.hide()
self.hist_btn.show()
# cliek_time = time.strftime("%Y%m%d", time.localtime())
def hist_cbox_open(self):
self.hist_btn.hide()
self.hist_cbox.show()
file_names = os.listdir(r"data/")
list_temp = list()
for i in file_names:
if i[0:4] == 'wanc':
list_temp.append(i[4:-4])
self.hist_cbox.clear()
self.hist_cbox.addItems(list_temp)
# 进入完成列表信号事件
def a(self):
self.down_widget.hide()
self.wanc_widget.show()
for i in self.label_wanc.keys():
self.label_wanc[i].setText('')
for x, y in read_wanc().items():
self.label_wanc[x].setText(y)
# 返回主界面信号
def b(self):
self.wanc_widget.hide()
self.down_widget.show()
# 插入待完成信号
def func(self):
value = list()
if self.Tip_lineEdit.text() != '' and self.Tip_lineEdit.text() != '\n':
value.append(self.Tip_lineEdit.text())
dataWrite(value)
self.Tip_lineEdit.clear()
self.cbox.clear()
data = dataRead()
for i in self.label_value.keys():
self.label_value[i].setText('')
for x, y in data.items():
self.label_value[x].setText(y)
self.cbox.addItem(y)
# 转移完成信号事件
def wancheng(self, i):
del_data = list()
add_wanc = list()
for i in range(self.cbox.count()):
if i != self.cbox.currentIndex():
del_data.append(self.cbox.itemText(i))
elif i == self.cbox.currentIndex():
add_wanc.append(self.cbox.itemText(i))
dataDelete(del_data)
self.func()
write_wanc(add_wanc)
cliek_time = time.strftime("%H:%M:%S", time.localtime())
self.cbox.hide()
self.cboxopen.show()
# 右键事件菜单
# def rightMenuShow(self):
# self.contextMenu = QMenu(self)
# self.exit = self.contextMenu.addAction('关闭')
# # 绑定关闭事件
# self.exit.triggered.connect()
# self.minimize = self.contextMenu.addAction('最小化')
# # 绑定最小化事件
# self.minimize.triggered.connect(self.showMinimized())
# self.contextMenu.exec_(QCursor.pos())
def main():
app = QtWidgets.QApplication(sys.argv)
gui = MainUi()
gui.show()
sys.exit(app.exec_())
main()