Qt 4.8
|
The QSize class defines the size of a two-dimensional object using integer point precision. More...
#include <qsize.h>
Public Functions | |
QSize | boundedTo (const QSize &) const |
Returns a size holding the minimum width and height of this size and the given otherSize. More... | |
QSize | expandedTo (const QSize &) const |
Returns a size holding the maximum width and height of this size and the given otherSize. More... | |
int | height () const |
Returns the height. More... | |
bool | isEmpty () const |
Returns true if either of the width and height is less than or equal to 0; otherwise returns false. More... | |
bool | isNull () const |
Returns true if both the width and height is 0; otherwise returns false. More... | |
bool | isValid () const |
Returns true if both the width and height is equal to or greater than 0; otherwise returns false. More... | |
QSize & | operator*= (qreal c) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.Multiplies both the width and height by the given factor, and returns a reference to the size. More... | |
QSize & | operator+= (const QSize &) |
Adds the given size to this size, and returns a reference to this size. More... | |
QSize & | operator-= (const QSize &) |
Subtracts the given size from this size, and returns a reference to this size. More... | |
QSize & | operator/= (qreal c) |
Divides both the width and height by the given divisor, and returns a reference to the size. More... | |
QSize () | |
Constructs a size with an invalid width and height (i. More... | |
QSize (int w, int h) | |
Constructs a size with the given width and height. More... | |
int & | rheight () |
Returns a reference to the height. More... | |
int & | rwidth () |
Returns a reference to the width. More... | |
void | scale (int w, int h, Qt::AspectRatioMode mode) |
Scales the size to a rectangle with the given width and height, according to the specified mode: More... | |
void | scale (const QSize &s, Qt::AspectRatioMode mode) |
Scales the size to a rectangle with the given size, according to the specified mode. More... | |
void | setHeight (int h) |
Sets the height to the given height. More... | |
void | setWidth (int w) |
Sets the width to the given width. More... | |
void | transpose () |
Swaps the width and height values. More... | |
int | width () const |
Returns the width. More... | |
Properties | |
int | ht |
int | wd |
Friends | |
bool | operator!= (const QSize &, const QSize &) |
Returns true if s1 and s2 are different; otherwise returns false. More... | |
const QSize | operator* (const QSize &, qreal) |
const QSize | operator* (qreal, const QSize &) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More... | |
const QSize | operator+ (const QSize &, const QSize &) |
Returns the sum of s1 and s2; each component is added separately. More... | |
const QSize | operator- (const QSize &, const QSize &) |
Returns s2 subtracted from s1; each component is subtracted separately. More... | |
const QSize | operator/ (const QSize &, qreal) |
Divides the given size by the given divisor, and returns the result rounded to the nearest integer. More... | |
bool | operator== (const QSize &, const QSize &) |
Returns true if s1 and s2 are equal; otherwise returns false. More... | |
Related Functions | |
(Note that these are not member functions.) | |
QDataStream & | operator<< (QDataStream &stream, const QSize &size) |
Writes the given size to the given stream, and returns a reference to the stream. More... | |
QDataStream & | operator>> (QDataStream &stream, QSize &size) |
Reads a size from the given stream into the given size, and returns a reference to the stream. More... | |
The QSize class defines the size of a two-dimensional object using integer point precision.
A size is specified by a width() and a height(). It can be set in the constructor and changed using the setWidth(), setHeight(), or scale() functions, or using arithmetic operators. A size can also be manipulated directly by retrieving references to the width and height using the rwidth() and rheight() functions. Finally, the width and height can be swapped using the transpose() function.
The isValid() function determines if a size is valid (a valid size has both width and height greater than zero). The isEmpty() function returns true if either of the width and height is less than, or equal to, zero, while the isNull() function returns true only if both the width and the height is zero.
Use the expandedTo() function to retrieve a size which holds the maximum height and width of this size and a given size. Similarly, the boundedTo() function returns a size which holds the minimum height and width of this size and a given size.
QSize objects can be streamed as well as compared.
|
inline |
Constructs a size with an invalid width and height (i.
e., isValid() returns false).
Definition at line 111 of file qsize.h.
Referenced by boundedTo(), expandedTo(), operator*(), operator+(), operator-(), operator/(), and scale().
|
inline |
Constructs a size with the given width and height.
Returns a size holding the minimum width and height of this size and the given otherSize.
Definition at line 192 of file qsize.h.
Referenced by QLayout::alignmentRect(), QMdiAreaPrivate::appendChild(), QLayout::closestAcceptableSize(), QItemDelegate::doLayout(), fixToolBarOrientation(), QDockAreaLayout::getGrid(), QTabWidget::heightForWidth(), QTabWidget::initStyleOption(), QGridLayout::maximumSize(), qSmartMinSize(), QToolBarAreaLayoutItem::realSizeHint(), QWidget::resize(), QWidgetItem::setGeometry(), QWidget::setGeometry(), QBoxLayoutPrivate::setupGeom(), QMdiArea::showEvent(), QDockWidgetLayout::sizeFromContent(), QScrollArea::sizeHint(), QWellArray::sizeHint(), QWidgetItem::sizeHint(), QTabWidget::sizeHint(), QWorkspaceChild::sizeHint(), QWidgetItemV2::updateCacheIfNecessary(), QScrollAreaPrivate::updateScrollBars(), and QCommonStylePrivate::viewItemLayout().
Returns a size holding the maximum width and height of this size and the given otherSize.
Definition at line 187 of file qsize.h.
Referenced by QRenderRule::adjustSize(), QMdiAreaPrivate::appendChild(), QMenuBarPrivate::calcActionRects(), QWorkspace::cascade(), QLayout::closestAcceptableSize(), QStyleSheetStyle::drawComplexControl(), QDockAreaLayout::getGrid(), getNetWmState(), QTabWidget::heightForWidth(), QStackedLayout::minimumSize(), QGroupBox::minimumSizeHint(), QMdiSubWindow::minimumSizeHint(), QMdiArea::minimumSizeHint(), QMenuBar::minimumSizeHint(), QAbstractSpinBox::minimumSizeHint(), QTabWidget::minimumSizeHint(), QTabBar::minimumSizeHint(), QWidgetResizeHandler::mouseMoveEvent(), QStyleSheetStyle::positionRect(), qNormalizeRadii(), qSmartMaxSize(), qSmartMinSize(), QWorkspaceChild::QWorkspaceChild(), QToolBarAreaLayoutItem::realSizeHint(), QMdiAreaPrivate::rearrange(), QComboBoxPrivate::recomputeSizeHint(), QWidget::resize(), QMdiAreaPrivate::resizeToMinimumTileSize(), QMainWindowLayout::setGeometry(), QWidget::setGeometry(), QMdiSubWindowPrivate::setNewGeometry(), QMdiSubWindowPrivate::setNormalMode(), QBoxLayoutPrivate::setupGeom(), QMdiSubWindowPrivate::setWindowFlags(), QWorkspaceChild::showShaded(), QLabelPrivate::sizeForWidth(), QDockWidgetLayout::sizeFromContent(), QMacStyle::sizeFromContents(), QGtkStyle::sizeFromContents(), QStyleSheetStyle::sizeFromContents(), QCheckBox::sizeHint(), QScrollBar::sizeHint(), QColumnView::sizeHint(), QToolBoxButton::sizeHint(), QMdiSubWindow::sizeHint(), QDial::sizeHint(), QSlider::sizeHint(), QStackedLayout::sizeHint(), QMdiArea::sizeHint(), QMenuBar::sizeHint(), QAbstractSpinBox::sizeHint(), QWidgetItem::sizeHint(), QTabWidget::sizeHint(), QMenu::sizeHint(), DetailButton::sizeHint(), QTabBar::sizeHint(), QDateTimeEdit::sizeHint(), QSplitterHandle::sizeHint(), QWizard::sizeHint(), QWorkspaceChild::sizeHint(), QCommonStyle::subControlRect(), QWindowsMobileStyle::subControlRect(), QWindowsCEStyle::subControlRect(), QMotifStyle::subControlRect(), QWorkspace::tile(), QMenuPrivate::updateActionRects(), QWidgetItemV2::updateCacheIfNecessary(), and QScrollAreaPrivate::updateScrollBars().
|
inline |
Returns the height.
Definition at line 129 of file qsize.h.
Referenced by QTextEditPrivate::_q_adjustScrollbars(), QWorkspacePrivate::_q_showOperationMenu(), QGLFramebufferObjectPool::acquire(), QLayout::activate(), QAxClientSite::activateObject(), QPixmapIconEngine::actualSize(), QIconLoaderEngine::actualSize(), QLayout::addChildWidget(), QGridLayoutPrivate::addData(), QGridLayoutPrivate::addHfwData(), QPushButtonPrivate::adjustedMenuPosition(), QWidgetPrivate::adjustedSize(), QRenderRule::adjustSize(), QWorkspaceChild::adjustToFullscreen(), QStyle::alignedRect(), QLayout::alignmentRect(), QDockAreaLayoutInfo::apply(), QApplicationPrivate::applyX11SpecificCommandLineArguments(), QMacStylePrivate::aquaSizeConstrain(), area(), areaDiff(), QFormLayoutPrivate::arrangeWidgets(), QBalloonTip::balloon(), QWorkspaceChild::baseSize(), basicSize(), QGL2PaintEngineEx::begin(), blitTexture(), QVGCompositionHelper::blitWindow(), QRenderRule::borderClip(), QRenderRule::boxSize(), QMenuBarPrivate::calcActionRects(), QWorkspace::cascade(), QLayout::closestAcceptableSize(), QMacStylePrivate::contentFitsInPushButton(), QRenderRule::contentsSize(), QOpenGLPaintEnginePrivate::copyDrawable(), QImageData::create(), QWidgetPrivate::create_sys(), QDirectFBScreen::createDFBSurface(), QStyleSheetStyle::defaultSize(), QPixmap::depth(), determineScreenSize(), QIconModeViewBase::doBatchedItemLayout(), documentSize(), QIconModeViewBase::doDynamicLayout(), QItemDelegate::doLayout(), QListModeViewBase::doStaticLayout(), QVGPixmapConvolutionFilter::draw(), QVGPixmapColorizeFilter::draw(), QVGPixmapDropShadowFilter::draw(), QVGPixmapBlurFilter::draw(), QAlphaPaintEnginePrivate::drawAlphaImage(), QStyleHelper::drawBorderPixmap(), QCommonStyle::drawControl(), QWindowsVistaStyle::drawControl(), QPlastiqueStyle::drawControl(), QMacStyle::drawControl(), QStyleSheetStyle::drawControl(), QOpenGLPaintEnginePrivate::drawItem(), QGraphicsScenePrivate::drawItemHelper(), QGLTrapezoidMaskGenerator::drawMask(), QGLEllipseMaskGenerator::drawMask(), QGL2PaintEngineEx::drawPixmapFragments(), QGL2PaintEngineExPrivate::drawPixmapFragments(), QWindowsVistaStyle::drawPrimitive(), QGL2PaintEngineExPrivate::drawTexture(), drawTexture(), QDirectFBPaintEnginePrivate::drawTiledPixmap(), QVistaHelper::drawTitleBar(), effectiveState(), QIconLoaderEngine::entryForSize(), QStatusBar::event(), QAxHostWidget::event(), QWorkspaceChild::eventFilter(), QVGPaintEngine::fillRegion(), QOpenGLPaintEnginePrivate::fillVertexArray(), QIconModeViewBase::filterDropEvent(), QToolBarAreaLayoutInfo::fitLayout(), QToolBarAreaLayout::fitLayout(), QMainWindowLayout::fixSizeInUnifiedToolbar(), QGLWindowSurface::flush(), QVideoSurfaceFormat::frameHeight(), QBitmap::fromData(), QGLPixmapData::fromData(), QGLPixmapData::fromFile(), generateBlurTexture(), QMdi::MinOverlapPlacer::getCandidatePlacements(), QAxServerBase::GetExtent(), QDockAreaLayout::getGrid(), QBBScreenEventHandler::handleTouchEvent(), QVideoFrame::height(), QCommandLinkButton::heightForWidth(), QMenuBar::heightForWidth(), QWidgetItemV2::heightForWidth(), QBoxLayoutItem::hfw(), QMainWindowLayout::hover(), QTreeView::indexRowSizeHint(), QColorDialogPrivate::init(), QGLPixelBufferPrivate::init(), QIconModeViewBase::initBspTree(), QMacStylePrivate::initComboboxBdi(), QIconModeViewBase::initDynamicLayout(), QGLWindowSurface::initializeOffscreenTexture(), initLayoutStruct(), QTabBarPrivate::initStyleBaseOption(), QWidgetPrivate::invalidateBuffer_resizeHelper(), QAxServerBase::Invoke(), QWidget::isEnabledToTLW(), isServerProcess(), QProgressDialogPrivate::layout(), QToolBarLayout::layoutActions(), QTabBarPrivate::layoutTabs(), QDeclarativeBorderImage::load(), QDirectFBPaintDevice::lockSurface(), make_widget_eventUPP(), make_win_eventUPP(), QShivaContext::makeCurrent(), QTransformedScreen::mapFromDevice(), QTransformedScreen::mapToDevice(), QListModeViewBase::mapToViewport(), QDockAreaLayoutInfo::maximumSize(), maybeRoundToNextPowerOfTwo(), menuBarHeightForWidth(), QGLPaintDevice::metric(), QBoxLayoutItem::mhfw(), QDockAreaLayoutInfo::minimumSize(), QToolBarAreaLayout::minimumSize(), QDockAreaLayout::minimumSize(), QMainWindowLayout::minimumSize(), QCommandLinkButton::minimumSizeHint(), QMdiSubWindow::minimumSizeHint(), QDialog::minimumSizeHint(), QMenuBar::minimumSizeHint(), QLabel::minimumSizeHint(), QTabBar::minimumSizeHint(), QListView::moveCursor(), nearest_gl_texture_size(), QWaylandEglWindow::newSurfaceCreated(), QWaylandWindow::newSurfaceCreated(), operator<<(), operator>>(), QTreeViewPrivate::paintAlternatingRowColors(), QGtkPainter::paintBox(), QGtkPainter::paintBoxGap(), QGraphicsWidget::paintWindowFrame(), QMacPrintEnginePrivate::paperSize(), parseGeometry(), QWSYellowSurface::permanentState(), perp(), QSplitterLayoutStruct::pick(), QSplitterPrivate::pick(), pick(), QCommonStyle::pixelMetric(), QMacStyle::pixelMetric(), QStyleSheetStyle::pixelMetric(), PixmapEntry::pixmap(), QPixmapIconEngine::pixmap(), QSvgIconEnginePrivate::pmcKey(), pmKey(), QMenu::popup(), QToolButtonPrivate::popupTimerDone(), QDateTimeEditPrivate::positionCalendarPopup(), QStyleSheetStyle::positionRect(), QGLPixmapBlurFilter::processGL(), QVideoSurfaceFormat::property(), QMacStylePrivate::pushButtonSizeFromContents(), PvrEglWindowSurface::PvrEglWindowSurface(), QDirectFbBlitter::QDirectFbBlitter(), qDrawBorder(), qHash(), qNormalizeRadii(), QPixmap::QPixmap(), QRect::QRect(), QRollEffect::QRollEffect(), qSmartMaxSize(), qSmartMinSize(), qt_aqua_get_known_size(), qt_aqua_guess_size(), qt_defaultDpiY(), qt_format_to_attrib_list(), qt_mac_widget_in_menu_eventHandler(), QtWndProc(), QGLMaskTextureCache::quadtreeFindAvailableLocation(), QGLMaskTextureCache::quadtreeFindExistingLocation(), QVNCDirtyMap::QVNCDirtyMap(), QWaylandShmBuffer::QWaylandShmBuffer(), QWaylandXCompositeBuffer::QWaylandXCompositeBuffer(), QWorkspaceChild::QWorkspaceChild(), QXcbShmImage::QXcbShmImage(), QSvgIOHandler::read(), read_jpeg_image(), QPFGlyphTree::readData(), readImage(), QGraphicsViewPrivate::recalculateContentSize(), QComboBoxPrivate::recomputeSizeHint(), QToolBarAreaLayout::rectHint(), QStatusBar::reformat(), QTextEditPrivate::relayoutDocument(), QDeclarativeBorderImage::requestFinished(), QCocoaWindowSurface::resize(), QBBRootWindow::resize(), QRubberBand::resize(), QListViewItem::resize(), QWidget::resize(), QXlibWindowSurface::resizeBuffer(), QColumnViewPreviewColumn::resizeEvent(), QListView::resizeEvent(), QWorkspaceChild::resizeEvent(), QMdiAreaPrivate::resizeToMinimumTileSize(), QAlphaWidget::run(), QPixmap::scaled(), QImage::scaled(), QmlJSDebugger::ZoomTool::scaleView(), QVGEGLWindowSurfaceDirect::scroll(), QHeaderView::sectionSizeFromContents(), QHeaderView::sectionSizeHint(), QPageSetupWidget::selectPrinter(), QWidget::setBaseSize(), QBlittablePixmapData::setBlittable(), QBBWindow::setBufferSize(), QHeaderView::setDefaultSectionSize(), QBoxLayout::setDirection(), QAxServerBase::SetExtent(), QWidget::setFixedSize(), QSplitterPrivate::setGeo(), QX11GLWindowSurface::setGeometry(), QX11WindowSurface::setGeometry(), QWidgetItem::setGeometry(), QStyleSheetStyle::setGeometry(), QWSLocalMemSurface::setGeometry(), QWSSharedMemSurface::setGeometry(), QDeclarativeBorderImage::setGridScaledImage(), QWidget::setMaximumSize(), QLayout::setMenuBar(), QWidget::setMinimumSize(), QMdiSubWindowPrivate::setNewGeometry(), QGLMaskTextureCache::setOffscreenSize(), QMacPrintEnginePrivate::setPaperSize(), QBBScreen::setRotation(), QListView::setSelection(), QRect::setSize(), QWidget::setSizeIncrement(), QTransformedScreen::setTransformation(), QGLShaderProgram::setUniformValue(), QWizardHeader::setup(), QBoxLayoutPrivate::setupGeom(), QGridLayoutPrivate::setupHfwLayoutData(), QFormLayoutPrivate::setupHfwLayoutData(), QFormLayoutPrivate::setupVerticalLayoutData(), QDeclarativeSizeValueType::setValue(), QMdiSubWindowPrivate::setWindowFlags(), QDialog::showExtension(), QCompleterPrivate::showPopup(), QDockWidgetLayout::sizeFromContent(), QWindowsVistaStyle::sizeFromContents(), QPlastiqueStyle::sizeFromContents(), QWindowsMobileStyle::sizeFromContents(), QCommonStyle::sizeFromContents(), QWindowsCEStyle::sizeFromContents(), QCleanlooksStyle::sizeFromContents(), QWindowsXPStyle::sizeFromContents(), QWindowsStyle::sizeFromContents(), QMotifStyle::sizeFromContents(), QMacStyle::sizeFromContents(), QGtkStyle::sizeFromContents(), QStyleSheetStyle::sizeFromContents(), QRadioButton::sizeHint(), QCheckBox::sizeHint(), QPushButton::sizeHint(), QScrollArea::sizeHint(), QToolBoxButton::sizeHint(), QWorkspace::sizeHint(), QToolButton::sizeHint(), QDialog::sizeHint(), QProgressDialog::sizeHint(), QMdiArea::sizeHint(), QMenuBar::sizeHint(), QDockWidgetTitleButton::sizeHint(), QVideoSurfaceFormat::sizeHint(), QMenu::sizeHint(), QDockAreaLayoutInfo::sizeHint(), QWizard::sizeHint(), QToolBarAreaLayout::sizeHint(), QDockAreaLayout::sizeHint(), QMainWindowLayout::sizeHint(), QTableView::sizeHintForRow(), QIconModeViewBase::snapToGrid(), QWidgetBackingStore::staticContents(), QCommonStyle::subControlRect(), QWindowsVistaStyle::subControlRect(), QWindowsXPStyle::subControlRect(), QWindowsMobileStyle::subControlRect(), QWindowsCEStyle::subControlRect(), QMotifStyle::subControlRect(), QGtkStyle::subControlRect(), QStyleSheetStyle::subControlRect(), QCommonStyle::subElementRect(), QMacStyle::subElementRect(), QStyleSheetStyle::subElementRect(), QWaylandReadbackGlxContext::swapBuffers(), QWaylandReadbackEglContext::swapBuffers(), QDockAreaLayoutInfo::tabContentRect(), QCommonStylePrivate::tabLayout(), QTabBar::tabSizeHint(), QItemDelegate::textRectangle(), QWorkspace::tile(), QTest::toString(), QLayout::totalMaximumSize(), QSplitterPrivate::trans(), QDirectFBPixmapData::transformed(), QETWidget::translateConfigEvent(), QStyleHelper::uniqueName(), uniqueName(), QMenuPrivate::updateActionRects(), ShaderEffectSource::updateBackbuffer(), QGL2PaintEngineExPrivate::updateBrushTexture(), QCalendarTextNavigator::updateDateLabel(), QOpenGLPaintEnginePrivate::updateDepthClip(), QOpenGLPaintEnginePrivate::updateFragmentProgramData(), QTableView::updateGeometries(), QTreeView::updateGeometries(), QGLWindowSurface::updateGeometry(), ShaderEffectItem::updateGeometry(), QAxServerBase::updateGeometry(), QWizardPrivate::updateMinMaxSizes(), ShaderEffect::updateRenderTargets(), QScrollAreaPrivate::updateScrollBars(), QTreeViewPrivate::updateScrollBars(), QMdiAreaPrivate::updateScrollBars(), QDeclarativeTextPrivate::updateSize(), QMessageBoxPrivate::updateSize(), ShaderEffectSource::updateSizeAndTexture(), QMdiAreaPrivate::updateTabBarGeometry(), QCommonListViewBase::updateVerticalScrollBar(), QListModeViewBase::updateVerticalScrollBar(), useScrollBar(), QSettingsPrivate::variantToString(), QCommonStylePrivate::viewItemLayout(), QCommonStylePrivate::viewItemSize(), and QPdfEnginePrivate::writePage().
|
inline |
Returns true if either of the width and height is less than or equal to 0; otherwise returns false.
Definition at line 120 of file qsize.h.
Referenced by QMenuBarPrivate::calcActionRects(), QIconModeViewBase::doDynamicLayout(), QGraphicsScenePrivate::drawItemHelper(), QGLPixmapData::fromData(), QGLPixmapData::fromFile(), QBBWindow::hasBuffers(), ShaderEffectSource::markSourceSizeDirty(), QWorkspaceChild::minimumSizeHint(), QPdfEnginePrivate::newPage(), QMdi::MinOverlapPlacer::place(), QSvgIOHandler::read(), read_jpeg_image(), QTreeViewPrivate::renderTreeToPixmapForAnimation(), QPixmap::scaled(), QImage::scaled(), QWSLocalMemSurface::setGeometry(), QWSSharedMemSurface::setGeometry(), QRasterPixmapData::setMask(), QPixmapData::setMask(), QWindowsVistaStyle::sizeFromContents(), QWindowsStyle::sizeFromContents(), QWindowsXPStyle::sizeFromContents(), QMotifStyle::sizeFromContents(), QDeclarativeView::sizeHint(), QWidgetBackingStore::staticContents(), QCommonStylePrivate::tabLayout(), QTabBar::tabSizeHint(), QDeclarativeTextPrivate::textLayoutImage(), QDirectFBPixmapData::transformed(), QMenuPrivate::updateActionRects(), ShaderEffectSource::updateBackbuffer(), ShaderEffect::updateRenderTargets(), ShaderEffectSource::updateSizeAndTexture(), and QPixmapIconEngine::virtual_hook().
|
inline |
Returns true if both the width and height is 0; otherwise returns false.
Definition at line 117 of file qsize.h.
Referenced by QPixmapIconEngine::actualSize(), QDockAreaLayoutInfo::apply(), QPixmapIconEngine::bestMatch(), QRenderRule::borderClip(), QScreen::compose(), QMacStyle::drawControl(), QDockAreaLayout::getGrid(), QDockAreaLayoutInfo::maximumSize(), QDockAreaLayoutInfo::minimumSize(), QMenuBar::minimumSizeHint(), QSvgIconEngine::pixmap(), QPixmapIconEngine::pixmap(), QWidgetPrivate::render_helper(), QListView::resizeEvent(), QMacWindowSurface::scroll(), QMdiSubWindowPrivate::setNormalMode(), QListView::setSelection(), QGraphicsProxyWidgetPrivate::setWidget_helper(), QStyleSheetStyle::sizeFromContents(), QWizard::sizeHint(), QDirectFBScreen::surfaceForWidget(), QDockAreaLayoutInfo::tabContentRect(), and QTabBar::tabSizeHint().
|
inline |
Returns true if both the width and height is equal to or greater than 0; otherwise returns false.
Definition at line 123 of file qsize.h.
Referenced by QWorkspace::addWindow(), QWidgetPrivate::adjustedSize(), QWidget::adjustSize(), QFormLayoutPrivate::arrangeWidgets(), QPixmapIconEngine::bestMatch(), QWorkspace::cascade(), QImageData::create(), QIconModeViewBase::doDynamicLayout(), QListViewPrivate::doItemsLayout(), QListModeViewBase::doStaticLayout(), QGraphicsScenePrivate::drawItemHelper(), QRenderRule::fixupBorder(), QDockAreaLayout::getGrid(), QSplitterLayoutStruct::getWidgetSize(), QListModeViewBase::indexToListViewItem(), QIconModeViewBase::initDynamicLayout(), QToolButton::initStyleOption(), QVideoSurfaceFormat::isValid(), QListViewPrivate::itemSize(), QMdiSubWindow::minimumSizeHint(), QAxWidget::minimumSizeHint(), QSplitter::minimumSizeHint(), QAxHostWidget::minimumSizeHint(), QWaylandEglWindow::newSurfaceCreated(), QMoviePrivate::next(), QTiffHandler::option(), QApplicationPrivate::qt_mac_apply_settings(), QSvgIOHandler::read(), QImageReader::read(), QComboBoxPrivate::recomputeSizeHint(), QAxServerBase::resize(), QMdiAreaPrivate::resizeToMinimumTileSize(), QGraphicsItem::scroll(), QMainWindow::setIconSize(), QToolBar::setIconSize(), QMdiSubWindowPrivate::setMaximizeMode(), QListView::setSelection(), QAxWidget::sizeHint(), QSplitter::sizeHint(), QMacStyle::styleHint(), QCommonStylePrivate::tabLayout(), QAxServerBase::updateGeometry(), QGraphicsProxyWidgetPrivate::updateProxyGeometryFromWidget(), QTreeViewPrivate::updateScrollBars(), QDeclarativeViewPrivate::updateSize(), and QApplicationPrivate::x11_apply_settings().
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.Multiplies both the width and height by the given factor, and returns a reference to the size.
Note that the result is rounded to the nearest integer.
Definition at line 153 of file qsize.h.
Divides both the width and height by the given divisor, and returns a reference to the size.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Note that the result is rounded to the nearest integer.
Definition at line 174 of file qsize.h.
|
inline |
Returns a reference to the height.
Using a reference makes it possible to manipulate the height directly. For example:
Definition at line 144 of file qsize.h.
Referenced by QFormLayoutPrivate::calcSizeHints(), QDirectFBScreen::copyDFBSurface(), QIconModeViewBase::doDynamicLayout(), QDirectFBPixmapData::fill(), isFullUpdate(), QDockAreaLayoutInfo::maximumSize(), QAbstractScrollArea::maximumViewportSize(), QDockAreaLayoutInfo::minimumSize(), QToolBarAreaLayout::minimumSize(), QLabel::minimumSizeHint(), QSizeGrip::mouseMoveEvent(), operator>>(), QTipLabel::reuseTip(), rperp(), rpick(), QPixmap::scaled(), QImage::scaled(), QHeaderView::sectionSizeFromContents(), QDirectFBScreenCursor::set(), QAxServerBase::SetExtent(), QAxServerBase::SetObjectRects(), QWindowsVistaStyle::sizeFromContents(), QPlastiqueStyle::sizeFromContents(), QMacStyle::sizeFromContents(), QMenu::sizeHint(), QDockAreaLayoutInfo::sizeHint(), QToolBarAreaLayout::sizeHint(), QWorkspace::tile(), and QMdiAreaPrivate::updateScrollBars().
|
inline |
Returns a reference to the width.
Using a reference makes it possible to manipulate the width directly. For example:
Definition at line 141 of file qsize.h.
Referenced by QFormLayoutPrivate::calcSizeHints(), QDirectFBScreen::copyDFBSurface(), QIconModeViewBase::doDynamicLayout(), QItemDelegate::doLayout(), QDirectFBPixmapData::fill(), isFullUpdate(), QDockAreaLayoutInfo::maximumSize(), QAbstractScrollArea::maximumViewportSize(), QDockAreaLayoutInfo::minimumSize(), QToolBarAreaLayout::minimumSize(), QLabel::minimumSizeHint(), operator>>(), QComboBoxPrivate::recomputeSizeHint(), rperp(), rpick(), QPixmap::scaled(), QImage::scaled(), QHeaderView::sectionSizeFromContents(), QDirectFBScreenCursor::set(), QAxServerBase::SetExtent(), QAxServerBase::SetObjectRects(), QWindowsVistaStyle::sizeFromContents(), QPlastiqueStyle::sizeFromContents(), QMotifStyle::sizeFromContents(), QMacStyle::sizeFromContents(), QMenu::sizeHint(), QDockAreaLayoutInfo::sizeHint(), QToolBarAreaLayout::sizeHint(), QMdiAreaPrivate::updateScrollBars(), and QCommonStylePrivate::viewItemLayout().
|
inline |
Scales the size to a rectangle with the given width and height, according to the specified mode:
If mode is Qt::IgnoreAspectRatio, the size is set to (width, height).
Example:
Definition at line 138 of file qsize.h.
Referenced by QPixmapIconEngine::actualSize(), QSvgIconEngine::pixmap(), QPixmapIconEngine::pixmap(), QBBScreen::resizeTopLevelWindow(), QPixmap::scaled(), and QImage::scaled().
void QSize::scale | ( | const QSize & | size, |
Qt::AspectRatioMode | mode | ||
) |
Scales the size to a rectangle with the given size, according to the specified mode.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 236 of file qsize.cpp.
|
inline |
Sets the height to the given height.
Definition at line 135 of file qsize.h.
Referenced by QGLFramebufferObjectPool::acquire(), QLayout::activate(), QAxClientSite::activateObject(), QWidgetPrivate::adjustedSize(), QRenderRule::adjustSize(), QLayout::alignmentRect(), QRenderRule::boxSize(), QLayout::closestAcceptableSize(), QRenderRule::contentsSize(), QStyleSheetStyle::defaultSize(), documentSize(), QItemDelegate::doLayout(), QWindowsVistaStyle::drawControl(), QProgressDialogPrivate::layout(), QGridLayout::maximumSize(), QBoxLayout::maximumSize(), QToolBarAreaLayout::minimumSize(), QCommandLinkButton::minimumSizeHint(), QSlider::minimumSizeHint(), QMenuBar::minimumSizeHint(), QMenu::popup(), QStyleSheetStyle::positionRect(), QMacStylePrivate::pushButtonSizeFromContents(), qSmartMaxSize(), qSmartMinSize(), qt_aqua_get_known_size(), readImage(), QToolBarAreaLayoutItem::realSizeHint(), QComboBoxPrivate::recomputeSizeHint(), QDeclarativeViewPrivate::rootObjectSize(), QWidgetItem::setGeometry(), QSvgTinyDocument::setHeight(), QDeclarativeSizeValueType::setHeight(), QMdiSubWindowPrivate::setMaximizeMode(), QMdiSubWindowPrivate::setNormalMode(), QGridLayoutPrivate::setupHfwLayoutData(), QDockWidgetLayout::sizeFromContent(), QWindowsVistaStyle::sizeFromContents(), QPlastiqueStyle::sizeFromContents(), QWindowsMobileStyle::sizeFromContents(), QCommonStyle::sizeFromContents(), QWindowsCEStyle::sizeFromContents(), QCleanlooksStyle::sizeFromContents(), QWindowsStyle::sizeFromContents(), QWindowsXPStyle::sizeFromContents(), QMacStyle::sizeFromContents(), QGtkStyle::sizeFromContents(), QStyleSheetStyle::sizeFromContents(), QCommandLinkButton::sizeHint(), QScrollArea::sizeHint(), QMenuBar::sizeHint(), QWidgetItem::sizeHint(), QMenu::sizeHint(), QWizard::sizeHint(), QToolBarAreaLayout::sizeHint(), QCommonStyle::subControlRect(), QWindowsMobileStyle::subControlRect(), QWindowsCEStyle::subControlRect(), QCleanlooksStyle::subControlRect(), QMotifStyle::subControlRect(), QGtkStyle::subControlRect(), QLayout::totalSizeHint(), QETWidget::translateConfigEvent(), QMenuPrivate::updateActionRects(), QAxServerBase::updateGeometry(), QWizardPrivate::updateMinMaxSizes(), ShaderEffectSource::updateSizeAndTexture(), and QCommonStylePrivate::viewItemLayout().
|
inline |
Sets the width to the given width.
Definition at line 132 of file qsize.h.
Referenced by QGLFramebufferObjectPool::acquire(), QLayout::activate(), QAxClientSite::activateObject(), QWidgetPrivate::adjustedSize(), QMenuPrivate::adjustMenuSizeForScreen(), QRenderRule::adjustSize(), QLayout::alignmentRect(), QRenderRule::boxSize(), QRenderRule::contentsSize(), QStyleSheetStyle::defaultSize(), QWindowsVistaStyle::drawControl(), QWindowsVistaStyle::drawPrimitive(), QListModeViewBase::indexToListViewItem(), QGridLayout::maximumSize(), QBoxLayout::maximumSize(), QToolBarAreaLayout::minimumSize(), QSlider::minimumSizeHint(), QMenuBar::minimumSizeHint(), QStyleSheetStyle::positionRect(), QMacStylePrivate::pushButtonSizeFromContents(), qSmartMaxSize(), qSmartMinSize(), qt_aqua_get_known_size(), readImage(), QToolBarAreaLayoutItem::realSizeHint(), QComboBoxPrivate::recomputeSizeHint(), QDeclarativeViewPrivate::rootObjectSize(), QWidgetItem::setGeometry(), QMdiSubWindowPrivate::setMaximizeMode(), QMdiSubWindowPrivate::setNormalMode(), QSvgTinyDocument::setWidth(), QDeclarativeSizeValueType::setWidth(), QDockWidgetLayout::sizeFromContent(), QCommonStyle::sizeFromContents(), QCleanlooksStyle::sizeFromContents(), QWindowsStyle::sizeFromContents(), QMotifStyle::sizeFromContents(), QMacStyle::sizeFromContents(), QGtkStyle::sizeFromContents(), QStyleSheetStyle::sizeFromContents(), QCommandLinkButton::sizeHint(), QScrollArea::sizeHint(), QToolButton::sizeHint(), QFontComboBox::sizeHint(), QMenuBar::sizeHint(), QVideoSurfaceFormat::sizeHint(), QWidgetItem::sizeHint(), QMenu::sizeHint(), QWizard::sizeHint(), QToolBarAreaLayout::sizeHint(), QCommonStyle::subControlRect(), QWindowsMobileStyle::subControlRect(), QWindowsCEStyle::subControlRect(), QCleanlooksStyle::subControlRect(), QMotifStyle::subControlRect(), QGtkStyle::subControlRect(), QETWidget::translateConfigEvent(), QMenuPrivate::updateActionRects(), QWidgetItemV2::updateCacheIfNecessary(), updateFormLayoutItem(), QAxServerBase::updateGeometry(), QWizardPrivate::updateMinMaxSizes(), QDeclarativeViewPrivate::updateSize(), and ShaderEffectSource::updateSizeAndTexture().
void QSize::transpose | ( | ) |
Swaps the width and height values.
Definition at line 196 of file qsize.cpp.
Referenced by QCommonStyle::drawControl(), QWindowsVistaStyle::drawControl(), QPlastiqueStyle::drawControl(), QWindowsMobileStyle::drawControl(), QCleanlooksStyle::drawControl(), QWindowsXPStyle::drawControl(), QWindowsStyle::drawControl(), QGtkStyle::drawControl(), QMacStyle::drawControl(), QStyleSheetStyle::drawControl(), QMainWindowTabBar::event(), QBBScreen::QBBScreen(), QMacStyle::sizeFromContents(), QProgressBar::sizeHint(), QCommonStyle::subElementRect(), and QMacStyle::subElementRect().
|
inline |
Returns the width.
Definition at line 126 of file qsize.h.
Referenced by QTextEditPrivate::_q_adjustScrollbars(), QWorkspacePrivate::_q_showOperationMenu(), QCalendarWidgetPrivate::_q_yearClicked(), QGLFramebufferObjectPool::acquire(), QLayout::activate(), QAxClientSite::activateObject(), QPixmapIconEngine::actualSize(), QIconLoaderEngine::actualSize(), QLayout::addChildWidget(), QGridLayoutPrivate::addData(), QPushButtonPrivate::adjustedMenuPosition(), QWidgetPrivate::adjustedSize(), QRenderRule::adjustSize(), QStyle::alignedRect(), QLayout::alignmentRect(), QDockAreaLayoutInfo::apply(), QApplicationPrivate::applyX11SpecificCommandLineArguments(), QMacStylePrivate::aquaSizeConstrain(), area(), areaDiff(), QFormLayoutPrivate::arrangeWidgets(), QBalloonTip::balloon(), basicSize(), QGL2PaintEngineEx::begin(), blitTexture(), QRenderRule::borderClip(), QRenderRule::boxSize(), QMenuBarPrivate::calcActionRects(), QWorkspace::cascade(), QLayout::closestAcceptableSize(), QComboBoxPrivate::computeWidthHint(), QMacStylePrivate::contentFitsInPushButton(), QRenderRule::contentsSize(), QOpenGLPaintEnginePrivate::copyDrawable(), QImageData::create(), QWidgetPrivate::create_sys(), QColumnViewPrivate::createColumn(), QDirectFBScreen::createDFBSurface(), QStyleSheetStyle::defaultSize(), QPixmap::depth(), determineScreenSize(), QIconModeViewBase::doBatchedItemLayout(), QIconModeViewBase::doDynamicLayout(), QItemDelegate::doLayout(), QLayoutPrivate::doResize(), QListModeViewBase::doStaticLayout(), QVGPixmapConvolutionFilter::draw(), QVGPixmapColorizeFilter::draw(), QVGPixmapDropShadowFilter::draw(), QVGPixmapBlurFilter::draw(), QAlphaPaintEnginePrivate::drawAlphaImage(), QStyleHelper::drawBorderPixmap(), QCommonStyle::drawControl(), QWindowsVistaStyle::drawControl(), QPlastiqueStyle::drawControl(), QWindowsXPStyle::drawControl(), QStyleSheetStyle::drawControl(), QGraphicsScenePrivate::drawItemHelper(), QGL2PaintEngineEx::drawPixmapFragments(), QGL2PaintEngineExPrivate::drawPixmapFragments(), QWindowsVistaStyle::drawPrimitive(), QGL2PaintEngineExPrivate::drawTexture(), drawTexture(), QDirectFBPaintEnginePrivate::drawTiledPixmap(), effectiveState(), QIconLoaderEngine::entryForSize(), QAxHostWidget::event(), QMainWindowTabBar::event(), QMenuBar::eventFilter(), QTabBarPrivate::extraWidth(), QIconModeViewBase::filterDropEvent(), QToolBarAreaLayoutInfo::fitLayout(), QToolBarAreaLayout::fitLayout(), QMainWindowLayout::fixSizeInUnifiedToolbar(), QGLWindowSurface::flush(), QVideoSurfaceFormat::frameWidth(), QBitmap::fromData(), QGLPixmapData::fromData(), QGLPixmapData::fromFile(), generateBlurTexture(), QMdi::MinOverlapPlacer::getCandidatePlacements(), QAxServerBase::GetExtent(), QDockAreaLayout::getGrid(), QComboMenuDelegate::getStyleOption(), handleSizeAttribute(), QBBScreenEventHandler::handleTouchEvent(), QTabWidget::heightForWidth(), QWidgetItemV2::heightForWidth(), QMainWindowLayout::hover(), QListModeViewBase::indexToListViewItem(), QColorDialogPrivate::init(), QGLPixelBufferPrivate::init(), QIconModeViewBase::initBspTree(), QIconModeViewBase::initDynamicLayout(), QGLWindowSurface::initializeOffscreenTexture(), QTabBarPrivate::initStyleBaseOption(), QTabWidget::initStyleOption(), QWidgetPrivate::invalidateBuffer_resizeHelper(), QAxServerBase::Invoke(), QWidget::isEnabledToTLW(), isServerProcess(), QProgressDialogPrivate::layout(), QToolBarLayout::layoutActions(), QMessageBoxPrivate::layoutMinimumWidth(), QTabBarPrivate::layoutTabs(), QDeclarativeBorderImage::load(), QDirectFBPaintDevice::lockSurface(), make_widget_eventUPP(), make_win_eventUPP(), QShivaContext::makeCurrent(), QTransformedScreen::mapFromDevice(), QTransformedScreen::mapToDevice(), QListModeViewBase::mapToViewport(), QDockAreaLayoutInfo::maximumSize(), maybeRoundToNextPowerOfTwo(), QMenuBarPrivate::menuRect(), QGLPaintDevice::metric(), QDockAreaLayoutInfo::minimumSize(), QToolBarAreaLayout::minimumSize(), QDockAreaLayout::minimumSize(), QMainWindowLayout::minimumSize(), QMdiSubWindow::minimumSizeHint(), QMenuBar::minimumSizeHint(), QColumnViewGrip::mouseDoubleClickEvent(), QListView::moveCursor(), nearest_gl_texture_size(), QWaylandEglWindow::newSurfaceCreated(), QWaylandWindow::newSurfaceCreated(), operator<<(), operator>>(), QFontFamilyDelegate::paint(), QGtkPainter::paintBox(), QGtkPainter::paintBoxGap(), QListView::paintEvent(), QFileDialogComboBox::paintEvent(), QGraphicsWidget::paintWindowFrame(), QMacPrintEnginePrivate::paperSize(), parseGeometry(), QWSYellowSurface::permanentState(), perp(), QSplitterLayoutStruct::pick(), QSplitterPrivate::pick(), pick(), QCommonStyle::pixelMetric(), QMacStyle::pixelMetric(), QStyleSheetStyle::pixelMetric(), PixmapEntry::pixmap(), QPixmapIconEngine::pixmap(), QSvgIconEnginePrivate::pmcKey(), pmKey(), QMenu::popup(), QToolButtonPrivate::popupTimerDone(), QDateTimeEditPrivate::positionCalendarPopup(), QStyleSheetStyle::positionRect(), QGLPixmapBlurFilter::processGL(), QVideoSurfaceFormat::property(), QMacStylePrivate::pushButtonSizeFromContents(), PvrEglWindowSurface::PvrEglWindowSurface(), QBalloonTip::QBalloonTip(), QDirectFbBlitter::QDirectFbBlitter(), qDrawBorder(), qHash(), qNormalizeRadii(), QPixmap::QPixmap(), QRect::QRect(), QRollEffect::QRollEffect(), qSmartMaxSize(), qSmartMinSize(), qt_aqua_get_known_size(), qt_aqua_guess_size(), qt_defaultDpiX(), qt_format_to_attrib_list(), qt_mac_widget_in_menu_eventHandler(), QGLMaskTextureCache::quadtreeFindAvailableLocation(), QGLMaskTextureCache::quadtreeFindExistingLocation(), QVNCDirtyMap::QVNCDirtyMap(), QWaylandShmBuffer::QWaylandShmBuffer(), QWaylandXCompositeBuffer::QWaylandXCompositeBuffer(), QWorkspaceChild::QWorkspaceChild(), QXcbShmImage::QXcbShmImage(), QSvgIOHandler::read(), read_jpeg_image(), readImage(), QGraphicsViewPrivate::recalculateContentSize(), QComboBoxPrivate::recomputeSizeHint(), QToolBarAreaLayout::rectHint(), QDeclarativeBorderImage::requestFinished(), QCocoaWindowSurface::resize(), QBBRootWindow::resize(), QRubberBand::resize(), QListViewItem::resize(), QWidget::resize(), QXlibWindowSurface::resizeBuffer(), QColumnViewPreviewColumn::resizeEvent(), QListView::resizeEvent(), QWizard::resizeEvent(), QPlainTextEdit::resizeEvent(), QTextEdit::resizeEvent(), QMdiAreaPrivate::resizeToMinimumTileSize(), QAlphaWidget::run(), QPixmap::scaled(), QImage::scaled(), QmlJSDebugger::ZoomTool::scaleView(), QColumnView::scrollTo(), QHeaderView::sectionSizeFromContents(), QHeaderView::sectionSizeHint(), QPageSetupWidget::selectPrinter(), QWidget::setBaseSize(), QBlittablePixmapData::setBlittable(), QBBWindow::setBufferSize(), QHeaderView::setDefaultSectionSize(), QBoxLayout::setDirection(), QAxServerBase::SetExtent(), QWidget::setFixedSize(), QSplitterPrivate::setGeo(), QX11GLWindowSurface::setGeometry(), QX11WindowSurface::setGeometry(), QBoxLayout::setGeometry(), QWidgetItem::setGeometry(), QStyleSheetStyle::setGeometry(), QWSLocalMemSurface::setGeometry(), QWSSharedMemSurface::setGeometry(), QDeclarativeBorderImage::setGridScaledImage(), QWidget::setMaximumSize(), QWidget::setMinimumSize(), QMdiSubWindowPrivate::setNewGeometry(), QGLMaskTextureCache::setOffscreenSize(), QMacPrintEnginePrivate::setPaperSize(), QBBScreen::setRotation(), QListView::setSelection(), QRect::setSize(), QWidget::setSizeIncrement(), QTransformedScreen::setTransformation(), QGLShaderProgram::setUniformValue(), QBoxLayoutPrivate::setupGeom(), QFormLayoutPrivate::setupHorizontalLayoutData(), QFormLayoutPrivate::setupVerticalLayoutData(), QUrlModel::setUrl(), QDeclarativeSizeValueType::setValue(), QMdiSubWindowPrivate::setWindowFlags(), QDialog::showExtension(), QLabelPrivate::sizeForWidth(), QDockWidgetLayout::sizeFromContent(), QWindowsMobileStyle::sizeFromContents(), QCommonStyle::sizeFromContents(), QWindowsCEStyle::sizeFromContents(), QCleanlooksStyle::sizeFromContents(), QWindowsStyle::sizeFromContents(), QMotifStyle::sizeFromContents(), QMacStyle::sizeFromContents(), QGtkStyle::sizeFromContents(), QStyleSheetStyle::sizeFromContents(), QRadioButton::sizeHint(), QCheckBox::sizeHint(), QCommandLinkButton::sizeHint(), QPushButton::sizeHint(), QScrollArea::sizeHint(), QToolBoxButton::sizeHint(), QWorkspace::sizeHint(), QToolButton::sizeHint(), QProgressDialog::sizeHint(), QMdiArea::sizeHint(), QMenuBar::sizeHint(), QDockWidgetTitleButton::sizeHint(), QVideoSurfaceFormat::sizeHint(), QMenu::sizeHint(), QDockAreaLayoutInfo::sizeHint(), QWizard::sizeHint(), QToolBarAreaLayout::sizeHint(), QDockAreaLayout::sizeHint(), QMainWindowLayout::sizeHint(), QFileDialogTreeView::sizeHint(), QTableView::sizeHintForColumn(), QTreeView::sizeHintForColumn(), QIconModeViewBase::snapToGrid(), QWidgetBackingStore::staticContents(), QCommonStyle::subControlRect(), QWindowsVistaStyle::subControlRect(), QWindowsXPStyle::subControlRect(), QWindowsMobileStyle::subControlRect(), QWindowsCEStyle::subControlRect(), QCleanlooksStyle::subControlRect(), QMotifStyle::subControlRect(), QGtkStyle::subControlRect(), QStyleSheetStyle::subControlRect(), QCommonStyle::subElementRect(), QMacStyle::subElementRect(), QStyleSheetStyle::subElementRect(), QWaylandReadbackEglContext::swapBuffers(), QWaylandReadbackGlxContext::swapBuffers(), QDockAreaLayoutInfo::tabContentRect(), QCommonStylePrivate::tabLayout(), QTabBar::tabSizeHint(), QItemDelegatePrivate::textLayoutBounds(), QItemDelegate::textRectangle(), QWorkspace::tile(), QStyleSheetStyle::titleBarLayout(), QTest::toString(), QLayout::totalMaximumSize(), QLayout::totalMinimumSize(), QLayout::totalSizeHint(), QSplitterPrivate::trans(), QDirectFBPixmapData::transformed(), QETWidget::translateConfigEvent(), QStyleHelper::uniqueName(), uniqueName(), QMenuPrivate::updateActionRects(), ShaderEffectSource::updateBackbuffer(), QGL2PaintEngineExPrivate::updateBrushTexture(), QCalendarTextNavigator::updateDateLabel(), QStyledItemDelegate::updateEditorGeometry(), updateFormLayoutItem(), QOpenGLPaintEnginePrivate::updateFragmentProgramData(), QMenuBarPrivate::updateGeometries(), QTableView::updateGeometries(), QGLWindowSurface::updateGeometry(), ShaderEffectItem::updateGeometry(), QAxServerBase::updateGeometry(), QCommonListViewBase::updateHorizontalScrollBar(), QListModeViewBase::updateHorizontalScrollBar(), QExpandingLineEdit::updateMinimumWidth(), QWizardPrivate::updateMinMaxSizes(), ShaderEffect::updateRenderTargets(), QScrollAreaPrivate::updateScrollBars(), QColumnViewPrivate::updateScrollbars(), QTreeViewPrivate::updateScrollBars(), QMdiAreaPrivate::updateScrollBars(), QDeclarativeTextPrivate::updateSize(), QMessageBoxPrivate::updateSize(), ShaderEffectSource::updateSizeAndTexture(), QFormLayoutPrivate::updateSizes(), useScrollBar(), QSettingsPrivate::variantToString(), QCommonStylePrivate::viewItemLayout(), QCommonStylePrivate::viewItemSize(), QVideoFrame::width(), and QPdfEnginePrivate::writePage().
Multiplies the given size by the given factor, and returns the result rounded to the nearest integer.
Definition at line 168 of file qsize.h.
Divides the given size by the given divisor, and returns the result rounded to the nearest integer.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 181 of file qsize.h.
|
related |
Writes the given size to the given stream, and returns a reference to the stream.
Definition at line 461 of file qsize.cpp.
Referenced by boundedTo().
|
related |
|
private |
Definition at line 93 of file qsize.h.
Referenced by boundedTo(), expandedTo(), height(), isEmpty(), isNull(), isValid(), operator!=(), operator*(), operator*=(), operator+(), operator+=(), operator-(), operator-=(), operator/(), operator/=(), operator==(), QSize(), QSizeF::QSizeF(), rheight(), scale(), QSizeF::scale(), setHeight(), transpose(), and QSizeF::transpose().
|
private |
Definition at line 92 of file qsize.h.
Referenced by boundedTo(), expandedTo(), isEmpty(), isNull(), isValid(), operator!=(), operator*(), operator*=(), operator+(), operator+=(), operator-(), operator-=(), operator/(), operator/=(), operator==(), QSize(), QSizeF::QSizeF(), rwidth(), scale(), QSizeF::scale(), setWidth(), transpose(), QSizeF::transpose(), and width().