<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                # QDesignerPropertyEditorInterface Class Reference ## [[QtDesigner](index.htm) module] 該QDesignerPropertyEditorInterface類允許你查詢和操作的Qt設計器的屬性編輯器的當前狀態。[More...](#details) 繼承[QWidget](qwidget.html)。 ### Methods * `__init__ (self, QWidget?parent, Qt.WindowFlags?flags?=?0)` * `QDesignerFormEditorInterface core (self)` * `QString currentPropertyName (self)` * `bool isReadOnly (self)` * `QObject object (self)` * `setObject (self, QObject?object)` * `setPropertyValue (self, QString?name, QVariant?value, bool?changed?=?True)` * `setReadOnly (self, bool?readOnly)` ### Qt Signals * `void propertyChanged (const QString&,const QVariant&)` * * * ## Detailed Description 該QDesignerPropertyEditorInterface類允許你查詢和操作的Qt設計器的屬性編輯器的當前狀態。 QDesignerPropertyEditorInterface包含了通常用于查詢的屬性編輯器,其當前狀態的功能,和幾個插槽集合操縱它的狀態。該接口還提供了一個信號,[propertyChanged](qdesignerpropertyeditorinterface.html#propertyChanged)( ) ,這是發射時在屬性編輯器中的屬性更改。該信號的參數是已更改的屬性及其新值。 例如,實現一個自定義的widget插件時,你可以將信號連接到一個自定義的槽: ``` QDesignerPropertyEditorInterface *propertyEditor = 0; propertyEditor = formEditor->propertyEditor(); connect(propertyEditor, SIGNAL(propertyChanged([QString](qstring.html), [QVariant](qvariant.html))), this, SLOT(checkProperty([QString](qstring.html), [QVariant](qvariant.html)))); ``` 此外,定制的插槽可以檢查新值,我們希望在一個指定的屬性,屬于特定窗口小部件,改變的范圍之內: ``` void checkProperty([QString](qstring.html) property, [QVariant](qvariant.html) value) { QDesignerPropertyEditorInterface *propertyEditor = 0; propertyEditor = formEditor->propertyEditor(); [QObject](qobject.html) *object = propertyeditor->object(); MyCustomWidget *widget = qobject_cast<MyCustomWidget>(object); if (widget && property == aProperty && value != expectedValue) {...} } ``` 該QDesignerPropertyEditorInterface類不適合直接實例化。你可以檢索界面_Qt Designer_使用的屬性編輯器[QDesignerFormEditorInterface.propertyEditor](qdesignerformeditorinterface.html#propertyEditor)()函數。一個指向_Qt Designer_目前的[QDesignerFormEditorInterface](qdesignerformeditorinterface.html)對象(`formEditor`在上面的例子)是由提供[QDesignerCustomWidgetInterface.initialize](qdesignercustomwidgetinterface.html#initialize)( )函數的參數。當實現一個自定義的widget插件,你必須在子類[QDesignerCustomWidgetInterface](qdesignercustomwidgetinterface.html)暴露你的插件_Qt Designer_。 訪問屬性編輯器的功能是[core](qdesignerpropertyeditorinterface.html#core)( )函數,你可以使用它來檢索一個接口,表單編輯器中,[currentPropertyName](qdesignerpropertyeditorinterface.html#currentPropertyName)( )函數,返回的屬性編輯器中當前所選屬性的名稱時,[object](qdesignerpropertyeditorinterface.html#object)( )函數,返回當前選定的對象_Qt Designer_的工作空間,以及[isReadOnly](qdesignerpropertyeditorinterface.html#isReadOnly)( )函數,如果屬性編輯器是寫proteced返回True (否則返回False ) 。 操縱屬性編輯器的狀態的槽的[setObject](qdesignerpropertyeditorinterface.html#setObject)()槽,你可以用它來改變當前選定的對象_Qt Designer_的工作區時,[setPropertyValue](qdesignerpropertyeditorinterface.html#setPropertyValue)()槽,改變一個給定屬性的值和[setReadOnly](qdesignerpropertyeditorinterface.html#setReadOnly)()槽控制的屬性編輯器的寫保護。 * * * ## Method Documentation ``` QDesignerPropertyEditorInterface.__init__ (self, QWidget?parent, Qt.WindowFlags?flags?=?0) ``` 該_parent_的說法,如果不是沒有,原因_self_通過Qt的,而不是PyQt的擁有。 構造一個屬性編輯器界面與給定_parent_和在指定的窗口_flags_。 ``` QDesignerFormEditorInterface QDesignerPropertyEditorInterface.core (self) ``` [](qdesignerformeditorinterface.html) [返回一個指針_Qt Designer_目前的](qdesignerformeditorinterface.html)[QDesignerFormEditorInterface](qdesignerformeditorinterface.html)對象。 ``` QString QDesignerPropertyEditorInterface.currentPropertyName (self) ``` 這種方法是抽象的,應在任何子類中重新實現。 返回在屬性編輯器中當前所選屬性的名稱。 **See also** [setPropertyValue](qdesignerpropertyeditorinterface.html#setPropertyValue)( ) 。 ``` bool QDesignerPropertyEditorInterface.isReadOnly (self) ``` 這種方法是抽象的,應在任何子類中重新實現。 返回True,如果屬性編輯器處于寫保護狀態,否則為False 。 **See also** [setReadOnly](qdesignerpropertyeditorinterface.html#setReadOnly)( ) 。 ``` QObject QDesignerPropertyEditorInterface.object (self) ``` [ 這種方法是抽象的,應在任何子類中重新實現。 返回當前選定的對象_Qt Designer_的工作空間。 ](qobject.html) [**See also**](qobject.html) [setObject](qdesignerpropertyeditorinterface.html#setObject)( ) 。 ``` QDesignerPropertyEditorInterface.setObject (self, QObject?object) ``` 這種方法也是一個Qt槽與C + +的簽名`void setObject(QObject *)`。 這種方法是抽象的,應在任何子類中重新實現。 在更改當前選定的對象_Qt Designer_的工作空間,以_object_。 **See also** [object](qdesignerpropertyeditorinterface.html#object)( ) 。 ``` QDesignerPropertyEditorInterface.setPropertyValue (self, QString?name, QVariant?value, bool?changed?=?True) ``` 這種方法也是一個Qt槽與C + +的簽名`void setPropertyValue(const QString&,const QVariant&,bool = 1)`。 這種方法是抽象的,應在任何子類中重新實現。 通過設置指定的屬性值_name_至_value_。 此外,該屬性標記為_changed_在屬性編輯器,即它的值從默認值不同。 **See also** [currentPropertyName](qdesignerpropertyeditorinterface.html#currentPropertyName)()和[propertyChanged](qdesignerpropertyeditorinterface.html#propertyChanged)( ) 。 ``` QDesignerPropertyEditorInterface.setReadOnly (self, bool?readOnly) ``` 這種方法也是一個Qt槽與C + +的簽名`void setReadOnly(bool)`。 這種方法是抽象的,應在任何子類中重新實現。 If _readOnly_為True,則屬性編輯器是由寫保護,否則寫保護被刪除。 **See also** [isReadOnly](qdesignerpropertyeditorinterface.html#isReadOnly)( ) 。 * * * ## Qt Signal Documentation ``` void propertyChanged (const QString&,const QVariant&) ``` 這是該信號的默認超載。 這個信號被發射時在屬性編輯器中的屬性更改。這改變了其新的價值的財產被指定_name_和_value_分別。 **See also** [setPropertyValue](qdesignerpropertyeditorinterface.html#setPropertyValue)( ) 。
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看