<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國際加速解決方案。 廣告
                # QLayoutItem Class Reference ## [[QtGui](index.htm) module] 該QLayoutItem類提供了一個抽象的概念,一個[QLayout](qlayout.html)操縱。[More...](#details) 通過繼承[QLayout](qlayout.html),[QSpacerItem](qspaceritem.html)和[QWidgetItem](qwidgetitem.html)。 ### Methods * `__init__ (self, Qt.Alignment?alignment?=?0)` * `__init__ (self, QLayoutItem)` * `Qt.Alignment alignment (self)` * `QSizePolicy.ControlTypes controlTypes (self)` * `Qt.Orientations expandingDirections (self)` * `QRect geometry (self)` * `bool hasHeightForWidth (self)` * `int heightForWidth (self, int)` * `invalidate (self)` * `bool isEmpty (self)` * `QLayout layout (self)` * `QSize maximumSize (self)` * `int minimumHeightForWidth (self, int)` * `QSize minimumSize (self)` * `setAlignment (self, Qt.Alignment?a)` * `setGeometry (self, QRect)` * `QSize sizeHint (self)` * `QSpacerItem spacerItem (self)` * `QWidget widget (self)` * * * ## Detailed Description 該QLayoutItem類提供了一個抽象的概念,一個[QLayout](qlayout.html)操縱。 這是使用自定義布局。 提供純虛函數返回有關布局的信息,包括,[sizeHint](qlayoutitem.html#sizeHint)( )[minimumSize](qlayoutitem.html#minimumSize)( )[maximumSize](qlayoutitem.html#maximumSize)( )和擴展( ) 。 布局的幾何形狀可以設置和檢索[setGeometry](qlayoutitem.html#setGeometry)()和[geometry](qlayoutitem.html#geometry)() ,其與對準[setAlignment](qlayoutitem.html#setAlignment)()和[alignment](qlayoutitem.html#alignment)( ) 。 [isEmpty](qlayoutitem.html#isEmpty)( )返回版面項目是否為空。如果具體項目是一個[QWidget](qwidget.html),它可以使用來檢索[widget](qlayoutitem.html#widget)( ) 。同樣,對于[layout](qlayoutitem.html#layout)()和[spacerItem](qlayoutitem.html#spacerItem)( ) 。 一些布局有寬度和高度的相互依存關系。這些可以使用表示[hasHeightForWidth](qlayoutitem.html#hasHeightForWidth)( )[heightForWidth](qlayoutitem.html#heightForWidth)()和[minimumHeightForWidth](qlayoutitem.html#minimumHeightForWidth)( ) 。如需詳細說明見_Qt Quarterly_文章[Trading Height for Width](http://qt.nokia.com/doc/qq/qq04-height-for-width.html)。 * * * ## Method Documentation ``` QLayoutItem.__init__ (self, Qt.Alignment?alignment?=?0) ``` 構造與布局項目_alignment_。不是所有的子類支持對齊。 ``` QLayoutItem.__init__ (self, QLayoutItem) ``` ``` Qt.Alignment QLayoutItem.alignment (self) ``` [ 返回此項目的對齊方式。 ](index.htm) [**See also**](index.htm) [setAlignment](qlayoutitem.html#setAlignment)( ) 。 ``` QSizePolicy.ControlTypes QLayoutItem.controlTypes (self) ``` [](index.htm) [返回該控件的類型( s)為布局項目。對于](index.htm)[QWidgetItem](qwidgetitem.html),控件類型來自于小部件的大小政策,對[QLayoutItem](qlayoutitem.html),控制類型,從布局中的內容導出。 **See also** [QSizePolicy.controlType](qsizepolicy.html#controlType)( ) 。 ``` Qt.Orientations QLayoutItem.expandingDirections (self) ``` [ 這種方法是抽象的,應在任何子類中重新實現。 ](index.htm) [返回此布局的項目是否可以使更多的空間比使用](index.htm)[sizeHint](qlayoutitem.html#sizeHint)( ) 。的值[Qt.Vertical](qt.html#Orientation-enum) or [Qt.Horizontal](qt.html#Orientation-enum)意味著它要在只有一維增長,而[Qt.Vertical](qt.html#Orientation-enum)|[Qt.Horizontal](qt.html#Orientation-enum)也就是說,它要在這兩個方面的增長。 ``` QRect QLayoutItem.geometry (self) ``` [ 這種方法是抽象的,應在任何子類中重新實現。 返回復蓋此布局項目的矩形。 ](qrect.html) [**See also**](qrect.html) [setGeometry](qlayoutitem.html#setGeometry)( ) 。 ``` bool QLayoutItem.hasHeightForWidth (self) ``` 返回True如果此布局的首選高度依賴于它的寬度,否則返回False 。默認實現返回False 。 在支持高度寬度布局管理器重新實現這個函數。 **See also** [heightForWidth](qlayoutitem.html#heightForWidth)()和[QWidget.heightForWidth](qwidget.html#heightForWidth)( ) 。 ``` int QLayoutItem.heightForWidth (self, int) ``` 返回此布局項目的首選高度,給出的寬度_w_。 默認實現返回-1 ,表明首選高度獨立于項目的寬度。使用功能[hasHeightForWidth](qlayoutitem.html#hasHeightForWidth)()通常比調用此函數和試驗-1快得多。 在支持高度寬度布局管理器重新實現這個函數。一個典型的實現將看起來像這樣: ``` int MyLayout.heightForWidth(int w) const { if (cache_dirty || cached_width != w) { // not all C++ compilers support "mutable" MyLayout *that = (MyLayout*)this; int h = calculateHeightForWidth(w); that->cached_hfw = h; return h; } return cached_hfw; } ``` 緩存強烈建議,沒有它的布局將需要指數時間。 **See also** [hasHeightForWidth](qlayoutitem.html#hasHeightForWidth)( ) 。 ``` QLayoutItem.invalidate (self) ``` 無效在此布局項目的任何緩存信息。 ``` bool QLayoutItem.isEmpty (self) ``` 這種方法是抽象的,應在任何子類中重新實現。 實現在子類中返回此項目是否為空,即是否包含任何部件。 ``` QLayout QLayoutItem.layout (self) ``` [](qlayout.html) [如果這個項目是一個](qlayout.html)[QLayout](qlayout.html),它返回一個[QLayout](qlayout.html)否則返回0。此功能提供了類型安全的鑄造。 ``` QSize QLayoutItem.maximumSize (self) ``` [ 這種方法是抽象的,應在任何子類中重新實現。 實現在子類中返回這個項目的最大尺寸。 ``` int QLayoutItem.minimumHeightForWidth (self, int) ``` 返回這個窗口部件需要為給定的寬度最小高度_w_。默認實現只返回heightForWidth (_w_) 。 ](qsize.html) ``` QSize QLayoutItem.minimumSize (self) ``` [ 這種方法是抽象的,應在任何子類中重新實現。 實現在子類中返回該項目的最小尺寸。 ``` QLayoutItem.setAlignment (self, Qt.Alignment?a) ``` 設置此項目的對齊方式_alignment_。 ](qsize.html) [**Note:**項目定位只支持](qsize.html)[QLayoutItem](qlayoutitem.html)子類在那里將有一個視覺效果。以外[QSpacerItem](qspaceritem.html),它提供了布局,繼承所有公共Qt類空白[QLayoutItem](qlayoutitem.html)支持項目對齊。 **See also** [alignment](qlayoutitem.html#alignment)( ) 。 ``` QLayoutItem.setGeometry (self, QRect) ``` 這種方法是抽象的,應在任何子類中重新實現。 實現在子類中設置該項目的幾何圖形_r_。 **See also** [geometry](qlayoutitem.html#geometry)( ) 。 ``` QSize QLayoutItem.sizeHint (self) ``` [ 這種方法是抽象的,應在任何子類中重新實現。 實現在子類中返回此項目的首選尺寸。 ](qsize.html) ``` QSpacerItem QLayoutItem.spacerItem (self) ``` [](qspaceritem.html) [如果這個項目是一個](qspaceritem.html)[QSpacerItem](qspaceritem.html),它返回一個[QSpacerItem](qspaceritem.html)否則返回0。此功能提供了類型安全的鑄造。 ``` QWidget QLayoutItem.widget (self) ``` [](qwidget.html) [如果這個項目是一個](qwidget.html)[QWidget](qwidget.html),它返回一個[QWidget](qwidget.html)否則返回0。此功能提供了類型安全的鑄造。
                  <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>

                              哎呀哎呀视频在线观看