-
Notifications
You must be signed in to change notification settings - Fork 36
/
FinderOverlay.py
37 lines (29 loc) · 1.39 KB
/
FinderOverlay.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
from PySide.QtCore import Qt
from PySide.QtGui import QPainter, QWidget, QPalette, QBrush, QColor, QLabel, QGridLayout
class FinderOverlay(QWidget):
def __init__(self, parent=None):
super(FinderOverlay, self).__init__(parent)
self.initUI()
def initUI(self):
# container = QWidget(self)
# container.resize(200, 100);
# container.setStyleSheet("background-color:black;")
font_size = QLabel('Font Size')
font_size.fillColor = QColor(30, 30, 30, 120)
font_size.penColor = QColor("#333333")
grid = QGridLayout()
grid.setContentsMargins(50, 10, 10, 10)
grid.addWidget(font_size, 0, 0)
self.setLayout(grid)
# palette = QPalette(self.palette())
# palette.setColor(self.backgroundRole(), Qt.black)
# palette.setColor(palette.Background, Qt.transparent)
# self.setPalette(palette)
# def paintEvent(self, event):
# painter = QPainter()
# painter.begin(self)
# # painter.setRenderHint(QPainter.Antialiasing)
# painter.fillRect(event.rect(), QBrush(QColor(255, 255, 255, 127)))
# painter.drawLine(self.width() / 8, self.height() / 8, 7 * self.width() / 8, 7 * self.height() / 8)
# painter.drawLine(self.width() / 8, 7 * self.height() / 8, 7 * self.width() / 8, self.height() / 8)
# # painter.setPen(QPen(Qt.NoPen))