Loading...
Searching...
No Matches
qwt_pixel_matrix.cpp
/******************************************************************************
* Qwt Widget Library
* Copyright (C) 1997 Josef Wilgen
* Copyright (C) 2002 Uwe Rathmann
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the Qwt License, Version 1.0
*****************************************************************************/
#include "qwt_pixel_matrix.h"
QwtPixelMatrix::QwtPixelMatrix( const QRect& rect )
: QBitArray( qMax( rect.width() * rect.height(), 0 ) )
, m_rect( rect )
{
}
QwtPixelMatrix::~QwtPixelMatrix()
{
}
void QwtPixelMatrix::setRect( const QRect& rect )
{
if ( rect != m_rect )
{
m_rect = rect;
const int sz = qMax( rect.width() * rect.height(), 0 );
resize( sz );
}
fill( false );
}
QRect QwtPixelMatrix::rect() const
{
return m_rect;
}
QwtPixelMatrix::~QwtPixelMatrix
~QwtPixelMatrix()
Destructor.
Definition qwt_pixel_matrix.cpp:24
QwtPixelMatrix::rect
QRect rect() const
Definition qwt_pixel_matrix.cpp:48
QwtPixelMatrix::QwtPixelMatrix
QwtPixelMatrix(const QRect &rect)
Constructor.
Definition qwt_pixel_matrix.cpp:17
QwtPixelMatrix::setRect
void setRect(const QRect &rect)
Definition qwt_pixel_matrix.cpp:35