4 # |
4 # |
5 |
5 |
6 """ |
6 """ |
7 Module implementing a palette widget for the icon editor. |
7 Module implementing a palette widget for the icon editor. |
8 """ |
8 """ |
|
9 |
|
10 from __future__ import unicode_literals # __IGNORE_WARNING__ |
9 |
11 |
10 from PyQt4.QtCore import pyqtSignal, Qt |
12 from PyQt4.QtCore import pyqtSignal, Qt |
11 from PyQt4.QtGui import QWidget, QColor, QPainter, QBoxLayout, QLabel, QFrame, \ |
13 from PyQt4.QtGui import QWidget, QColor, QPainter, QBoxLayout, QLabel, QFrame, \ |
12 QPushButton, QSpinBox, QGroupBox, QVBoxLayout, QRadioButton, QSpacerItem, \ |
14 QPushButton, QSpinBox, QGroupBox, QVBoxLayout, QRadioButton, QSpacerItem, \ |
13 QSizePolicy, QPixmap, QColorDialog |
15 QSizePolicy, QPixmap, QColorDialog |
28 """ |
30 """ |
29 Constructor |
31 Constructor |
30 |
32 |
31 @param parent reference to the parent widget (QWidget) |
33 @param parent reference to the parent widget (QWidget) |
32 """ |
34 """ |
33 super().__init__(parent) |
35 super(IconEditorPalette, self).__init__(parent) |
34 |
36 |
35 if self.layoutDirection == Qt.Horizontal: |
37 if self.layoutDirection == Qt.Horizontal: |
36 direction = QBoxLayout.LeftToRight |
38 direction = QBoxLayout.LeftToRight |
37 else: |
39 else: |
38 direction = QBoxLayout.TopToBottom |
40 direction = QBoxLayout.TopToBottom |