Exemple #1
0
class AddTagDlg(QDialog):
    def __init__(self, list, parent = None):
        super(AddTagDlg, self).__init__(parent)
        self.setModal(True)
        self.list = list
        self.color = QColor('red')
        #Creazione elementi dialog
        buttonBox = QDialogButtonBox(QDialogButtonBox.Ok|QDialogButtonBox.Cancel)
        self.colorPickerButton = ColorButton()
        self.colorPickerButton.setColor(self.color)
        labelTag = QLabel("Nome &Tag:")
        self.lineEdit = QLineEdit()
        labelTag.setBuddy(self.lineEdit)
        labelColor = QLabel("&Colore:")
        labelColor.setBuddy(self.colorPickerButton)
        #Creazione layout dialog
        grid = QGridLayout()
        grid.addWidget(labelTag, 0, 0)
        grid.addWidget(self.lineEdit, 0, 1)
        grid.addWidget(labelColor,1, 0)
        grid.addWidget(self.colorPickerButton, 1, 1)
        grid.addWidget(buttonBox, 2, 0, 1, 2)
        self.setLayout(grid)
        self.setWindowTitle("Aggiungi Tag")
        #Connessioni
        self.connect(buttonBox, SIGNAL("accepted()"), self, SLOT("accept()"))
        self.connect(buttonBox, SIGNAL("rejected()"), self, SLOT("reject()"))
        self.connect(self.colorPickerButton, SIGNAL("clicked()"), self.chooseColorDlg)
        
        #print self.parent()
        
    #Riscrittura per validazione Post-mortem
    def accept(self):
        item = QListWidgetItem()
        itemLabel = TagLabel(self.lineEdit.text(), self.color.name(), self)
        self.list.addItem(item)
        self.list.setItemWidget(item, itemLabel)
        QDialog.accept(self)
    
    def chooseColorDlg(self):
        dialog = QColorDialog(self)
        #Connessioni
        self.connect(dialog, SIGNAL("colorSelected(QColor)"), self.setColor)
        dialog.show()
    
    def setColor(self, color):
        self.color = color
        self.colorPickerButton.setColor(color)
Exemple #2
0
 def __init__(self, list, parent = None):
     super(AddTagDlg, self).__init__(parent)
     self.setModal(True)
     self.list = list
     self.color = QColor('red')
     #Creazione elementi dialog
     buttonBox = QDialogButtonBox(QDialogButtonBox.Ok|QDialogButtonBox.Cancel)
     self.colorPickerButton = ColorButton()
     self.colorPickerButton.setColor(self.color)
     labelTag = QLabel("Nome &Tag:")
     self.lineEdit = QLineEdit()
     labelTag.setBuddy(self.lineEdit)
     labelColor = QLabel("&Colore:")
     labelColor.setBuddy(self.colorPickerButton)
     #Creazione layout dialog
     grid = QGridLayout()
     grid.addWidget(labelTag, 0, 0)
     grid.addWidget(self.lineEdit, 0, 1)
     grid.addWidget(labelColor,1, 0)
     grid.addWidget(self.colorPickerButton, 1, 1)
     grid.addWidget(buttonBox, 2, 0, 1, 2)
     self.setLayout(grid)
     self.setWindowTitle("Aggiungi Tag")
     #Connessioni
     self.connect(buttonBox, SIGNAL("accepted()"), self, SLOT("accept()"))
     self.connect(buttonBox, SIGNAL("rejected()"), self, SLOT("reject()"))
     self.connect(self.colorPickerButton, SIGNAL("clicked()"), self.chooseColorDlg)
Exemple #3
0
 def createWidget(self, parent):
     return ColorButton(parent)
    def setupUi(self, NewTilesetDialog):
        NewTilesetDialog.setObjectName("NewTilesetDialog")
        NewTilesetDialog.resize(387, 314)
        self.verticalLayout = QtWidgets.QVBoxLayout(NewTilesetDialog)
        self.verticalLayout.setSizeConstraint(
            QtWidgets.QLayout.SetMinAndMaxSize)
        self.verticalLayout.setObjectName("verticalLayout")
        self.tilesetGroupBox = QtWidgets.QGroupBox(NewTilesetDialog)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.tilesetGroupBox.sizePolicy().hasHeightForWidth())
        self.tilesetGroupBox.setSizePolicy(sizePolicy)
        self.tilesetGroupBox.setObjectName("tilesetGroupBox")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.tilesetGroupBox)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.tilesetType = QtWidgets.QComboBox(self.tilesetGroupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.tilesetType.sizePolicy().hasHeightForWidth())
        self.tilesetType.setSizePolicy(sizePolicy)
        self.tilesetType.setObjectName("tilesetType")
        self.tilesetType.addItem("")
        self.tilesetType.addItem("")
        self.gridLayout_2.addWidget(self.tilesetType, 1, 1, 1, 1)
        self.typeLabel = QtWidgets.QLabel(self.tilesetGroupBox)
        self.typeLabel.setObjectName("typeLabel")
        self.gridLayout_2.addWidget(self.typeLabel, 1, 0, 1, 1)
        self.nameLabel = QtWidgets.QLabel(self.tilesetGroupBox)
        self.nameLabel.setObjectName("nameLabel")
        self.gridLayout_2.addWidget(self.nameLabel, 0, 0, 1, 1)
        self.name = QtWidgets.QLineEdit(self.tilesetGroupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.name.sizePolicy().hasHeightForWidth())
        self.name.setSizePolicy(sizePolicy)
        self.name.setObjectName("name")
        self.gridLayout_2.addWidget(self.name, 0, 1, 1, 1)
        self.verticalLayout.addWidget(self.tilesetGroupBox)
        self.imageGroupBox = QtWidgets.QGroupBox(NewTilesetDialog)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred,
                                           QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.imageGroupBox.sizePolicy().hasHeightForWidth())
        self.imageGroupBox.setSizePolicy(sizePolicy)
        self.imageGroupBox.setCheckable(False)
        self.imageGroupBox.setObjectName("imageGroupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.imageGroupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.sourceLabel = QtWidgets.QLabel(self.imageGroupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed,
                                           QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.sourceLabel.sizePolicy().hasHeightForWidth())
        self.sourceLabel.setSizePolicy(sizePolicy)
        self.sourceLabel.setObjectName("sourceLabel")
        self.gridLayout.addWidget(self.sourceLabel, 0, 0, 1, 1)
        self.browseButton = QtWidgets.QPushButton(self.imageGroupBox)
        self.browseButton.setObjectName("browseButton")
        self.gridLayout.addWidget(self.browseButton, 0, 4, 1, 1)
        self.useTransparentColor = QtWidgets.QCheckBox(self.imageGroupBox)
        self.useTransparentColor.setObjectName("useTransparentColor")
        self.gridLayout.addWidget(self.useTransparentColor, 1, 0, 1, 2)
        self.colorButton = ColorButton(self.imageGroupBox)
        self.colorButton.setEnabled(False)
        self.colorButton.setObjectName("colorButton")
        self.gridLayout.addWidget(self.colorButton, 1, 2, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(0, 13,
                                           QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Minimum)
        self.gridLayout.addItem(spacerItem, 1, 3, 1, 1)
        self.gridLayout_3 = QtWidgets.QGridLayout()
        self.gridLayout_3.setObjectName("gridLayout_3")
        self.tileHeight = QtWidgets.QSpinBox(self.imageGroupBox)
        self.tileHeight.setMinimum(1)
        self.tileHeight.setMaximum(9999)
        self.tileHeight.setProperty("value", 32)
        self.tileHeight.setObjectName("tileHeight")
        self.gridLayout_3.addWidget(self.tileHeight, 1, 1, 1, 1)
        self.tileHeightLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.tileHeightLabel.setObjectName("tileHeightLabel")
        self.gridLayout_3.addWidget(self.tileHeightLabel, 1, 0, 1, 1)
        spacerItem1 = QtWidgets.QSpacerItem(20, 20,
                                            QtWidgets.QSizePolicy.Preferred,
                                            QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_3.addItem(spacerItem1, 1, 2, 1, 1)
        self.tileWidth = QtWidgets.QSpinBox(self.imageGroupBox)
        self.tileWidth.setEnabled(True)
        self.tileWidth.setMinimum(1)
        self.tileWidth.setMaximum(9999)
        self.tileWidth.setProperty("value", 32)
        self.tileWidth.setObjectName("tileWidth")
        self.gridLayout_3.addWidget(self.tileWidth, 0, 1, 1, 1)
        self.marginLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.marginLabel.setObjectName("marginLabel")
        self.gridLayout_3.addWidget(self.marginLabel, 0, 3, 1, 1)
        self.margin = QtWidgets.QSpinBox(self.imageGroupBox)
        self.margin.setMinimum(0)
        self.margin.setMaximum(9999)
        self.margin.setProperty("value", 0)
        self.margin.setObjectName("margin")
        self.gridLayout_3.addWidget(self.margin, 0, 4, 1, 1)
        self.spacing = QtWidgets.QSpinBox(self.imageGroupBox)
        self.spacing.setMinimum(0)
        self.spacing.setMaximum(9999)
        self.spacing.setProperty("value", 0)
        self.spacing.setObjectName("spacing")
        self.gridLayout_3.addWidget(self.spacing, 1, 4, 1, 1)
        self.tileWidthLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.tileWidthLabel.setObjectName("tileWidthLabel")
        self.gridLayout_3.addWidget(self.tileWidthLabel, 0, 0, 1, 1)
        self.spacingLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.spacingLabel.setObjectName("spacingLabel")
        self.gridLayout_3.addWidget(self.spacingLabel, 1, 3, 1, 1)
        spacerItem2 = QtWidgets.QSpacerItem(0, 20,
                                            QtWidgets.QSizePolicy.Expanding,
                                            QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_3.addItem(spacerItem2, 1, 5, 1, 1)
        self.gridLayout.addLayout(self.gridLayout_3, 2, 0, 1, 5)
        self.image = QtWidgets.QLineEdit(self.imageGroupBox)
        self.image.setObjectName("image")
        self.gridLayout.addWidget(self.image, 0, 1, 1, 3)
        self.verticalLayout.addWidget(self.imageGroupBox)
        self.buttonBox = QtWidgets.QDialogButtonBox(NewTilesetDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel
                                          | QtWidgets.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout.addWidget(self.buttonBox)
        self.nameLabel.setBuddy(self.name)

        self.retranslateUi(NewTilesetDialog)
        self.buttonBox.accepted.connect(NewTilesetDialog.tryAccept)
        self.buttonBox.rejected.connect(NewTilesetDialog.reject)
        self.useTransparentColor.toggled['bool'].connect(
            self.colorButton.setEnabled)
        QtCore.QMetaObject.connectSlotsByName(NewTilesetDialog)
        NewTilesetDialog.setTabOrder(self.name, self.tilesetType)
        NewTilesetDialog.setTabOrder(self.tilesetType, self.image)
        NewTilesetDialog.setTabOrder(self.image, self.browseButton)
        NewTilesetDialog.setTabOrder(self.browseButton,
                                     self.useTransparentColor)
        NewTilesetDialog.setTabOrder(self.useTransparentColor,
                                     self.colorButton)
        NewTilesetDialog.setTabOrder(self.colorButton, self.tileWidth)
        NewTilesetDialog.setTabOrder(self.tileWidth, self.tileHeight)
        NewTilesetDialog.setTabOrder(self.tileHeight, self.margin)
        NewTilesetDialog.setTabOrder(self.margin, self.spacing)
        NewTilesetDialog.setTabOrder(self.spacing, self.buttonBox)
class Ui_PreferencesDialog(object):
    def setupUi(self, PreferencesDialog):
        PreferencesDialog.setObjectName("PreferencesDialog")
        PreferencesDialog.resize(421, 426)
        self.verticalLayout = QtWidgets.QVBoxLayout(PreferencesDialog)
        self.verticalLayout.setSizeConstraint(QtWidgets.QLayout.SetFixedSize)
        self.verticalLayout.setObjectName("verticalLayout")
        self.tabWidget = QtWidgets.QTabWidget(PreferencesDialog)
        self.tabWidget.setObjectName("tabWidget")
        self.tab = QtWidgets.QWidget()
        self.tab.setObjectName("tab")
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.tab)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.groupBox = QtWidgets.QGroupBox(self.tab)
        self.groupBox.setObjectName("groupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.groupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.reloadTilesetImages = QtWidgets.QCheckBox(self.groupBox)
        self.reloadTilesetImages.setObjectName("reloadTilesetImages")
        self.gridLayout.addWidget(self.reloadTilesetImages, 1, 0, 1, 2)
        self.enableDtd = QtWidgets.QCheckBox(self.groupBox)
        self.enableDtd.setObjectName("enableDtd")
        self.gridLayout.addWidget(self.enableDtd, 0, 0, 1, 2)
        self.openLastFiles = QtWidgets.QCheckBox(self.groupBox)
        self.openLastFiles.setChecked(True)
        self.openLastFiles.setObjectName("openLastFiles")
        self.gridLayout.addWidget(self.openLastFiles, 2, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox)
        self.groupBox_2 = QtWidgets.QGroupBox(self.tab)
        self.groupBox_2.setObjectName("groupBox_2")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox_2)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.openGL = QtWidgets.QCheckBox(self.groupBox_2)
        self.openGL.setObjectName("openGL")
        self.gridLayout_2.addWidget(self.openGL, 5, 0, 1, 4)
        self.label_2 = QtWidgets.QLabel(self.groupBox_2)
        self.label_2.setObjectName("label_2")
        self.gridLayout_2.addWidget(self.label_2, 0, 0, 1, 1)
        self.label_3 = QtWidgets.QLabel(self.groupBox_2)
        self.label_3.setObjectName("label_3")
        self.gridLayout_2.addWidget(self.label_3, 2, 0, 1, 1)
        self.gridColor = ColorButton(self.groupBox_2)
        self.gridColor.setObjectName("gridColor")
        self.gridLayout_2.addWidget(self.gridColor, 2, 3, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(0, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_2.addItem(spacerItem, 0, 4, 1, 1)
        self.languageCombo = QtWidgets.QComboBox(self.groupBox_2)
        self.languageCombo.setObjectName("languageCombo")
        self.gridLayout_2.addWidget(self.languageCombo, 0, 3, 1, 1)
        self.label_4 = QtWidgets.QLabel(self.groupBox_2)
        self.label_4.setObjectName("label_4")
        self.gridLayout_2.addWidget(self.label_4, 3, 0, 1, 1)
        self.gridFine = QtWidgets.QSpinBox(self.groupBox_2)
        self.gridFine.setMinimum(1)
        self.gridFine.setMaximum(128)
        self.gridFine.setObjectName("gridFine")
        self.gridLayout_2.addWidget(self.gridFine, 3, 3, 1, 1)
        self.objectLineWidth = QtWidgets.QDoubleSpinBox(self.groupBox_2)
        self.objectLineWidth.setDecimals(1)
        self.objectLineWidth.setMinimum(1.0)
        self.objectLineWidth.setProperty("value", 2.0)
        self.objectLineWidth.setObjectName("objectLineWidth")
        self.gridLayout_2.addWidget(self.objectLineWidth, 4, 3, 1, 1)
        self.label = QtWidgets.QLabel(self.groupBox_2)
        self.label.setObjectName("label")
        self.gridLayout_2.addWidget(self.label, 4, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox_2)
        spacerItem1 = QtWidgets.QSpacerItem(381, 1, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout_2.addItem(spacerItem1)
        self.tabWidget.addTab(self.tab, "")
        self.tab_2 = QtWidgets.QWidget()
        self.tab_2.setObjectName("tab_2")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.tab_2)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.groupBox_3 = QtWidgets.QGroupBox(self.tab_2)
        self.groupBox_3.setObjectName("groupBox_3")
        self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.groupBox_3)
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.objectTypesTable = QtWidgets.QTableView(self.groupBox_3)
        self.objectTypesTable.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows)
        self.objectTypesTable.setVerticalScrollMode(QtWidgets.QAbstractItemView.ScrollPerPixel)
        self.objectTypesTable.setWordWrap(False)
        self.objectTypesTable.setObjectName("objectTypesTable")
        self.objectTypesTable.horizontalHeader().setHighlightSections(False)
        self.objectTypesTable.verticalHeader().setVisible(False)
        self.objectTypesTable.verticalHeader().setHighlightSections(False)
        self.verticalLayout_4.addWidget(self.objectTypesTable)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.addObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/images/22x22/add.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.addObjectTypeButton.setIcon(icon)
        self.addObjectTypeButton.setAutoRaise(True)
        self.addObjectTypeButton.setObjectName("addObjectTypeButton")
        self.horizontalLayout.addWidget(self.addObjectTypeButton)
        self.removeObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        self.removeObjectTypeButton.setEnabled(False)
        icon1 = QtGui.QIcon()
        icon1.addPixmap(QtGui.QPixmap(":/images/22x22/remove.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.removeObjectTypeButton.setIcon(icon1)
        self.removeObjectTypeButton.setAutoRaise(True)
        self.removeObjectTypeButton.setObjectName("removeObjectTypeButton")
        self.horizontalLayout.addWidget(self.removeObjectTypeButton)
        spacerItem2 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem2)
        self.importObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.importObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.importObjectTypesButton.setSizePolicy(sizePolicy)
        self.importObjectTypesButton.setObjectName("importObjectTypesButton")
        self.horizontalLayout.addWidget(self.importObjectTypesButton)
        self.exportObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.exportObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.exportObjectTypesButton.setSizePolicy(sizePolicy)
        self.exportObjectTypesButton.setObjectName("exportObjectTypesButton")
        self.horizontalLayout.addWidget(self.exportObjectTypesButton)
        self.verticalLayout_4.addLayout(self.horizontalLayout)
        self.verticalLayout_3.addWidget(self.groupBox_3)
        self.tabWidget.addTab(self.tab_2, "")
        self.tab_3 = QtWidgets.QWidget()
        self.tab_3.setObjectName("tab_3")
        self.autoMapWhileDrawing = QtWidgets.QCheckBox(self.tab_3)
        self.autoMapWhileDrawing.setGeometry(QtCore.QRect(10, 20, 391, 22))
        self.autoMapWhileDrawing.setObjectName("autoMapWhileDrawing")
        self.tabWidget.addTab(self.tab_3, "")
        self.verticalLayout.addWidget(self.tabWidget)
        self.buttonBox = QtWidgets.QDialogButtonBox(PreferencesDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Close)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout.addWidget(self.buttonBox)
        self.label_2.setBuddy(self.languageCombo)
        self.label_3.setBuddy(self.gridColor)
        self.label_4.setBuddy(self.gridFine)
        self.label.setBuddy(self.objectLineWidth)

        self.retranslateUi(PreferencesDialog)
        self.tabWidget.setCurrentIndex(0)
        self.buttonBox.rejected.connect(PreferencesDialog.reject)
        QtCore.QMetaObject.connectSlotsByName(PreferencesDialog)
        PreferencesDialog.setTabOrder(self.tabWidget, self.enableDtd)
        PreferencesDialog.setTabOrder(self.enableDtd, self.reloadTilesetImages)
        PreferencesDialog.setTabOrder(self.reloadTilesetImages, self.languageCombo)
        PreferencesDialog.setTabOrder(self.languageCombo, self.gridColor)
        PreferencesDialog.setTabOrder(self.gridColor, self.gridFine)
        PreferencesDialog.setTabOrder(self.gridFine, self.objectLineWidth)
        PreferencesDialog.setTabOrder(self.objectLineWidth, self.openGL)
        PreferencesDialog.setTabOrder(self.openGL, self.buttonBox)
        PreferencesDialog.setTabOrder(self.buttonBox, self.importObjectTypesButton)
        PreferencesDialog.setTabOrder(self.importObjectTypesButton, self.exportObjectTypesButton)
        PreferencesDialog.setTabOrder(self.exportObjectTypesButton, self.autoMapWhileDrawing)
        PreferencesDialog.setTabOrder(self.autoMapWhileDrawing, self.removeObjectTypeButton)
        PreferencesDialog.setTabOrder(self.removeObjectTypeButton, self.addObjectTypeButton)
        PreferencesDialog.setTabOrder(self.addObjectTypeButton, self.objectTypesTable)

    def retranslateUi(self, PreferencesDialog):
        _translate = QtCore.QCoreApplication.translate
        PreferencesDialog.setWindowTitle(_translate("PreferencesDialog", "Preferences"))
        self.groupBox.setTitle(_translate("PreferencesDialog", "Saving and Loading"))
        self.reloadTilesetImages.setText(_translate("PreferencesDialog", "&Reload tileset images when they change"))
        self.enableDtd.setToolTip(_translate("PreferencesDialog", "Not enabled by default since a reference to an external DTD is known to cause problems with some XML parsers."))
        self.enableDtd.setText(_translate("PreferencesDialog", "Include &DTD reference in saved maps"))
        self.openLastFiles.setText(_translate("PreferencesDialog", "Open last files on startup"))
        self.groupBox_2.setTitle(_translate("PreferencesDialog", "Interface"))
        self.openGL.setText(_translate("PreferencesDialog", "Hardware &accelerated drawing (OpenGL)"))
        self.label_2.setText(_translate("PreferencesDialog", "&Language:"))
        self.label_3.setText(_translate("PreferencesDialog", "Grid color:"))
        self.label_4.setText(_translate("PreferencesDialog", "Fine grid divisions:"))
        self.objectLineWidth.setSuffix(_translate("PreferencesDialog", " pixels"))
        self.label.setText(_translate("PreferencesDialog", "Object line width:"))
        self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab), _translate("PreferencesDialog", "General"))
        self.groupBox_3.setTitle(_translate("PreferencesDialog", "Object Types"))
        self.addObjectTypeButton.setToolTip(_translate("PreferencesDialog", "Add Object Type"))
        self.addObjectTypeButton.setText(_translate("PreferencesDialog", "Add"))
        self.removeObjectTypeButton.setToolTip(_translate("PreferencesDialog", "Remove Selected Object Types"))
        self.removeObjectTypeButton.setText(_translate("PreferencesDialog", "Remove"))
        self.importObjectTypesButton.setText(_translate("PreferencesDialog", "Import..."))
        self.exportObjectTypesButton.setText(_translate("PreferencesDialog", "Export..."))
        self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_2), _translate("PreferencesDialog", "Object Types"))
        self.autoMapWhileDrawing.setText(_translate("PreferencesDialog", "Use Automapping, when drawing into layers"))
        self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab_3), _translate("PreferencesDialog", "Automapping"))
    def setupUi(self, PreferencesDialog):
        PreferencesDialog.setObjectName("PreferencesDialog")
        PreferencesDialog.resize(421, 426)
        self.verticalLayout = QtWidgets.QVBoxLayout(PreferencesDialog)
        self.verticalLayout.setSizeConstraint(QtWidgets.QLayout.SetFixedSize)
        self.verticalLayout.setObjectName("verticalLayout")
        self.tabWidget = QtWidgets.QTabWidget(PreferencesDialog)
        self.tabWidget.setObjectName("tabWidget")
        self.tab = QtWidgets.QWidget()
        self.tab.setObjectName("tab")
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.tab)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.groupBox = QtWidgets.QGroupBox(self.tab)
        self.groupBox.setObjectName("groupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.groupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.reloadTilesetImages = QtWidgets.QCheckBox(self.groupBox)
        self.reloadTilesetImages.setObjectName("reloadTilesetImages")
        self.gridLayout.addWidget(self.reloadTilesetImages, 1, 0, 1, 2)
        self.enableDtd = QtWidgets.QCheckBox(self.groupBox)
        self.enableDtd.setObjectName("enableDtd")
        self.gridLayout.addWidget(self.enableDtd, 0, 0, 1, 2)
        self.openLastFiles = QtWidgets.QCheckBox(self.groupBox)
        self.openLastFiles.setChecked(True)
        self.openLastFiles.setObjectName("openLastFiles")
        self.gridLayout.addWidget(self.openLastFiles, 2, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox)
        self.groupBox_2 = QtWidgets.QGroupBox(self.tab)
        self.groupBox_2.setObjectName("groupBox_2")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox_2)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.openGL = QtWidgets.QCheckBox(self.groupBox_2)
        self.openGL.setObjectName("openGL")
        self.gridLayout_2.addWidget(self.openGL, 5, 0, 1, 4)
        self.label_2 = QtWidgets.QLabel(self.groupBox_2)
        self.label_2.setObjectName("label_2")
        self.gridLayout_2.addWidget(self.label_2, 0, 0, 1, 1)
        self.label_3 = QtWidgets.QLabel(self.groupBox_2)
        self.label_3.setObjectName("label_3")
        self.gridLayout_2.addWidget(self.label_3, 2, 0, 1, 1)
        self.gridColor = ColorButton(self.groupBox_2)
        self.gridColor.setObjectName("gridColor")
        self.gridLayout_2.addWidget(self.gridColor, 2, 3, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(0, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_2.addItem(spacerItem, 0, 4, 1, 1)
        self.languageCombo = QtWidgets.QComboBox(self.groupBox_2)
        self.languageCombo.setObjectName("languageCombo")
        self.gridLayout_2.addWidget(self.languageCombo, 0, 3, 1, 1)
        self.label_4 = QtWidgets.QLabel(self.groupBox_2)
        self.label_4.setObjectName("label_4")
        self.gridLayout_2.addWidget(self.label_4, 3, 0, 1, 1)
        self.gridFine = QtWidgets.QSpinBox(self.groupBox_2)
        self.gridFine.setMinimum(1)
        self.gridFine.setMaximum(128)
        self.gridFine.setObjectName("gridFine")
        self.gridLayout_2.addWidget(self.gridFine, 3, 3, 1, 1)
        self.objectLineWidth = QtWidgets.QDoubleSpinBox(self.groupBox_2)
        self.objectLineWidth.setDecimals(1)
        self.objectLineWidth.setMinimum(1.0)
        self.objectLineWidth.setProperty("value", 2.0)
        self.objectLineWidth.setObjectName("objectLineWidth")
        self.gridLayout_2.addWidget(self.objectLineWidth, 4, 3, 1, 1)
        self.label = QtWidgets.QLabel(self.groupBox_2)
        self.label.setObjectName("label")
        self.gridLayout_2.addWidget(self.label, 4, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox_2)
        spacerItem1 = QtWidgets.QSpacerItem(381, 1, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout_2.addItem(spacerItem1)
        self.tabWidget.addTab(self.tab, "")
        self.tab_2 = QtWidgets.QWidget()
        self.tab_2.setObjectName("tab_2")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.tab_2)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.groupBox_3 = QtWidgets.QGroupBox(self.tab_2)
        self.groupBox_3.setObjectName("groupBox_3")
        self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.groupBox_3)
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.objectTypesTable = QtWidgets.QTableView(self.groupBox_3)
        self.objectTypesTable.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows)
        self.objectTypesTable.setVerticalScrollMode(QtWidgets.QAbstractItemView.ScrollPerPixel)
        self.objectTypesTable.setWordWrap(False)
        self.objectTypesTable.setObjectName("objectTypesTable")
        self.objectTypesTable.horizontalHeader().setHighlightSections(False)
        self.objectTypesTable.verticalHeader().setVisible(False)
        self.objectTypesTable.verticalHeader().setHighlightSections(False)
        self.verticalLayout_4.addWidget(self.objectTypesTable)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.addObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/images/22x22/add.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.addObjectTypeButton.setIcon(icon)
        self.addObjectTypeButton.setAutoRaise(True)
        self.addObjectTypeButton.setObjectName("addObjectTypeButton")
        self.horizontalLayout.addWidget(self.addObjectTypeButton)
        self.removeObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        self.removeObjectTypeButton.setEnabled(False)
        icon1 = QtGui.QIcon()
        icon1.addPixmap(QtGui.QPixmap(":/images/22x22/remove.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.removeObjectTypeButton.setIcon(icon1)
        self.removeObjectTypeButton.setAutoRaise(True)
        self.removeObjectTypeButton.setObjectName("removeObjectTypeButton")
        self.horizontalLayout.addWidget(self.removeObjectTypeButton)
        spacerItem2 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem2)
        self.importObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.importObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.importObjectTypesButton.setSizePolicy(sizePolicy)
        self.importObjectTypesButton.setObjectName("importObjectTypesButton")
        self.horizontalLayout.addWidget(self.importObjectTypesButton)
        self.exportObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.exportObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.exportObjectTypesButton.setSizePolicy(sizePolicy)
        self.exportObjectTypesButton.setObjectName("exportObjectTypesButton")
        self.horizontalLayout.addWidget(self.exportObjectTypesButton)
        self.verticalLayout_4.addLayout(self.horizontalLayout)
        self.verticalLayout_3.addWidget(self.groupBox_3)
        self.tabWidget.addTab(self.tab_2, "")
        self.tab_3 = QtWidgets.QWidget()
        self.tab_3.setObjectName("tab_3")
        self.autoMapWhileDrawing = QtWidgets.QCheckBox(self.tab_3)
        self.autoMapWhileDrawing.setGeometry(QtCore.QRect(10, 20, 391, 22))
        self.autoMapWhileDrawing.setObjectName("autoMapWhileDrawing")
        self.tabWidget.addTab(self.tab_3, "")
        self.verticalLayout.addWidget(self.tabWidget)
        self.buttonBox = QtWidgets.QDialogButtonBox(PreferencesDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Close)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout.addWidget(self.buttonBox)
        self.label_2.setBuddy(self.languageCombo)
        self.label_3.setBuddy(self.gridColor)
        self.label_4.setBuddy(self.gridFine)
        self.label.setBuddy(self.objectLineWidth)

        self.retranslateUi(PreferencesDialog)
        self.tabWidget.setCurrentIndex(0)
        self.buttonBox.rejected.connect(PreferencesDialog.reject)
        QtCore.QMetaObject.connectSlotsByName(PreferencesDialog)
        PreferencesDialog.setTabOrder(self.tabWidget, self.enableDtd)
        PreferencesDialog.setTabOrder(self.enableDtd, self.reloadTilesetImages)
        PreferencesDialog.setTabOrder(self.reloadTilesetImages, self.languageCombo)
        PreferencesDialog.setTabOrder(self.languageCombo, self.gridColor)
        PreferencesDialog.setTabOrder(self.gridColor, self.gridFine)
        PreferencesDialog.setTabOrder(self.gridFine, self.objectLineWidth)
        PreferencesDialog.setTabOrder(self.objectLineWidth, self.openGL)
        PreferencesDialog.setTabOrder(self.openGL, self.buttonBox)
        PreferencesDialog.setTabOrder(self.buttonBox, self.importObjectTypesButton)
        PreferencesDialog.setTabOrder(self.importObjectTypesButton, self.exportObjectTypesButton)
        PreferencesDialog.setTabOrder(self.exportObjectTypesButton, self.autoMapWhileDrawing)
        PreferencesDialog.setTabOrder(self.autoMapWhileDrawing, self.removeObjectTypeButton)
        PreferencesDialog.setTabOrder(self.removeObjectTypeButton, self.addObjectTypeButton)
        PreferencesDialog.setTabOrder(self.addObjectTypeButton, self.objectTypesTable)
    def setupUi(self, Plot_Options_Dialog):
        Plot_Options_Dialog.setObjectName("Plot_Options_Dialog")
        Plot_Options_Dialog.setWindowModality(QtCore.Qt.WindowModal)
        Plot_Options_Dialog.resize(570, 358)
        Plot_Options_Dialog.setFocusPolicy(QtCore.Qt.TabFocus)
        self.vboxlayout = QtGui.QVBoxLayout(Plot_Options_Dialog)
        self.vboxlayout.setObjectName("vboxlayout")
        self.tabWidget = QtGui.QTabWidget(Plot_Options_Dialog)
        self.tabWidget.setMinimumSize(QtCore.QSize(0, 30))
        self.tabWidget.setObjectName("tabWidget")
        self.gen_options_tab = QtGui.QWidget()
        self.gen_options_tab.setObjectName("gen_options_tab")
        self.layoutWidget = QtGui.QWidget(self.gen_options_tab)
        self.layoutWidget.setGeometry(QtCore.QRect(33, 50, 295, 124))
        self.layoutWidget.setObjectName("layoutWidget")
        self.gridlayout = QtGui.QGridLayout(self.layoutWidget)
        self.gridlayout.setObjectName("gridlayout")
        self.label_3 = QtGui.QLabel(self.layoutWidget)
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setWeight(75)
        font.setBold(True)
        self.label_3.setFont(font)
        self.label_3.setAlignment(QtCore.Qt.AlignCenter)
        self.label_3.setObjectName("label_3")
        self.gridlayout.addWidget(self.label_3, 0, 1, 1, 1)
        self.label_4 = QtGui.QLabel(self.layoutWidget)
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setWeight(75)
        font.setBold(True)
        self.label_4.setFont(font)
        self.label_4.setAlignment(QtCore.Qt.AlignCenter)
        self.label_4.setObjectName("label_4")
        self.gridlayout.addWidget(self.label_4, 0, 2, 1, 1)
        self.min_label = QtGui.QLabel(self.layoutWidget)
        self.min_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.min_label.setObjectName("min_label")
        self.gridlayout.addWidget(self.min_label, 1, 0, 1, 1)
        self.xmin_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.xmin_lineEdit.setObjectName("xmin_lineEdit")
        self.gridlayout.addWidget(self.xmin_lineEdit, 1, 1, 1, 1)
        self.ymin_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.ymin_lineEdit.setObjectName("ymin_lineEdit")
        self.gridlayout.addWidget(self.ymin_lineEdit, 1, 2, 1, 1)
        self.max_label = QtGui.QLabel(self.layoutWidget)
        self.max_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.max_label.setObjectName("max_label")
        self.gridlayout.addWidget(self.max_label, 2, 0, 1, 1)
        self.xmax_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.xmax_lineEdit.setObjectName("xmax_lineEdit")
        self.gridlayout.addWidget(self.xmax_lineEdit, 2, 1, 1, 1)
        self.ymax_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.ymax_lineEdit.setObjectName("ymax_lineEdit")
        self.gridlayout.addWidget(self.ymax_lineEdit, 2, 2, 1, 1)
        self.axis_text_label = QtGui.QLabel(self.layoutWidget)
        self.axis_text_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.axis_text_label.setObjectName("axis_text_label")
        self.gridlayout.addWidget(self.axis_text_label, 3, 0, 1, 1)
        self.xlabel_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.xlabel_lineEdit.setObjectName("xlabel_lineEdit")
        self.gridlayout.addWidget(self.xlabel_lineEdit, 3, 1, 1, 1)
        self.ylabel_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.ylabel_lineEdit.setObjectName("ylabel_lineEdit")
        self.gridlayout.addWidget(self.ylabel_lineEdit, 3, 2, 1, 1)
        self.logy_cb = QtGui.QCheckBox(self.gen_options_tab)
        self.logy_cb.setGeometry(QtCore.QRect(43, 220, 83, 23))
        self.logy_cb.setObjectName("logy_cb")
        self.plot_title_label = QtGui.QLabel(self.gen_options_tab)
        self.plot_title_label.setGeometry(QtCore.QRect(33, 10, 61, 27))
        self.plot_title_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.plot_title_label.setObjectName("plot_title_label")
        self.logx_cb = QtGui.QCheckBox(self.gen_options_tab)
        self.logx_cb.setGeometry(QtCore.QRect(43, 190, 83, 23))
        self.logx_cb.setObjectName("logx_cb")
        self.plottitle_lineEdit = QtGui.QLineEdit(self.gen_options_tab)
        self.plottitle_lineEdit.setGeometry(QtCore.QRect(100, 10, 291, 27))
        self.plottitle_lineEdit.setObjectName("plottitle_lineEdit")
        self.toggleGrid_btn = QtGui.QPushButton(self.gen_options_tab)
        self.toggleGrid_btn.setGeometry(QtCore.QRect(150, 190, 75, 23))
        self.toggleGrid_btn.setObjectName("toggleGrid_btn")
        self.tabWidget.addTab(self.gen_options_tab, "")
        self.trace_options_tab = QtGui.QWidget()
        self.trace_options_tab.setObjectName("trace_options_tab")
        self.gridlayout1 = QtGui.QGridLayout(self.trace_options_tab)
        self.gridlayout1.setObjectName("gridlayout1")
        self.gridlayout2 = QtGui.QGridLayout()
        self.gridlayout2.setObjectName("gridlayout2")
        self.label_11 = QtGui.QLabel(self.trace_options_tab)
        self.label_11.setObjectName("label_11")
        self.gridlayout2.addWidget(self.label_11, 0, 0, 1, 1)
        self.activePlotListWidget = QtGui.QListWidget(self.trace_options_tab)
        self.activePlotListWidget.setObjectName("activePlotListWidget")
        self.gridlayout2.addWidget(self.activePlotListWidget, 1, 0, 1, 1)
        self.gridlayout1.addLayout(self.gridlayout2, 0, 0, 4, 1)
        self.label = QtGui.QLabel(self.trace_options_tab)
        self.label.setObjectName("label")
        self.gridlayout1.addWidget(self.label, 0, 1, 1, 1)
        self.lstyle_comboBox = QtGui.QComboBox(self.trace_options_tab)
        self.lstyle_comboBox.setObjectName("lstyle_comboBox")
        self.gridlayout1.addWidget(self.lstyle_comboBox, 0, 2, 1, 1)
        self.label_8 = QtGui.QLabel(self.trace_options_tab)
        self.label_8.setObjectName("label_8")
        self.gridlayout1.addWidget(self.label_8, 1, 1, 1, 1)
        self.label_5 = QtGui.QLabel(self.trace_options_tab)
        self.label_5.setObjectName("label_5")
        self.gridlayout1.addWidget(self.label_5, 2, 1, 1, 1)
        self.mstyle_comboBox = QtGui.QComboBox(self.trace_options_tab)
        self.mstyle_comboBox.setObjectName("mstyle_comboBox")
        self.gridlayout1.addWidget(self.mstyle_comboBox, 2, 2, 1, 1)
        self.label_2 = QtGui.QLabel(self.trace_options_tab)
        self.label_2.setObjectName("label_2")
        self.gridlayout1.addWidget(self.label_2, 3, 1, 1, 1)
        self.lw_spinBox = QtGui.QDoubleSpinBox(self.trace_options_tab)
        self.lw_spinBox.setMinimum(0.25)
        self.lw_spinBox.setMaximum(50.0)
        self.lw_spinBox.setSingleStep(0.25)
        self.lw_spinBox.setProperty("value", QtCore.QVariant(1.0))
        self.lw_spinBox.setObjectName("lw_spinBox")
        self.gridlayout1.addWidget(self.lw_spinBox, 1, 2, 1, 1)
        self.ms_spinBox = QtGui.QDoubleSpinBox(self.trace_options_tab)
        self.ms_spinBox.setMinimum(0.25)
        self.ms_spinBox.setMaximum(50.0)
        self.ms_spinBox.setSingleStep(0.25)
        self.ms_spinBox.setProperty("value", QtCore.QVariant(1.0))
        self.ms_spinBox.setObjectName("ms_spinBox")
        self.gridlayout1.addWidget(self.ms_spinBox, 3, 2, 1, 1)
        self.lineColorBtn = ColorButton(self.trace_options_tab)
        self.lineColorBtn.setEnabled(True)
        self.lineColorBtn.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon)
        self.lineColorBtn.setObjectName("lineColorBtn")
        self.gridlayout1.addWidget(self.lineColorBtn, 4, 1, 1, 1)
        self.markerColorBtn = ColorButton(self.trace_options_tab)
        self.markerColorBtn.setEnabled(True)
        self.markerColorBtn.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon)
        self.markerColorBtn.setObjectName("markerColorBtn")
        self.gridlayout1.addWidget(self.markerColorBtn, 4, 2, 1, 1)
        self.tabWidget.addTab(self.trace_options_tab, "")
        self.vboxlayout.addWidget(self.tabWidget)
        self.buttonBox = QtGui.QDialogButtonBox(Plot_Options_Dialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.NoButton|QtGui.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.vboxlayout.addWidget(self.buttonBox)

        self.retranslateUi(Plot_Options_Dialog)
        self.tabWidget.setCurrentIndex(0)
        QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("accepted()"), Plot_Options_Dialog.accept)
        QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("rejected()"), Plot_Options_Dialog.reject)
        QtCore.QMetaObject.connectSlotsByName(Plot_Options_Dialog)
Exemple #8
0
    def setupUi(self, Plot_Options_Dialog):
        Plot_Options_Dialog.setObjectName("Plot_Options_Dialog")
        Plot_Options_Dialog.setWindowModality(QtCore.Qt.WindowModal)
        Plot_Options_Dialog.resize(570, 358)
        Plot_Options_Dialog.setFocusPolicy(QtCore.Qt.TabFocus)
        self.vboxlayout = QtGui.QVBoxLayout(Plot_Options_Dialog)
        self.vboxlayout.setObjectName("vboxlayout")
        self.tabWidget = QtGui.QTabWidget(Plot_Options_Dialog)
        self.tabWidget.setMinimumSize(QtCore.QSize(0, 30))
        self.tabWidget.setObjectName("tabWidget")
        self.gen_options_tab = QtGui.QWidget()
        self.gen_options_tab.setObjectName("gen_options_tab")
        self.layoutWidget = QtGui.QWidget(self.gen_options_tab)
        self.layoutWidget.setGeometry(QtCore.QRect(33, 50, 295, 124))
        self.layoutWidget.setObjectName("layoutWidget")
        self.gridlayout = QtGui.QGridLayout(self.layoutWidget)
        self.gridlayout.setObjectName("gridlayout")
        self.label_3 = QtGui.QLabel(self.layoutWidget)
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setWeight(75)
        font.setBold(True)
        self.label_3.setFont(font)
        self.label_3.setAlignment(QtCore.Qt.AlignCenter)
        self.label_3.setObjectName("label_3")
        self.gridlayout.addWidget(self.label_3, 0, 1, 1, 1)
        self.label_4 = QtGui.QLabel(self.layoutWidget)
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setWeight(75)
        font.setBold(True)
        self.label_4.setFont(font)
        self.label_4.setAlignment(QtCore.Qt.AlignCenter)
        self.label_4.setObjectName("label_4")
        self.gridlayout.addWidget(self.label_4, 0, 2, 1, 1)
        self.min_label = QtGui.QLabel(self.layoutWidget)
        self.min_label.setAlignment(QtCore.Qt.AlignRight
                                    | QtCore.Qt.AlignTrailing
                                    | QtCore.Qt.AlignVCenter)
        self.min_label.setObjectName("min_label")
        self.gridlayout.addWidget(self.min_label, 1, 0, 1, 1)
        self.xmin_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.xmin_lineEdit.setObjectName("xmin_lineEdit")
        self.gridlayout.addWidget(self.xmin_lineEdit, 1, 1, 1, 1)
        self.ymin_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.ymin_lineEdit.setObjectName("ymin_lineEdit")
        self.gridlayout.addWidget(self.ymin_lineEdit, 1, 2, 1, 1)
        self.max_label = QtGui.QLabel(self.layoutWidget)
        self.max_label.setAlignment(QtCore.Qt.AlignRight
                                    | QtCore.Qt.AlignTrailing
                                    | QtCore.Qt.AlignVCenter)
        self.max_label.setObjectName("max_label")
        self.gridlayout.addWidget(self.max_label, 2, 0, 1, 1)
        self.xmax_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.xmax_lineEdit.setObjectName("xmax_lineEdit")
        self.gridlayout.addWidget(self.xmax_lineEdit, 2, 1, 1, 1)
        self.ymax_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.ymax_lineEdit.setObjectName("ymax_lineEdit")
        self.gridlayout.addWidget(self.ymax_lineEdit, 2, 2, 1, 1)
        self.axis_text_label = QtGui.QLabel(self.layoutWidget)
        self.axis_text_label.setAlignment(QtCore.Qt.AlignRight
                                          | QtCore.Qt.AlignTrailing
                                          | QtCore.Qt.AlignVCenter)
        self.axis_text_label.setObjectName("axis_text_label")
        self.gridlayout.addWidget(self.axis_text_label, 3, 0, 1, 1)
        self.xlabel_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.xlabel_lineEdit.setObjectName("xlabel_lineEdit")
        self.gridlayout.addWidget(self.xlabel_lineEdit, 3, 1, 1, 1)
        self.ylabel_lineEdit = QtGui.QLineEdit(self.layoutWidget)
        self.ylabel_lineEdit.setObjectName("ylabel_lineEdit")
        self.gridlayout.addWidget(self.ylabel_lineEdit, 3, 2, 1, 1)
        self.logy_cb = QtGui.QCheckBox(self.gen_options_tab)
        self.logy_cb.setGeometry(QtCore.QRect(43, 220, 83, 23))
        self.logy_cb.setObjectName("logy_cb")
        self.plot_title_label = QtGui.QLabel(self.gen_options_tab)
        self.plot_title_label.setGeometry(QtCore.QRect(33, 10, 61, 27))
        self.plot_title_label.setAlignment(QtCore.Qt.AlignRight
                                           | QtCore.Qt.AlignTrailing
                                           | QtCore.Qt.AlignVCenter)
        self.plot_title_label.setObjectName("plot_title_label")
        self.logx_cb = QtGui.QCheckBox(self.gen_options_tab)
        self.logx_cb.setGeometry(QtCore.QRect(43, 190, 83, 23))
        self.logx_cb.setObjectName("logx_cb")
        self.plottitle_lineEdit = QtGui.QLineEdit(self.gen_options_tab)
        self.plottitle_lineEdit.setGeometry(QtCore.QRect(100, 10, 291, 27))
        self.plottitle_lineEdit.setObjectName("plottitle_lineEdit")
        self.toggleGrid_btn = QtGui.QPushButton(self.gen_options_tab)
        self.toggleGrid_btn.setGeometry(QtCore.QRect(150, 190, 75, 23))
        self.toggleGrid_btn.setObjectName("toggleGrid_btn")
        self.tabWidget.addTab(self.gen_options_tab, "")
        self.trace_options_tab = QtGui.QWidget()
        self.trace_options_tab.setObjectName("trace_options_tab")
        self.gridlayout1 = QtGui.QGridLayout(self.trace_options_tab)
        self.gridlayout1.setObjectName("gridlayout1")
        self.gridlayout2 = QtGui.QGridLayout()
        self.gridlayout2.setObjectName("gridlayout2")
        self.label_11 = QtGui.QLabel(self.trace_options_tab)
        self.label_11.setObjectName("label_11")
        self.gridlayout2.addWidget(self.label_11, 0, 0, 1, 1)
        self.activePlotListWidget = QtGui.QListWidget(self.trace_options_tab)
        self.activePlotListWidget.setObjectName("activePlotListWidget")
        self.gridlayout2.addWidget(self.activePlotListWidget, 1, 0, 1, 1)
        self.gridlayout1.addLayout(self.gridlayout2, 0, 0, 4, 1)
        self.label = QtGui.QLabel(self.trace_options_tab)
        self.label.setObjectName("label")
        self.gridlayout1.addWidget(self.label, 0, 1, 1, 1)
        self.lstyle_comboBox = QtGui.QComboBox(self.trace_options_tab)
        self.lstyle_comboBox.setObjectName("lstyle_comboBox")
        self.gridlayout1.addWidget(self.lstyle_comboBox, 0, 2, 1, 1)
        self.label_8 = QtGui.QLabel(self.trace_options_tab)
        self.label_8.setObjectName("label_8")
        self.gridlayout1.addWidget(self.label_8, 1, 1, 1, 1)
        self.label_5 = QtGui.QLabel(self.trace_options_tab)
        self.label_5.setObjectName("label_5")
        self.gridlayout1.addWidget(self.label_5, 2, 1, 1, 1)
        self.mstyle_comboBox = QtGui.QComboBox(self.trace_options_tab)
        self.mstyle_comboBox.setObjectName("mstyle_comboBox")
        self.gridlayout1.addWidget(self.mstyle_comboBox, 2, 2, 1, 1)
        self.label_2 = QtGui.QLabel(self.trace_options_tab)
        self.label_2.setObjectName("label_2")
        self.gridlayout1.addWidget(self.label_2, 3, 1, 1, 1)
        self.lw_spinBox = QtGui.QDoubleSpinBox(self.trace_options_tab)
        self.lw_spinBox.setMinimum(0.25)
        self.lw_spinBox.setMaximum(50.0)
        self.lw_spinBox.setSingleStep(0.25)
        self.lw_spinBox.setProperty("value", QtCore.QVariant(1.0))
        self.lw_spinBox.setObjectName("lw_spinBox")
        self.gridlayout1.addWidget(self.lw_spinBox, 1, 2, 1, 1)
        self.ms_spinBox = QtGui.QDoubleSpinBox(self.trace_options_tab)
        self.ms_spinBox.setMinimum(0.25)
        self.ms_spinBox.setMaximum(50.0)
        self.ms_spinBox.setSingleStep(0.25)
        self.ms_spinBox.setProperty("value", QtCore.QVariant(1.0))
        self.ms_spinBox.setObjectName("ms_spinBox")
        self.gridlayout1.addWidget(self.ms_spinBox, 3, 2, 1, 1)
        self.lineColorBtn = ColorButton(self.trace_options_tab)
        self.lineColorBtn.setEnabled(True)
        self.lineColorBtn.setToolButtonStyle(
            QtCore.Qt.ToolButtonTextBesideIcon)
        self.lineColorBtn.setObjectName("lineColorBtn")
        self.gridlayout1.addWidget(self.lineColorBtn, 4, 1, 1, 1)
        self.markerColorBtn = ColorButton(self.trace_options_tab)
        self.markerColorBtn.setEnabled(True)
        self.markerColorBtn.setToolButtonStyle(
            QtCore.Qt.ToolButtonTextBesideIcon)
        self.markerColorBtn.setObjectName("markerColorBtn")
        self.gridlayout1.addWidget(self.markerColorBtn, 4, 2, 1, 1)
        self.tabWidget.addTab(self.trace_options_tab, "")
        self.vboxlayout.addWidget(self.tabWidget)
        self.buttonBox = QtGui.QDialogButtonBox(Plot_Options_Dialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel
                                          | QtGui.QDialogButtonBox.NoButton
                                          | QtGui.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.vboxlayout.addWidget(self.buttonBox)

        self.retranslateUi(Plot_Options_Dialog)
        self.tabWidget.setCurrentIndex(0)
        QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("accepted()"),
                               Plot_Options_Dialog.accept)
        QtCore.QObject.connect(self.buttonBox, QtCore.SIGNAL("rejected()"),
                               Plot_Options_Dialog.reject)
        QtCore.QMetaObject.connectSlotsByName(Plot_Options_Dialog)
    def setupUi(self, dlgPlotOptions):
        dlgPlotOptions.setObjectName("dlgPlotOptions")
        dlgPlotOptions.setWindowModality(QtCore.Qt.WindowModal)
        dlgPlotOptions.resize(545, 278)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(dlgPlotOptions.sizePolicy().hasHeightForWidth())
        dlgPlotOptions.setSizePolicy(sizePolicy)
        dlgPlotOptions.setFocusPolicy(QtCore.Qt.TabFocus)
        self.buttonBox = QtGui.QDialogButtonBox(dlgPlotOptions)
        self.buttonBox.setGeometry(QtCore.QRect(9, 599, 731, 25))
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.mcmbBLineW = QtGui.QComboBox(dlgPlotOptions)
        self.mcmbBLineW.setGeometry(QtCore.QRect(400, 100, 121, 20))
        self.mcmbBLineW.setEditable(True)
        self.mcmbBLineW.setObjectName("mcmbBLineW")
        self.mcmbBLineStyle = QtGui.QComboBox(dlgPlotOptions)
        self.mcmbBLineStyle.setGeometry(QtCore.QRect(400, 70, 121, 20))
        self.mcmbBLineStyle.setObjectName("mcmbBLineStyle")
        self.mcmbBMarkerSize = QtGui.QComboBox(dlgPlotOptions)
        self.mcmbBMarkerSize.setGeometry(QtCore.QRect(400, 160, 121, 20))
        self.mcmbBMarkerSize.setEditable(True)
        self.mcmbBMarkerSize.setObjectName("mcmbBMarkerSize")
        self.label_7 = QtGui.QLabel(dlgPlotOptions)
        self.label_7.setGeometry(QtCore.QRect(329, 190, 82, 20))
        self.label_7.setObjectName("label_7")
        self.mtoolBtnColor = ColorButton(dlgPlotOptions)
        self.mtoolBtnColor.setEnabled(True)
        self.mtoolBtnColor.setGeometry(QtCore.QRect(400, 190, 121, 21))
        self.mtoolBtnColor.setLayoutDirection(QtCore.Qt.LeftToRight)
        self.mtoolBtnColor.setToolButtonStyle(QtCore.Qt.ToolButtonTextBesideIcon)
        self.mtoolBtnColor.setObjectName("mtoolBtnColor")
        self.label_2 = QtGui.QLabel(dlgPlotOptions)
        self.label_2.setGeometry(QtCore.QRect(339, 100, 71, 20))
        self.label_2.setObjectName("label_2")
        self.label_6 = QtGui.QLabel(dlgPlotOptions)
        self.label_6.setGeometry(QtCore.QRect(335, 160, 82, 20))
        self.label_6.setObjectName("label_6")
        self.label = QtGui.QLabel(dlgPlotOptions)
        self.label.setGeometry(QtCore.QRect(342, 70, 82, 20))
        self.label.setObjectName("label")
        self.label_5 = QtGui.QLabel(dlgPlotOptions)
        self.label_5.setGeometry(QtCore.QRect(330, 130, 82, 20))
        self.label_5.setObjectName("label_5")
        self.mcmbBMarkerStyle = QtGui.QComboBox(dlgPlotOptions)
        self.mcmbBMarkerStyle.setGeometry(QtCore.QRect(400, 130, 121, 20))
        self.mcmbBMarkerStyle.setObjectName("mcmbBMarkerStyle")
        self.mlineEditYmin = QtGui.QLineEdit(dlgPlotOptions)
        self.mlineEditYmin.setGeometry(QtCore.QRect(202, 70, 117, 20))
        self.mlineEditYmin.setObjectName("mlineEditYmin")
        self.min_label = QtGui.QLabel(dlgPlotOptions)
        self.min_label.setGeometry(QtCore.QRect(26, 70, 48, 20))
        self.min_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.min_label.setObjectName("min_label")
        self.mchkBoxLogX = QtGui.QCheckBox(dlgPlotOptions)
        self.mchkBoxLogX.setGeometry(QtCore.QRect(80, 150, 83, 23))
        self.mchkBoxLogX.setObjectName("mchkBoxLogX")
        self.mlineEditTitle = QtGui.QLineEdit(dlgPlotOptions)
        self.mlineEditTitle.setGeometry(QtCore.QRect(77, 16, 241, 21))
        self.mlineEditTitle.setObjectName("mlineEditTitle")
        self.mchkBoxGrid = QtGui.QCheckBox(dlgPlotOptions)
        self.mchkBoxGrid.setGeometry(QtCore.QRect(80, 180, 83, 23))
        self.mchkBoxGrid.setChecked(True)
        self.mchkBoxGrid.setObjectName("mchkBoxGrid")
        self.mlineEditYmax = QtGui.QLineEdit(dlgPlotOptions)
        self.mlineEditYmax.setGeometry(QtCore.QRect(202, 96, 117, 20))
        self.mlineEditYmax.setObjectName("mlineEditYmax")
        self.mlineEditYlabel = QtGui.QLineEdit(dlgPlotOptions)
        self.mlineEditYlabel.setGeometry(QtCore.QRect(202, 122, 117, 20))
        self.mlineEditYlabel.setObjectName("mlineEditYlabel")
        self.label_4 = QtGui.QLabel(dlgPlotOptions)
        self.label_4.setGeometry(QtCore.QRect(202, 33, 117, 41))
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setWeight(75)
        font.setBold(True)
        self.label_4.setFont(font)
        self.label_4.setAlignment(QtCore.Qt.AlignCenter)
        self.label_4.setObjectName("label_4")
        self.mlineEditXmin = QtGui.QLineEdit(dlgPlotOptions)
        self.mlineEditXmin.setGeometry(QtCore.QRect(80, 70, 116, 20))
        self.mlineEditXmin.setObjectName("mlineEditXmin")
        self.plot_title_label = QtGui.QLabel(dlgPlotOptions)
        self.plot_title_label.setGeometry(QtCore.QRect(10, 10, 61, 27))
        self.plot_title_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.plot_title_label.setObjectName("plot_title_label")
        self.mchkBoxLogY = QtGui.QCheckBox(dlgPlotOptions)
        self.mchkBoxLogY.setGeometry(QtCore.QRect(200, 150, 83, 23))
        self.mchkBoxLogY.setObjectName("mchkBoxLogY")
        self.mlineEditXmax = QtGui.QLineEdit(dlgPlotOptions)
        self.mlineEditXmax.setGeometry(QtCore.QRect(80, 96, 116, 20))
        self.mlineEditXmax.setObjectName("mlineEditXmax")
        self.mlineEditXlabel = QtGui.QLineEdit(dlgPlotOptions)
        self.mlineEditXlabel.setGeometry(QtCore.QRect(80, 122, 116, 20))
        self.mlineEditXlabel.setObjectName("mlineEditXlabel")
        self.axis_text_label = QtGui.QLabel(dlgPlotOptions)
        self.axis_text_label.setGeometry(QtCore.QRect(26, 122, 48, 20))
        self.axis_text_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.axis_text_label.setObjectName("axis_text_label")
        self.label_3 = QtGui.QLabel(dlgPlotOptions)
        self.label_3.setGeometry(QtCore.QRect(80, 33, 116, 41))
        font = QtGui.QFont()
        font.setPointSize(10)
        font.setWeight(75)
        font.setBold(True)
        self.label_3.setFont(font)
        self.label_3.setAlignment(QtCore.Qt.AlignCenter)
        self.label_3.setObjectName("label_3")
        self.max_label = QtGui.QLabel(dlgPlotOptions)
        self.max_label.setGeometry(QtCore.QRect(26, 96, 48, 20))
        self.max_label.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
        self.max_label.setObjectName("max_label")
        self.mBtnBox = QtGui.QDialogButtonBox(dlgPlotOptions)
        self.mBtnBox.setGeometry(QtCore.QRect(100, 240, 431, 25))
        self.mBtnBox.setOrientation(QtCore.Qt.Horizontal)
        self.mBtnBox.setStandardButtons(QtGui.QDialogButtonBox.Cancel|QtGui.QDialogButtonBox.Ok)
        self.mBtnBox.setObjectName("mBtnBox")
        self.line = QtGui.QFrame(dlgPlotOptions)
        self.line.setGeometry(QtCore.QRect(10, 220, 521, 16))
        self.line.setFrameShape(QtGui.QFrame.HLine)
        self.line.setFrameShadow(QtGui.QFrame.Sunken)
        self.line.setObjectName("line")

        self.retranslateUi(dlgPlotOptions)
        QtCore.QObject.connect(self.mBtnBox, QtCore.SIGNAL("accepted()"), dlgPlotOptions.accept)
        QtCore.QObject.connect(self.mBtnBox, QtCore.SIGNAL("rejected()"), dlgPlotOptions.reject)
        QtCore.QMetaObject.connectSlotsByName(dlgPlotOptions)
Exemple #10
0
    def __init__(self):
        super().__init__()

        palette = ColorButton()
        palette.colorChanged.connect(self.show_selected_color)
        self.setCentralWidget(palette)
Exemple #11
0
    def setupUi(self, PreferencesDialog):
        PreferencesDialog.setObjectName("PreferencesDialog")
        PreferencesDialog.resize(421, 426)
        self.verticalLayout = QtWidgets.QVBoxLayout(PreferencesDialog)
        self.verticalLayout.setSizeConstraint(QtWidgets.QLayout.SetFixedSize)
        self.verticalLayout.setObjectName("verticalLayout")
        self.tabWidget = QtWidgets.QTabWidget(PreferencesDialog)
        self.tabWidget.setObjectName("tabWidget")
        self.tab = QtWidgets.QWidget()
        self.tab.setObjectName("tab")
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.tab)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.groupBox = QtWidgets.QGroupBox(self.tab)
        self.groupBox.setObjectName("groupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.groupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.reloadTilesetImages = QtWidgets.QCheckBox(self.groupBox)
        self.reloadTilesetImages.setObjectName("reloadTilesetImages")
        self.gridLayout.addWidget(self.reloadTilesetImages, 1, 0, 1, 2)
        self.enableDtd = QtWidgets.QCheckBox(self.groupBox)
        self.enableDtd.setObjectName("enableDtd")
        self.gridLayout.addWidget(self.enableDtd, 0, 0, 1, 2)
        self.openLastFiles = QtWidgets.QCheckBox(self.groupBox)
        self.openLastFiles.setChecked(True)
        self.openLastFiles.setObjectName("openLastFiles")
        self.gridLayout.addWidget(self.openLastFiles, 2, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox)
        self.groupBox_2 = QtWidgets.QGroupBox(self.tab)
        self.groupBox_2.setObjectName("groupBox_2")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox_2)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.openGL = QtWidgets.QCheckBox(self.groupBox_2)
        self.openGL.setObjectName("openGL")
        self.gridLayout_2.addWidget(self.openGL, 5, 0, 1, 4)
        self.label_2 = QtWidgets.QLabel(self.groupBox_2)
        self.label_2.setObjectName("label_2")
        self.gridLayout_2.addWidget(self.label_2, 0, 0, 1, 1)
        self.label_3 = QtWidgets.QLabel(self.groupBox_2)
        self.label_3.setObjectName("label_3")
        self.gridLayout_2.addWidget(self.label_3, 2, 0, 1, 1)
        self.gridColor = ColorButton(self.groupBox_2)
        self.gridColor.setObjectName("gridColor")
        self.gridLayout_2.addWidget(self.gridColor, 2, 3, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(0, 20,
                                           QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_2.addItem(spacerItem, 0, 4, 1, 1)
        self.languageCombo = QtWidgets.QComboBox(self.groupBox_2)
        self.languageCombo.setObjectName("languageCombo")
        self.gridLayout_2.addWidget(self.languageCombo, 0, 3, 1, 1)
        self.label_4 = QtWidgets.QLabel(self.groupBox_2)
        self.label_4.setObjectName("label_4")
        self.gridLayout_2.addWidget(self.label_4, 3, 0, 1, 1)
        self.gridFine = QtWidgets.QSpinBox(self.groupBox_2)
        self.gridFine.setMinimum(1)
        self.gridFine.setMaximum(128)
        self.gridFine.setObjectName("gridFine")
        self.gridLayout_2.addWidget(self.gridFine, 3, 3, 1, 1)
        self.objectLineWidth = QtWidgets.QDoubleSpinBox(self.groupBox_2)
        self.objectLineWidth.setDecimals(1)
        self.objectLineWidth.setMinimum(1.0)
        self.objectLineWidth.setProperty("value", 2.0)
        self.objectLineWidth.setObjectName("objectLineWidth")
        self.gridLayout_2.addWidget(self.objectLineWidth, 4, 3, 1, 1)
        self.label = QtWidgets.QLabel(self.groupBox_2)
        self.label.setObjectName("label")
        self.gridLayout_2.addWidget(self.label, 4, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox_2)
        spacerItem1 = QtWidgets.QSpacerItem(381, 1,
                                            QtWidgets.QSizePolicy.Minimum,
                                            QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout_2.addItem(spacerItem1)
        self.tabWidget.addTab(self.tab, "")
        self.tab_2 = QtWidgets.QWidget()
        self.tab_2.setObjectName("tab_2")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.tab_2)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.groupBox_3 = QtWidgets.QGroupBox(self.tab_2)
        self.groupBox_3.setObjectName("groupBox_3")
        self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.groupBox_3)
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.objectTypesTable = QtWidgets.QTableView(self.groupBox_3)
        self.objectTypesTable.setSelectionBehavior(
            QtWidgets.QAbstractItemView.SelectRows)
        self.objectTypesTable.setVerticalScrollMode(
            QtWidgets.QAbstractItemView.ScrollPerPixel)
        self.objectTypesTable.setWordWrap(False)
        self.objectTypesTable.setObjectName("objectTypesTable")
        self.objectTypesTable.horizontalHeader().setHighlightSections(False)
        self.objectTypesTable.verticalHeader().setVisible(False)
        self.objectTypesTable.verticalHeader().setHighlightSections(False)
        self.verticalLayout_4.addWidget(self.objectTypesTable)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.addObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/images/22x22/add.png"),
                       QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.addObjectTypeButton.setIcon(icon)
        self.addObjectTypeButton.setAutoRaise(True)
        self.addObjectTypeButton.setObjectName("addObjectTypeButton")
        self.horizontalLayout.addWidget(self.addObjectTypeButton)
        self.removeObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        self.removeObjectTypeButton.setEnabled(False)
        icon1 = QtGui.QIcon()
        icon1.addPixmap(QtGui.QPixmap(":/images/22x22/remove.png"),
                        QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.removeObjectTypeButton.setIcon(icon1)
        self.removeObjectTypeButton.setAutoRaise(True)
        self.removeObjectTypeButton.setObjectName("removeObjectTypeButton")
        self.horizontalLayout.addWidget(self.removeObjectTypeButton)
        spacerItem2 = QtWidgets.QSpacerItem(40, 20,
                                            QtWidgets.QSizePolicy.Expanding,
                                            QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem2)
        self.importObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.importObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.importObjectTypesButton.setSizePolicy(sizePolicy)
        self.importObjectTypesButton.setObjectName("importObjectTypesButton")
        self.horizontalLayout.addWidget(self.importObjectTypesButton)
        self.exportObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed,
                                           QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.exportObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.exportObjectTypesButton.setSizePolicy(sizePolicy)
        self.exportObjectTypesButton.setObjectName("exportObjectTypesButton")
        self.horizontalLayout.addWidget(self.exportObjectTypesButton)
        self.verticalLayout_4.addLayout(self.horizontalLayout)
        self.verticalLayout_3.addWidget(self.groupBox_3)
        self.tabWidget.addTab(self.tab_2, "")
        self.tab_3 = QtWidgets.QWidget()
        self.tab_3.setObjectName("tab_3")
        self.autoMapWhileDrawing = QtWidgets.QCheckBox(self.tab_3)
        self.autoMapWhileDrawing.setGeometry(QtCore.QRect(10, 20, 391, 22))
        self.autoMapWhileDrawing.setObjectName("autoMapWhileDrawing")
        self.tabWidget.addTab(self.tab_3, "")
        self.verticalLayout.addWidget(self.tabWidget)
        self.buttonBox = QtWidgets.QDialogButtonBox(PreferencesDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Close)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout.addWidget(self.buttonBox)
        self.label_2.setBuddy(self.languageCombo)
        self.label_3.setBuddy(self.gridColor)
        self.label_4.setBuddy(self.gridFine)
        self.label.setBuddy(self.objectLineWidth)

        self.retranslateUi(PreferencesDialog)
        self.tabWidget.setCurrentIndex(0)
        self.buttonBox.rejected.connect(PreferencesDialog.reject)
        QtCore.QMetaObject.connectSlotsByName(PreferencesDialog)
        PreferencesDialog.setTabOrder(self.tabWidget, self.enableDtd)
        PreferencesDialog.setTabOrder(self.enableDtd, self.reloadTilesetImages)
        PreferencesDialog.setTabOrder(self.reloadTilesetImages,
                                      self.languageCombo)
        PreferencesDialog.setTabOrder(self.languageCombo, self.gridColor)
        PreferencesDialog.setTabOrder(self.gridColor, self.gridFine)
        PreferencesDialog.setTabOrder(self.gridFine, self.objectLineWidth)
        PreferencesDialog.setTabOrder(self.objectLineWidth, self.openGL)
        PreferencesDialog.setTabOrder(self.openGL, self.buttonBox)
        PreferencesDialog.setTabOrder(self.buttonBox,
                                      self.importObjectTypesButton)
        PreferencesDialog.setTabOrder(self.importObjectTypesButton,
                                      self.exportObjectTypesButton)
        PreferencesDialog.setTabOrder(self.exportObjectTypesButton,
                                      self.autoMapWhileDrawing)
        PreferencesDialog.setTabOrder(self.autoMapWhileDrawing,
                                      self.removeObjectTypeButton)
        PreferencesDialog.setTabOrder(self.removeObjectTypeButton,
                                      self.addObjectTypeButton)
        PreferencesDialog.setTabOrder(self.addObjectTypeButton,
                                      self.objectTypesTable)
Exemple #12
0
class Ui_PreferencesDialog(object):
    def setupUi(self, PreferencesDialog):
        PreferencesDialog.setObjectName("PreferencesDialog")
        PreferencesDialog.resize(421, 426)
        self.verticalLayout = QtWidgets.QVBoxLayout(PreferencesDialog)
        self.verticalLayout.setSizeConstraint(QtWidgets.QLayout.SetFixedSize)
        self.verticalLayout.setObjectName("verticalLayout")
        self.tabWidget = QtWidgets.QTabWidget(PreferencesDialog)
        self.tabWidget.setObjectName("tabWidget")
        self.tab = QtWidgets.QWidget()
        self.tab.setObjectName("tab")
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.tab)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.groupBox = QtWidgets.QGroupBox(self.tab)
        self.groupBox.setObjectName("groupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.groupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.reloadTilesetImages = QtWidgets.QCheckBox(self.groupBox)
        self.reloadTilesetImages.setObjectName("reloadTilesetImages")
        self.gridLayout.addWidget(self.reloadTilesetImages, 1, 0, 1, 2)
        self.enableDtd = QtWidgets.QCheckBox(self.groupBox)
        self.enableDtd.setObjectName("enableDtd")
        self.gridLayout.addWidget(self.enableDtd, 0, 0, 1, 2)
        self.openLastFiles = QtWidgets.QCheckBox(self.groupBox)
        self.openLastFiles.setChecked(True)
        self.openLastFiles.setObjectName("openLastFiles")
        self.gridLayout.addWidget(self.openLastFiles, 2, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox)
        self.groupBox_2 = QtWidgets.QGroupBox(self.tab)
        self.groupBox_2.setObjectName("groupBox_2")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox_2)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.openGL = QtWidgets.QCheckBox(self.groupBox_2)
        self.openGL.setObjectName("openGL")
        self.gridLayout_2.addWidget(self.openGL, 5, 0, 1, 4)
        self.label_2 = QtWidgets.QLabel(self.groupBox_2)
        self.label_2.setObjectName("label_2")
        self.gridLayout_2.addWidget(self.label_2, 0, 0, 1, 1)
        self.label_3 = QtWidgets.QLabel(self.groupBox_2)
        self.label_3.setObjectName("label_3")
        self.gridLayout_2.addWidget(self.label_3, 2, 0, 1, 1)
        self.gridColor = ColorButton(self.groupBox_2)
        self.gridColor.setObjectName("gridColor")
        self.gridLayout_2.addWidget(self.gridColor, 2, 3, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(0, 20,
                                           QtWidgets.QSizePolicy.Expanding,
                                           QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_2.addItem(spacerItem, 0, 4, 1, 1)
        self.languageCombo = QtWidgets.QComboBox(self.groupBox_2)
        self.languageCombo.setObjectName("languageCombo")
        self.gridLayout_2.addWidget(self.languageCombo, 0, 3, 1, 1)
        self.label_4 = QtWidgets.QLabel(self.groupBox_2)
        self.label_4.setObjectName("label_4")
        self.gridLayout_2.addWidget(self.label_4, 3, 0, 1, 1)
        self.gridFine = QtWidgets.QSpinBox(self.groupBox_2)
        self.gridFine.setMinimum(1)
        self.gridFine.setMaximum(128)
        self.gridFine.setObjectName("gridFine")
        self.gridLayout_2.addWidget(self.gridFine, 3, 3, 1, 1)
        self.objectLineWidth = QtWidgets.QDoubleSpinBox(self.groupBox_2)
        self.objectLineWidth.setDecimals(1)
        self.objectLineWidth.setMinimum(1.0)
        self.objectLineWidth.setProperty("value", 2.0)
        self.objectLineWidth.setObjectName("objectLineWidth")
        self.gridLayout_2.addWidget(self.objectLineWidth, 4, 3, 1, 1)
        self.label = QtWidgets.QLabel(self.groupBox_2)
        self.label.setObjectName("label")
        self.gridLayout_2.addWidget(self.label, 4, 0, 1, 1)
        self.verticalLayout_2.addWidget(self.groupBox_2)
        spacerItem1 = QtWidgets.QSpacerItem(381, 1,
                                            QtWidgets.QSizePolicy.Minimum,
                                            QtWidgets.QSizePolicy.Expanding)
        self.verticalLayout_2.addItem(spacerItem1)
        self.tabWidget.addTab(self.tab, "")
        self.tab_2 = QtWidgets.QWidget()
        self.tab_2.setObjectName("tab_2")
        self.verticalLayout_3 = QtWidgets.QVBoxLayout(self.tab_2)
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.groupBox_3 = QtWidgets.QGroupBox(self.tab_2)
        self.groupBox_3.setObjectName("groupBox_3")
        self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.groupBox_3)
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.objectTypesTable = QtWidgets.QTableView(self.groupBox_3)
        self.objectTypesTable.setSelectionBehavior(
            QtWidgets.QAbstractItemView.SelectRows)
        self.objectTypesTable.setVerticalScrollMode(
            QtWidgets.QAbstractItemView.ScrollPerPixel)
        self.objectTypesTable.setWordWrap(False)
        self.objectTypesTable.setObjectName("objectTypesTable")
        self.objectTypesTable.horizontalHeader().setHighlightSections(False)
        self.objectTypesTable.verticalHeader().setVisible(False)
        self.objectTypesTable.verticalHeader().setHighlightSections(False)
        self.verticalLayout_4.addWidget(self.objectTypesTable)
        self.horizontalLayout = QtWidgets.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.addObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(":/images/22x22/add.png"),
                       QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.addObjectTypeButton.setIcon(icon)
        self.addObjectTypeButton.setAutoRaise(True)
        self.addObjectTypeButton.setObjectName("addObjectTypeButton")
        self.horizontalLayout.addWidget(self.addObjectTypeButton)
        self.removeObjectTypeButton = QtWidgets.QToolButton(self.groupBox_3)
        self.removeObjectTypeButton.setEnabled(False)
        icon1 = QtGui.QIcon()
        icon1.addPixmap(QtGui.QPixmap(":/images/22x22/remove.png"),
                        QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.removeObjectTypeButton.setIcon(icon1)
        self.removeObjectTypeButton.setAutoRaise(True)
        self.removeObjectTypeButton.setObjectName("removeObjectTypeButton")
        self.horizontalLayout.addWidget(self.removeObjectTypeButton)
        spacerItem2 = QtWidgets.QSpacerItem(40, 20,
                                            QtWidgets.QSizePolicy.Expanding,
                                            QtWidgets.QSizePolicy.Minimum)
        self.horizontalLayout.addItem(spacerItem2)
        self.importObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum,
                                           QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.importObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.importObjectTypesButton.setSizePolicy(sizePolicy)
        self.importObjectTypesButton.setObjectName("importObjectTypesButton")
        self.horizontalLayout.addWidget(self.importObjectTypesButton)
        self.exportObjectTypesButton = QtWidgets.QPushButton(self.groupBox_3)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed,
                                           QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.exportObjectTypesButton.sizePolicy().hasHeightForWidth())
        self.exportObjectTypesButton.setSizePolicy(sizePolicy)
        self.exportObjectTypesButton.setObjectName("exportObjectTypesButton")
        self.horizontalLayout.addWidget(self.exportObjectTypesButton)
        self.verticalLayout_4.addLayout(self.horizontalLayout)
        self.verticalLayout_3.addWidget(self.groupBox_3)
        self.tabWidget.addTab(self.tab_2, "")
        self.tab_3 = QtWidgets.QWidget()
        self.tab_3.setObjectName("tab_3")
        self.autoMapWhileDrawing = QtWidgets.QCheckBox(self.tab_3)
        self.autoMapWhileDrawing.setGeometry(QtCore.QRect(10, 20, 391, 22))
        self.autoMapWhileDrawing.setObjectName("autoMapWhileDrawing")
        self.tabWidget.addTab(self.tab_3, "")
        self.verticalLayout.addWidget(self.tabWidget)
        self.buttonBox = QtWidgets.QDialogButtonBox(PreferencesDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Close)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout.addWidget(self.buttonBox)
        self.label_2.setBuddy(self.languageCombo)
        self.label_3.setBuddy(self.gridColor)
        self.label_4.setBuddy(self.gridFine)
        self.label.setBuddy(self.objectLineWidth)

        self.retranslateUi(PreferencesDialog)
        self.tabWidget.setCurrentIndex(0)
        self.buttonBox.rejected.connect(PreferencesDialog.reject)
        QtCore.QMetaObject.connectSlotsByName(PreferencesDialog)
        PreferencesDialog.setTabOrder(self.tabWidget, self.enableDtd)
        PreferencesDialog.setTabOrder(self.enableDtd, self.reloadTilesetImages)
        PreferencesDialog.setTabOrder(self.reloadTilesetImages,
                                      self.languageCombo)
        PreferencesDialog.setTabOrder(self.languageCombo, self.gridColor)
        PreferencesDialog.setTabOrder(self.gridColor, self.gridFine)
        PreferencesDialog.setTabOrder(self.gridFine, self.objectLineWidth)
        PreferencesDialog.setTabOrder(self.objectLineWidth, self.openGL)
        PreferencesDialog.setTabOrder(self.openGL, self.buttonBox)
        PreferencesDialog.setTabOrder(self.buttonBox,
                                      self.importObjectTypesButton)
        PreferencesDialog.setTabOrder(self.importObjectTypesButton,
                                      self.exportObjectTypesButton)
        PreferencesDialog.setTabOrder(self.exportObjectTypesButton,
                                      self.autoMapWhileDrawing)
        PreferencesDialog.setTabOrder(self.autoMapWhileDrawing,
                                      self.removeObjectTypeButton)
        PreferencesDialog.setTabOrder(self.removeObjectTypeButton,
                                      self.addObjectTypeButton)
        PreferencesDialog.setTabOrder(self.addObjectTypeButton,
                                      self.objectTypesTable)

    def retranslateUi(self, PreferencesDialog):
        _translate = QtCore.QCoreApplication.translate
        PreferencesDialog.setWindowTitle(
            _translate("PreferencesDialog", "Preferences"))
        self.groupBox.setTitle(
            _translate("PreferencesDialog", "Saving and Loading"))
        self.reloadTilesetImages.setText(
            _translate("PreferencesDialog",
                       "&Reload tileset images when they change"))
        self.enableDtd.setToolTip(
            _translate(
                "PreferencesDialog",
                "Not enabled by default since a reference to an external DTD is known to cause problems with some XML parsers."
            ))
        self.enableDtd.setText(
            _translate("PreferencesDialog",
                       "Include &DTD reference in saved maps"))
        self.openLastFiles.setText(
            _translate("PreferencesDialog", "Open last files on startup"))
        self.groupBox_2.setTitle(_translate("PreferencesDialog", "Interface"))
        self.openGL.setText(
            _translate("PreferencesDialog",
                       "Hardware &accelerated drawing (OpenGL)"))
        self.label_2.setText(_translate("PreferencesDialog", "&Language:"))
        self.label_3.setText(_translate("PreferencesDialog", "Grid color:"))
        self.label_4.setText(
            _translate("PreferencesDialog", "Fine grid divisions:"))
        self.objectLineWidth.setSuffix(
            _translate("PreferencesDialog", " pixels"))
        self.label.setText(
            _translate("PreferencesDialog", "Object line width:"))
        self.tabWidget.setTabText(self.tabWidget.indexOf(self.tab),
                                  _translate("PreferencesDialog", "General"))
        self.groupBox_3.setTitle(
            _translate("PreferencesDialog", "Object Types"))
        self.addObjectTypeButton.setToolTip(
            _translate("PreferencesDialog", "Add Object Type"))
        self.addObjectTypeButton.setText(_translate("PreferencesDialog",
                                                    "Add"))
        self.removeObjectTypeButton.setToolTip(
            _translate("PreferencesDialog", "Remove Selected Object Types"))
        self.removeObjectTypeButton.setText(
            _translate("PreferencesDialog", "Remove"))
        self.importObjectTypesButton.setText(
            _translate("PreferencesDialog", "Import..."))
        self.exportObjectTypesButton.setText(
            _translate("PreferencesDialog", "Export..."))
        self.tabWidget.setTabText(
            self.tabWidget.indexOf(self.tab_2),
            _translate("PreferencesDialog", "Object Types"))
        self.autoMapWhileDrawing.setText(
            _translate("PreferencesDialog",
                       "Use Automapping, when drawing into layers"))
        self.tabWidget.setTabText(
            self.tabWidget.indexOf(self.tab_3),
            _translate("PreferencesDialog", "Automapping"))
    def setupUi(self, NewTilesetDialog):
        NewTilesetDialog.setObjectName("NewTilesetDialog")
        NewTilesetDialog.resize(387, 314)
        self.verticalLayout = QtWidgets.QVBoxLayout(NewTilesetDialog)
        self.verticalLayout.setSizeConstraint(QtWidgets.QLayout.SetMinAndMaxSize)
        self.verticalLayout.setObjectName("verticalLayout")
        self.tilesetGroupBox = QtWidgets.QGroupBox(NewTilesetDialog)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.tilesetGroupBox.sizePolicy().hasHeightForWidth())
        self.tilesetGroupBox.setSizePolicy(sizePolicy)
        self.tilesetGroupBox.setObjectName("tilesetGroupBox")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.tilesetGroupBox)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.tilesetType = QtWidgets.QComboBox(self.tilesetGroupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.tilesetType.sizePolicy().hasHeightForWidth())
        self.tilesetType.setSizePolicy(sizePolicy)
        self.tilesetType.setObjectName("tilesetType")
        self.tilesetType.addItem("")
        self.tilesetType.addItem("")
        self.gridLayout_2.addWidget(self.tilesetType, 1, 1, 1, 1)
        self.typeLabel = QtWidgets.QLabel(self.tilesetGroupBox)
        self.typeLabel.setObjectName("typeLabel")
        self.gridLayout_2.addWidget(self.typeLabel, 1, 0, 1, 1)
        self.nameLabel = QtWidgets.QLabel(self.tilesetGroupBox)
        self.nameLabel.setObjectName("nameLabel")
        self.gridLayout_2.addWidget(self.nameLabel, 0, 0, 1, 1)
        self.name = QtWidgets.QLineEdit(self.tilesetGroupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.name.sizePolicy().hasHeightForWidth())
        self.name.setSizePolicy(sizePolicy)
        self.name.setObjectName("name")
        self.gridLayout_2.addWidget(self.name, 0, 1, 1, 1)
        self.verticalLayout.addWidget(self.tilesetGroupBox)
        self.imageGroupBox = QtWidgets.QGroupBox(NewTilesetDialog)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.imageGroupBox.sizePolicy().hasHeightForWidth())
        self.imageGroupBox.setSizePolicy(sizePolicy)
        self.imageGroupBox.setCheckable(False)
        self.imageGroupBox.setObjectName("imageGroupBox")
        self.gridLayout = QtWidgets.QGridLayout(self.imageGroupBox)
        self.gridLayout.setObjectName("gridLayout")
        self.sourceLabel = QtWidgets.QLabel(self.imageGroupBox)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.sourceLabel.sizePolicy().hasHeightForWidth())
        self.sourceLabel.setSizePolicy(sizePolicy)
        self.sourceLabel.setObjectName("sourceLabel")
        self.gridLayout.addWidget(self.sourceLabel, 0, 0, 1, 1)
        self.browseButton = QtWidgets.QPushButton(self.imageGroupBox)
        self.browseButton.setObjectName("browseButton")
        self.gridLayout.addWidget(self.browseButton, 0, 4, 1, 1)
        self.useTransparentColor = QtWidgets.QCheckBox(self.imageGroupBox)
        self.useTransparentColor.setObjectName("useTransparentColor")
        self.gridLayout.addWidget(self.useTransparentColor, 1, 0, 1, 2)
        self.colorButton = ColorButton(self.imageGroupBox)
        self.colorButton.setEnabled(False)
        self.colorButton.setObjectName("colorButton")
        self.gridLayout.addWidget(self.colorButton, 1, 2, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(0, 13, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.gridLayout.addItem(spacerItem, 1, 3, 1, 1)
        self.gridLayout_3 = QtWidgets.QGridLayout()
        self.gridLayout_3.setObjectName("gridLayout_3")
        self.tileHeight = QtWidgets.QSpinBox(self.imageGroupBox)
        self.tileHeight.setMinimum(1)
        self.tileHeight.setMaximum(9999)
        self.tileHeight.setProperty("value", 32)
        self.tileHeight.setObjectName("tileHeight")
        self.gridLayout_3.addWidget(self.tileHeight, 1, 1, 1, 1)
        self.tileHeightLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.tileHeightLabel.setObjectName("tileHeightLabel")
        self.gridLayout_3.addWidget(self.tileHeightLabel, 1, 0, 1, 1)
        spacerItem1 = QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_3.addItem(spacerItem1, 1, 2, 1, 1)
        self.tileWidth = QtWidgets.QSpinBox(self.imageGroupBox)
        self.tileWidth.setEnabled(True)
        self.tileWidth.setMinimum(1)
        self.tileWidth.setMaximum(9999)
        self.tileWidth.setProperty("value", 32)
        self.tileWidth.setObjectName("tileWidth")
        self.gridLayout_3.addWidget(self.tileWidth, 0, 1, 1, 1)
        self.marginLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.marginLabel.setObjectName("marginLabel")
        self.gridLayout_3.addWidget(self.marginLabel, 0, 3, 1, 1)
        self.margin = QtWidgets.QSpinBox(self.imageGroupBox)
        self.margin.setMinimum(0)
        self.margin.setMaximum(9999)
        self.margin.setProperty("value", 0)
        self.margin.setObjectName("margin")
        self.gridLayout_3.addWidget(self.margin, 0, 4, 1, 1)
        self.spacing = QtWidgets.QSpinBox(self.imageGroupBox)
        self.spacing.setMinimum(0)
        self.spacing.setMaximum(9999)
        self.spacing.setProperty("value", 0)
        self.spacing.setObjectName("spacing")
        self.gridLayout_3.addWidget(self.spacing, 1, 4, 1, 1)
        self.tileWidthLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.tileWidthLabel.setObjectName("tileWidthLabel")
        self.gridLayout_3.addWidget(self.tileWidthLabel, 0, 0, 1, 1)
        self.spacingLabel = QtWidgets.QLabel(self.imageGroupBox)
        self.spacingLabel.setObjectName("spacingLabel")
        self.gridLayout_3.addWidget(self.spacingLabel, 1, 3, 1, 1)
        spacerItem2 = QtWidgets.QSpacerItem(0, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)
        self.gridLayout_3.addItem(spacerItem2, 1, 5, 1, 1)
        self.gridLayout.addLayout(self.gridLayout_3, 2, 0, 1, 5)
        self.image = QtWidgets.QLineEdit(self.imageGroupBox)
        self.image.setObjectName("image")
        self.gridLayout.addWidget(self.image, 0, 1, 1, 3)
        self.verticalLayout.addWidget(self.imageGroupBox)
        self.buttonBox = QtWidgets.QDialogButtonBox(NewTilesetDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel|QtWidgets.QDialogButtonBox.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.verticalLayout.addWidget(self.buttonBox)
        self.nameLabel.setBuddy(self.name)

        self.retranslateUi(NewTilesetDialog)
        self.buttonBox.accepted.connect(NewTilesetDialog.tryAccept)
        self.buttonBox.rejected.connect(NewTilesetDialog.reject)
        self.useTransparentColor.toggled['bool'].connect(self.colorButton.setEnabled)
        QtCore.QMetaObject.connectSlotsByName(NewTilesetDialog)
        NewTilesetDialog.setTabOrder(self.name, self.tilesetType)
        NewTilesetDialog.setTabOrder(self.tilesetType, self.image)
        NewTilesetDialog.setTabOrder(self.image, self.browseButton)
        NewTilesetDialog.setTabOrder(self.browseButton, self.useTransparentColor)
        NewTilesetDialog.setTabOrder(self.useTransparentColor, self.colorButton)
        NewTilesetDialog.setTabOrder(self.colorButton, self.tileWidth)
        NewTilesetDialog.setTabOrder(self.tileWidth, self.tileHeight)
        NewTilesetDialog.setTabOrder(self.tileHeight, self.margin)
        NewTilesetDialog.setTabOrder(self.margin, self.spacing)
        NewTilesetDialog.setTabOrder(self.spacing, self.buttonBox)