当前位置: 首页>>代码示例>>Python>>正文


Python QgsColorButton.setText方法代码示例

本文整理汇总了Python中qgis.gui.QgsColorButton.setText方法的典型用法代码示例。如果您正苦于以下问题:Python QgsColorButton.setText方法的具体用法?Python QgsColorButton.setText怎么用?Python QgsColorButton.setText使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在qgis.gui.QgsColorButton的用法示例。


在下文中一共展示了QgsColorButton.setText方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: Ui_VectorScaleBoxOptionsDialog

# 需要导入模块: from qgis.gui import QgsColorButton [as 别名]
# 或者: from qgis.gui.QgsColorButton import setText [as 别名]
class Ui_VectorScaleBoxOptionsDialog(object):
    def setupUi(self, VectorScaleBoxOptionsDialog):
        VectorScaleBoxOptionsDialog.setObjectName(_fromUtf8("VectorScaleBoxOptionsDialog"))
        VectorScaleBoxOptionsDialog.resize(399, 274)
        self.uMainLayout = QtGui.QVBoxLayout(VectorScaleBoxOptionsDialog)
        self.uMainLayout.setObjectName(_fromUtf8("uMainLayout"))
        self.uLocationGroup = QtGui.QGroupBox(VectorScaleBoxOptionsDialog)
        self.uLocationGroup.setObjectName(_fromUtf8("uLocationGroup"))
        self.verticalLayout_2 = QtGui.QVBoxLayout(self.uLocationGroup)
        self.verticalLayout_2.setObjectName(_fromUtf8("verticalLayout_2"))
        self.uLocationLayout = QtGui.QVBoxLayout()
        self.uLocationLayout.setObjectName(_fromUtf8("uLocationLayout"))
        self.uPositionLayout_2 = QtGui.QHBoxLayout()
        self.uPositionLayout_2.setObjectName(_fromUtf8("uPositionLayout_2"))
        self.uPositionLabel = QtGui.QLabel(self.uLocationGroup)
        self.uPositionLabel.setObjectName(_fromUtf8("uPositionLabel"))
        self.uPositionLayout_2.addWidget(self.uPositionLabel)
        self.uRadioTL = QtGui.QRadioButton(self.uLocationGroup)
        self.uRadioTL.setObjectName(_fromUtf8("uRadioTL"))
        self.uPositionLayout_2.addWidget(self.uRadioTL)
        self.uRadioTR = QtGui.QRadioButton(self.uLocationGroup)
        self.uRadioTR.setObjectName(_fromUtf8("uRadioTR"))
        self.uPositionLayout_2.addWidget(self.uRadioTR)
        self.uRadioBL = QtGui.QRadioButton(self.uLocationGroup)
        self.uRadioBL.setObjectName(_fromUtf8("uRadioBL"))
        self.uPositionLayout_2.addWidget(self.uRadioBL)
        self.uRadioBR = QtGui.QRadioButton(self.uLocationGroup)
        self.uRadioBR.setChecked(True)
        self.uRadioBR.setObjectName(_fromUtf8("uRadioBR"))
        self.uPositionLayout_2.addWidget(self.uRadioBR)
        spacerItem = QtGui.QSpacerItem(40, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
        self.uPositionLayout_2.addItem(spacerItem)
        self.uLocationLayout.addLayout(self.uPositionLayout_2)
        self.verticalLayout_2.addLayout(self.uLocationLayout)
        self.uPositionLayout = QtGui.QHBoxLayout()
        self.uPositionLayout.setObjectName(_fromUtf8("uPositionLayout"))
        self.uOffsetXLabel = QtGui.QLabel(self.uLocationGroup)
        self.uOffsetXLabel.setObjectName(_fromUtf8("uOffsetXLabel"))
        self.uPositionLayout.addWidget(self.uOffsetXLabel)
        self.uOffsetX = QtGui.QSpinBox(self.uLocationGroup)
        self.uOffsetX.setMaximum(300)
        self.uOffsetX.setObjectName(_fromUtf8("uOffsetX"))
        self.uPositionLayout.addWidget(self.uOffsetX)
        self.uOffsetYLabel = QtGui.QLabel(self.uLocationGroup)
        self.uOffsetYLabel.setObjectName(_fromUtf8("uOffsetYLabel"))
        self.uPositionLayout.addWidget(self.uOffsetYLabel)
        self.uOffsetY = QtGui.QSpinBox(self.uLocationGroup)
        self.uOffsetY.setMaximum(300)
        self.uOffsetY.setObjectName(_fromUtf8("uOffsetY"))
        self.uPositionLayout.addWidget(self.uOffsetY)
        self.uArrowSizeLabel = QtGui.QLabel(self.uLocationGroup)
        self.uArrowSizeLabel.setObjectName(_fromUtf8("uArrowSizeLabel"))
        self.uPositionLayout.addWidget(self.uArrowSizeLabel)
        self.uArrowSizePercent = QtGui.QSpinBox(self.uLocationGroup)
        self.uArrowSizePercent.setMaximum(30)
        self.uArrowSizePercent.setObjectName(_fromUtf8("uArrowSizePercent"))
        self.uPositionLayout.addWidget(self.uArrowSizePercent)
        spacerItem1 = QtGui.QSpacerItem(40, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
        self.uPositionLayout.addItem(spacerItem1)
        self.verticalLayout_2.addLayout(self.uPositionLayout)
        self.uMainLayout.addWidget(self.uLocationGroup)
        self.uBoxGroup = QtGui.QGroupBox(VectorScaleBoxOptionsDialog)
        self.uBoxGroup.setObjectName(_fromUtf8("uBoxGroup"))
        self.horizontalLayout_6 = QtGui.QHBoxLayout(self.uBoxGroup)
        self.horizontalLayout_6.setObjectName(_fromUtf8("horizontalLayout_6"))
        self.uShowBoxLabel = QtGui.QLabel(self.uBoxGroup)
        self.uShowBoxLabel.setObjectName(_fromUtf8("uShowBoxLabel"))
        self.horizontalLayout_6.addWidget(self.uShowBoxLabel)
        self.uShowBox = QtGui.QCheckBox(self.uBoxGroup)
        self.uShowBox.setText(_fromUtf8(""))
        self.uShowBox.setObjectName(_fromUtf8("uShowBox"))
        self.horizontalLayout_6.addWidget(self.uShowBox)
        self.uFillBoxLabel = QtGui.QLabel(self.uBoxGroup)
        self.uFillBoxLabel.setObjectName(_fromUtf8("uFillBoxLabel"))
        self.horizontalLayout_6.addWidget(self.uFillBoxLabel)
        self.uFillBox = QtGui.QCheckBox(self.uBoxGroup)
        self.uFillBox.setText(_fromUtf8(""))
        self.uFillBox.setObjectName(_fromUtf8("uFillBox"))
        self.horizontalLayout_6.addWidget(self.uFillBox)
        spacerItem2 = QtGui.QSpacerItem(40, 20, QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Minimum)
        self.horizontalLayout_6.addItem(spacerItem2)
        self.uPenColor = QgsColorButton(self.uBoxGroup)
        self.uPenColor.setObjectName(_fromUtf8("uPenColor"))
        self.horizontalLayout_6.addWidget(self.uPenColor)
        self.uBrushColor = QgsColorButton(self.uBoxGroup)
        self.uBrushColor.setObjectName(_fromUtf8("uBrushColor"))
        self.horizontalLayout_6.addWidget(self.uBrushColor)
        self.uMainLayout.addWidget(self.uBoxGroup)
        self.uTextGroup = QtGui.QGroupBox(VectorScaleBoxOptionsDialog)
        self.uTextGroup.setObjectName(_fromUtf8("uTextGroup"))
        self.horizontalLayout_3 = QtGui.QHBoxLayout(self.uTextGroup)
        self.horizontalLayout_3.setObjectName(_fromUtf8("horizontalLayout_3"))
        self.uTitleLabel = QtGui.QLabel(self.uTextGroup)
        self.uTitleLabel.setObjectName(_fromUtf8("uTitleLabel"))
        self.horizontalLayout_3.addWidget(self.uTitleLabel)
        self.uTitle = QtGui.QLineEdit(self.uTextGroup)
        self.uTitle.setObjectName(_fromUtf8("uTitle"))
        self.horizontalLayout_3.addWidget(self.uTitle)
        self.uTitleFont = QtGui.QPushButton(self.uTextGroup)
        self.uTitleFont.setObjectName(_fromUtf8("uTitleFont"))
#.........这里部分代码省略.........
开发者ID:ccrook,项目名称:QGIS-VectorFieldRenderer-Plugin,代码行数:103,代码来源:Ui_VectorScaleBoxOptionsDialog.py

示例2: Ui_frmRptTitleBase

# 需要导入模块: from qgis.gui import QgsColorButton [as 别名]
# 或者: from qgis.gui.QgsColorButton import setText [as 别名]
class Ui_frmRptTitleBase(object):
    def setupUi(self, frmRptTitleBase):
        frmRptTitleBase.setObjectName(_fromUtf8("frmRptTitleBase"))
        frmRptTitleBase.resize(347, 495)
        self.gridLayout = QtGui.QGridLayout(frmRptTitleBase)
        self.gridLayout.setObjectName(_fromUtf8("gridLayout"))
        self.scrollArea = QtGui.QScrollArea(frmRptTitleBase)
        self.scrollArea.setWidgetResizable(True)
        self.scrollArea.setObjectName(_fromUtf8("scrollArea"))
        self.scrollAreaWidgetContents = QtGui.QWidget(self.scrollArea)
        self.scrollAreaWidgetContents.setGeometry(QtCore.QRect(0, 0, 327, 475))
        self.scrollAreaWidgetContents.setObjectName(_fromUtf8("scrollAreaWidgetContents"))
        self.verticalLayout = QtGui.QVBoxLayout(self.scrollAreaWidgetContents)
        self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
        self.label_10 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_10.setObjectName(_fromUtf8("label_10"))
        self.verticalLayout.addWidget(self.label_10)
        self.cboBorder = QtGui.QComboBox(self.scrollAreaWidgetContents)
        self.cboBorder.setObjectName(_fromUtf8("cboBorder"))
        self.cboBorder.addItem(_fromUtf8(""))
        self.cboBorder.addItem(_fromUtf8(""))
        self.cboBorder.addItem(_fromUtf8(""))
        self.cboBorder.addItem(_fromUtf8(""))
        self.cboBorder.addItem(_fromUtf8(""))
        self.cboBorder.addItem(_fromUtf8(""))
        self.verticalLayout.addWidget(self.cboBorder)
        self.label = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label.setObjectName(_fromUtf8("label"))
        self.verticalLayout.addWidget(self.label)
        self.btnTitleColor = QgsColorButton(self.scrollAreaWidgetContents)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.btnTitleColor.sizePolicy().hasHeightForWidth())
        self.btnTitleColor.setSizePolicy(sizePolicy)
        self.btnTitleColor.setMinimumSize(QtCore.QSize(32, 0))
        self.btnTitleColor.setMaximumSize(QtCore.QSize(1000, 16777215))
        self.btnTitleColor.setText(_fromUtf8(""))
        self.btnTitleColor.setObjectName(_fromUtf8("btnTitleColor"))
        self.verticalLayout.addWidget(self.btnTitleColor)
        self.label_2 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_2.setObjectName(_fromUtf8("label_2"))
        self.verticalLayout.addWidget(self.label_2)
        self.btnTitleFont = QtGui.QPushButton(self.scrollAreaWidgetContents)
        self.btnTitleFont.setObjectName(_fromUtf8("btnTitleFont"))
        self.verticalLayout.addWidget(self.btnTitleFont)
        self.label_3 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_3.setObjectName(_fromUtf8("label_3"))
        self.verticalLayout.addWidget(self.label_3)
        self.txtTitleHeight = QtGui.QLineEdit(self.scrollAreaWidgetContents)
        self.txtTitleHeight.setObjectName(_fromUtf8("txtTitleHeight"))
        self.verticalLayout.addWidget(self.txtTitleHeight)
        self.label_4 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_4.setObjectName(_fromUtf8("label_4"))
        self.verticalLayout.addWidget(self.label_4)
        self.cboTitleHAlign = QtGui.QComboBox(self.scrollAreaWidgetContents)
        self.cboTitleHAlign.setObjectName(_fromUtf8("cboTitleHAlign"))
        self.cboTitleHAlign.addItem(_fromUtf8(""))
        self.cboTitleHAlign.addItem(_fromUtf8(""))
        self.cboTitleHAlign.addItem(_fromUtf8(""))
        self.verticalLayout.addWidget(self.cboTitleHAlign)
        self.label_5 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_5.setObjectName(_fromUtf8("label_5"))
        self.verticalLayout.addWidget(self.label_5)
        self.txtTitleLeft = QtGui.QLineEdit(self.scrollAreaWidgetContents)
        self.txtTitleLeft.setObjectName(_fromUtf8("txtTitleLeft"))
        self.verticalLayout.addWidget(self.txtTitleLeft)
        self.label_6 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_6.setObjectName(_fromUtf8("label_6"))
        self.verticalLayout.addWidget(self.label_6)
        self.txtTitleText = QtGui.QLineEdit(self.scrollAreaWidgetContents)
        self.txtTitleText.setObjectName(_fromUtf8("txtTitleText"))
        self.verticalLayout.addWidget(self.txtTitleText)
        self.label_7 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_7.setObjectName(_fromUtf8("label_7"))
        self.verticalLayout.addWidget(self.label_7)
        self.txtTitleTop = QtGui.QLineEdit(self.scrollAreaWidgetContents)
        self.txtTitleTop.setObjectName(_fromUtf8("txtTitleTop"))
        self.verticalLayout.addWidget(self.txtTitleTop)
        self.label_8 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_8.setObjectName(_fromUtf8("label_8"))
        self.verticalLayout.addWidget(self.label_8)
        self.cboTitleVAlign = QtGui.QComboBox(self.scrollAreaWidgetContents)
        self.cboTitleVAlign.setObjectName(_fromUtf8("cboTitleVAlign"))
        self.cboTitleVAlign.addItem(_fromUtf8(""))
        self.cboTitleVAlign.addItem(_fromUtf8(""))
        self.cboTitleVAlign.addItem(_fromUtf8(""))
        self.verticalLayout.addWidget(self.cboTitleVAlign)
        self.label_9 = QtGui.QLabel(self.scrollAreaWidgetContents)
        self.label_9.setObjectName(_fromUtf8("label_9"))
        self.verticalLayout.addWidget(self.label_9)
        self.txtTitleWidth = QtGui.QLineEdit(self.scrollAreaWidgetContents)
        self.txtTitleWidth.setObjectName(_fromUtf8("txtTitleWidth"))
        self.verticalLayout.addWidget(self.txtTitleWidth)
        self.scrollArea.setWidget(self.scrollAreaWidgetContents)
        self.gridLayout.addWidget(self.scrollArea, 0, 0, 1, 1)

        self.retranslateUi(frmRptTitleBase)
        QtCore.QMetaObject.connectSlotsByName(frmRptTitleBase)

#.........这里部分代码省略.........
开发者ID:7o9,项目名称:stdm-plugin,代码行数:103,代码来源:ui_rpt_title_base.py

示例3: Ui_AnimationLayoutItemProps

# 需要导入模块: from qgis.gui import QgsColorButton [as 别名]
# 或者: from qgis.gui.QgsColorButton import setText [as 别名]
class Ui_AnimationLayoutItemProps(object):
    def setupUi(self, AnimationLayoutItemProps):
        AnimationLayoutItemProps.setObjectName(_fromUtf8("AnimationLayoutItemProps"))
        AnimationLayoutItemProps.resize(475, 175)
        self.formLayout = QtGui.QFormLayout(AnimationLayoutItemProps)
        self.formLayout.setObjectName(_fromUtf8("formLayout"))
        self.lblLabel = QtGui.QLabel(AnimationLayoutItemProps)
        self.lblLabel.setObjectName(_fromUtf8("lblLabel"))
        self.formLayout.setWidget(0, QtGui.QFormLayout.LabelRole, self.lblLabel)
        self.editLabel = QtGui.QLineEdit(AnimationLayoutItemProps)
        self.editLabel.setObjectName(_fromUtf8("editLabel"))
        self.formLayout.setWidget(0, QtGui.QFormLayout.FieldRole, self.editLabel)
        self.lblTimeFormat = QtGui.QLabel(AnimationLayoutItemProps)
        self.lblTimeFormat.setObjectName(_fromUtf8("lblTimeFormat"))
        self.formLayout.setWidget(1, QtGui.QFormLayout.LabelRole, self.lblTimeFormat)
        self.cboTimeFormat = QtGui.QComboBox(AnimationLayoutItemProps)
        self.cboTimeFormat.setObjectName(_fromUtf8("cboTimeFormat"))
        self.cboTimeFormat.addItem(_fromUtf8(""))
        self.cboTimeFormat.addItem(_fromUtf8(""))
        self.formLayout.setWidget(1, QtGui.QFormLayout.FieldRole, self.cboTimeFormat)
        self.lblText = QtGui.QLabel(AnimationLayoutItemProps)
        self.lblText.setObjectName(_fromUtf8("lblText"))
        self.formLayout.setWidget(2, QtGui.QFormLayout.LabelRole, self.lblText)
        self.horizontalLayout = QtGui.QHBoxLayout()
        self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout"))
        self.btnFont = QtGui.QPushButton(AnimationLayoutItemProps)
        self.btnFont.setObjectName(_fromUtf8("btnFont"))
        self.horizontalLayout.addWidget(self.btnFont)
        self.btnTextColor = QgsColorButton(AnimationLayoutItemProps)
        self.btnTextColor.setText(_fromUtf8(""))
        self.btnTextColor.setObjectName(_fromUtf8("btnTextColor"))
        self.horizontalLayout.addWidget(self.btnTextColor)
        self.formLayout.setLayout(2, QtGui.QFormLayout.FieldRole, self.horizontalLayout)
        self.lblBackground = QtGui.QLabel(AnimationLayoutItemProps)
        self.lblBackground.setObjectName(_fromUtf8("lblBackground"))
        self.formLayout.setWidget(3, QtGui.QFormLayout.LabelRole, self.lblBackground)
        self.horizontalLayout_2 = QtGui.QHBoxLayout()
        self.horizontalLayout_2.setObjectName(_fromUtf8("horizontalLayout_2"))
        self.chkBackground = QtGui.QCheckBox(AnimationLayoutItemProps)
        self.chkBackground.setText(_fromUtf8(""))
        self.chkBackground.setObjectName(_fromUtf8("chkBackground"))
        self.horizontalLayout_2.addWidget(self.chkBackground)
        self.btnBackgroundColor = QgsColorButton(AnimationLayoutItemProps)
        self.btnBackgroundColor.setText(_fromUtf8(""))
        self.btnBackgroundColor.setObjectName(_fromUtf8("btnBackgroundColor"))
        self.horizontalLayout_2.addWidget(self.btnBackgroundColor)
        self.formLayout.setLayout(3, QtGui.QFormLayout.FieldRole, self.horizontalLayout_2)
        self.lblPosition = QtGui.QLabel(AnimationLayoutItemProps)
        self.lblPosition.setObjectName(_fromUtf8("lblPosition"))
        self.formLayout.setWidget(4, QtGui.QFormLayout.LabelRole, self.lblPosition)
        self.cboPosition = QtGui.QComboBox(AnimationLayoutItemProps)
        self.cboPosition.setObjectName(_fromUtf8("cboPosition"))
        self.cboPosition.addItem(_fromUtf8(""))
        self.cboPosition.addItem(_fromUtf8(""))
        self.cboPosition.addItem(_fromUtf8(""))
        self.cboPosition.addItem(_fromUtf8(""))
        self.formLayout.setWidget(4, QtGui.QFormLayout.FieldRole, self.cboPosition)

        self.retranslateUi(AnimationLayoutItemProps)
        QtCore.QMetaObject.connectSlotsByName(AnimationLayoutItemProps)
        AnimationLayoutItemProps.setTabOrder(self.editLabel, self.cboTimeFormat)
        AnimationLayoutItemProps.setTabOrder(self.cboTimeFormat, self.btnBackgroundColor)
        AnimationLayoutItemProps.setTabOrder(self.btnBackgroundColor, self.cboPosition)

    def retranslateUi(self, AnimationLayoutItemProps):
        AnimationLayoutItemProps.setWindowTitle(_translate("AnimationLayoutItemProps", "Form", None))
        self.lblLabel.setText(_translate("AnimationLayoutItemProps", "Label", None))
        self.lblTimeFormat.setText(_translate("AnimationLayoutItemProps", "Format", None))
        self.cboTimeFormat.setItemText(0, _translate("AnimationLayoutItemProps", "hh:mm:ss.ss", None))
        self.cboTimeFormat.setItemText(1, _translate("AnimationLayoutItemProps", "hh.hhh", None))
        self.lblText.setText(_translate("AnimationLayoutItemProps", "Text", None))
        self.btnFont.setText(_translate("AnimationLayoutItemProps", "Font...", None))
        self.lblBackground.setText(_translate("AnimationLayoutItemProps", "Background", None))
        self.lblPosition.setText(_translate("AnimationLayoutItemProps", "Position", None))
        self.cboPosition.setItemText(0, _translate("AnimationLayoutItemProps", "Top-left", None))
        self.cboPosition.setItemText(1, _translate("AnimationLayoutItemProps", "Top-right", None))
        self.cboPosition.setItemText(2, _translate("AnimationLayoutItemProps", "Bottom-left", None))
        self.cboPosition.setItemText(3, _translate("AnimationLayoutItemProps", "Bottom-right", None))
开发者ID:kkremitzki,项目名称:qgis-crayfish-plugin,代码行数:80,代码来源:crayfish_animation_layout_item_props_ui.py


注:本文中的qgis.gui.QgsColorButton.setText方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。