The QMargins class defines the four margins of a rectangle. 更多...
| 頭: | #include <QMargins> |
| qmake: | QT += core |
| Since: | Qt 4.6 |
| QMargins () | |
| QMargins (int left , int top , int right , int bottom ) | |
| int | bottom () const |
| bool | isNull () const |
| int | left () const |
| int | right () const |
| void | setBottom (int bottom ) |
| void | setLeft (int left ) |
| void | setRight (int right ) |
| void | setTop (int Top ) |
| int | top () const |
| QMargins & | operator*= (int factor ) |
| QMargins & | operator*= (qreal factor ) |
| QMargins & | operator+= (const QMargins & margins ) |
| QMargins & | operator+= (int addend ) |
| QMargins & | operator-= (const QMargins & margins ) |
| QMargins & | operator-= (int subtrahend ) |
| QMargins & | operator/= (int divisor ) |
| QMargins & | operator/= (qreal divisor ) |
| bool | operator!= (const QMargins & m1 , const QMargins & m2 ) |
| QMargins | operator* (const QMargins & margins , int factor ) |
| QMargins | operator* (int factor , const QMargins & margins ) |
| QMargins | operator* (const QMargins & margins , qreal factor ) |
| QMargins | operator* (qreal factor , const QMargins & margins ) |
| QMargins | operator+ (const QMargins & m1 , const QMargins & m2 ) |
| QMargins | operator+ (const QMargins & lhs , int rhs ) |
| QMargins | operator+ (int lhs , const QMargins & rhs ) |
| QMargins | operator+ (const QMargins & margins ) |
| QMargins | operator- (const QMargins & m1 , const QMargins & m2 ) |
| QMargins | operator- (const QMargins & lhs , int rhs ) |
| QMargins | operator- (const QMargins & margins ) |
| QMargins | operator/ (const QMargins & margins , int divisor ) |
| QMargins | operator/ (const QMargins & margins , qreal divisor ) |
| QDataStream & | operator<< (QDataStream & stream , const QMargins & m ) |
| bool | operator== (const QMargins & m1 , const QMargins & m2 ) |
| QDataStream & | operator>> (QDataStream & stream , QMargins & m ) |
The QMargins class defines the four margins of a rectangle.
QMargins 定義一組 4 邊距;左、上、右和下,描述矩形周圍邊界的大小。
The
isNull
() 函數返迴
true
僅當所有邊距被設為 0 時。
既可以流化,也可以比較 QMargins 對象。
構造邊距對象,采用把所有邊距設為 0。
另請參閱 isNull ().
構造邊距采用給定 left , top , right , bottom
另請參閱 setLeft (), setRight (), setTop (),和 setBottom ().
返迴下邊距。
另請參閱 setBottom ().
返迴
true
若所有邊距為 0;否則返迴 false。
返迴左邊距。
另請參閱 setLeft ().
返迴右邊距。
另請參閱 setRight ().
將下邊距設為 bottom .
另請參閱 bottom ().
將左邊距設為 left .
另請參閱 left ().
將右邊距設為 right .
另請參閱 right ().
將上邊距設為 Top .
另請參閱 top ().
返迴上邊距。
另請參閱 setTop ().
此對象的各分量乘以 factor 並返迴其引用。
該函數在 Qt 5.1 引入。
另請參閱 operator/= ().
這是重載函數。
此對象的各分量乘以 factor 並返迴其引用。
該函數在 Qt 5.1 引入。
另請參閱 operator/= ().
Add each component of margins to the respective component of this object and returns a reference to it.
該函數在 Qt 5.1 引入。
另請參閱 operator-= ().
這是重載函數。
添加 addend to each component of this object and returns a reference to it.
另請參閱 operator-= ().
Subtract each component of margins from the respective component of this object and returns a reference to it.
該函數在 Qt 5.1 引入。
另請參閱 operator+= ().
這是重載函數。
減去 subtrahend from each component of this object and returns a reference to it.
另請參閱 operator+= ().
此對象的各分量除以 divisor 並返迴其引用。
該函數在 Qt 5.1 引入。
另請參閱 operator*= ().
這是重載函數。
該函數在 Qt 5.1 引入。
另請參閱 operator*= ().
返迴
true
if
m1
and
m2
不同;否則返迴
false
.
返迴 QMargins object that is formed by multiplying each component of the given margins by factor .
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator*= () 和 QMargins::operator/= ().
這是重載函數。
返迴 QMargins object that is formed by multiplying each component of the given margins by factor .
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator*= () 和 QMargins::operator/= ().
這是重載函數。
返迴 QMargins object that is formed by multiplying each component of the given margins by factor .
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator*= () 和 QMargins::operator/= ().
這是重載函數。
返迴 QMargins object that is formed by multiplying each component of the given margins by factor .
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator*= () 和 QMargins::operator/= ().
返迴 QMargins 對象是和對於給定邊距 m1 and m2 ;各分量分彆相加。
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator+= () 和 QMargins::operator-= ().
返迴 QMargins object that is formed by adding rhs to lhs .
該函數在 Qt 5.3 引入。
另請參閱 QMargins::operator+= () 和 QMargins::operator-= ().
返迴 QMargins object that is formed by adding lhs to rhs .
該函數在 Qt 5.3 引入。
另請參閱 QMargins::operator+= () 和 QMargins::operator-= ().
Returns a QMargin object that is formed from all components of margins .
該函數在 Qt 5.3 引入。
返迴 QMargins 對象的形成是通過減去 m2 from m1 ;分彆減去各分量。
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator+= () 和 QMargins::operator-= ().
返迴 QMargins 對象的形成是通過減去 rhs from lhs .
該函數在 Qt 5.3 引入。
另請參閱 QMargins::operator+= () 和 QMargins::operator-= ().
Returns a QMargin object that is formed by negating all components of margins .
該函數在 Qt 5.1 引入。
返迴 QMargins object that is formed by dividing the components of the given margins 通過給定 divisor .
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator*= () 和 QMargins::operator/= ().
這是重載函數。
返迴 QMargins object that is formed by dividing the components of the given margins 通過給定 divisor .
該函數在 Qt 5.1 引入。
另請參閱 QMargins::operator*= () 和 QMargins::operator/= ().
寫入邊距 m 到給定 stream 並返迴流引用。
另請參閱 序列化 Qt 數據類型 .
返迴
true
if
m1
and
m2
相等;否則返迴
false
.
讀取邊距從給定 stream 進邊距 m 並返迴流引用。
另請參閱 序列化 Qt 數據類型 .