QGraphicsDropShadowEffect Class Reference
|
|
QGraphicsDropShadowEffect ( QObject * parent = 0 ) | |
~QGraphicsDropShadowEffect () | |
qreal | blurRadius () const |
QColor | color () const |
QPointF | offset () const |
qreal | xOffset () const |
qreal | yOffset () const |
virtual QRectF | boundingRectFor ( const QRectF & rect ) const |
void | setBlurRadius ( qreal blurRadius ) |
void | setColor ( const QColor & color ) |
void | setOffset ( const QPointF & ofs ) |
void | setOffset ( qreal dx, qreal dy ) |
void | setOffset ( qreal d ) |
void | setXOffset ( qreal dx ) |
void | setYOffset ( qreal dy ) |
void | blurRadiusChanged ( qreal blurRadius ) |
void | colorChanged ( const QColor & color ) |
void | offsetChanged ( const QPointF & offset ) |
virtual void | draw ( QPainter * painter ) |
The QGraphicsDropShadowEffect class provides a drop shadow effect.
A drop shadow effect renders the source with a drop shadow. The color of the drop shadow can be modified using the setColor() function. The drop shadow offset can be modified using the setOffset() function and the blur radius of the drop shadow can be changed with the setBlurRadius() function.
By default, the drop shadow is a semi-transparent dark gray (QColor(63, 63, 63, 180)) shadow, blurred with a radius of 1 at an offset of 8 pixels towards the lower right. The drop shadow offset is specified in device coordinates.
See also QGraphicsBlurEffect, QGraphicsColorizeEffect, and QGraphicsOpacityEffect.
This property holds the blur radius in pixels of the drop shadow.
Using a smaller radius results in a sharper shadow, whereas using a bigger radius results in a more blurred shadow.
By default, the blur radius is 1 pixel.
Функции доступа:
qreal | blurRadius () const |
void | setBlurRadius ( qreal blurRadius ) |
Уведомляющий сигнал:
void | blurRadiusChanged ( qreal blurRadius ) |
See also color(), offset(), and ..
This property holds the color of the drop shadow.
By default, the drop color is a semi-transparent dark gray (QColor(63, 63, 63, 180)).
Функции доступа:
QColor | color () const |
void | setColor ( const QColor & color ) |
Уведомляющий сигнал:
void | colorChanged ( const QColor & color ) |
See also offset() and blurRadius().
This property holds the shadow offset in pixels.
By default, the offset is 8 pixels towards the lower right.
The offset is given in device coordinates, which means it is unaffected by scale.
Функции доступа:
QPointF | offset () const |
void | setOffset ( const QPointF & ofs ) |
void | setOffset ( qreal dx, qreal dy ) |
void | setOffset ( qreal d ) |
Уведомляющий сигнал:
void | offsetChanged ( const QPointF & offset ) |
See also xOffset(), yOffset(), blurRadius(), and color().
This property holds the horizontal shadow offset in pixels.
By default, the horizontal shadow offset is 8 pixels.
Функции доступа:
qreal | xOffset () const |
void | setXOffset ( qreal dx ) |
Уведомляющий сигнал:
void | offsetChanged ( const QPointF & offset ) |
See also yOffset() and offset().
This property holds the vertical shadow offset in pixels.
By default, the vertical shadow offset is 8 pixels.
Функции доступа:
qreal | yOffset () const |
void | setYOffset ( qreal dy ) |
Уведомляющий сигнал:
void | offsetChanged ( const QPointF & offset ) |
See also xOffset() and offset().
Constructs a new QGraphicsDropShadowEffect instance. The parent parameter is passed to QGraphicsEffect's constructor.
Destroys the effect.
This signal is emitted whenever the effect's blur radius changes. The blurRadius parameter holds the effect's new blur radius.
Reimplemented from QGraphicsEffect::boundingRectFor().
This signal is emitted whenever the effect's color changes. The color parameter holds the effect's new color.
Reimplemented from QGraphicsEffect::draw().
This signal is emitted whenever the effect's shadow offset changes. The offset parameter holds the effect's new shadow offset.
Авторские права © 2010 Nokia Corporation и/или её дочерние компании | Торговые марки | Qt 4.6.4 |
Попытка перевода Qt документации. Если есть желание присоединиться, или если есть замечания или пожелания, то заходите на форум: Перевод Qt документации на русский язык... Люди внесшие вклад в перевод: Команда переводчиков |