6.0.0-rc4Source

QConicalGradient Class

The QConicalGradient class changes color around a center. More…

Header#include <QConicalGradient>
CMaketarget_link_libraries(app PRIVATE Nt::Gui)
ModuleNt GUI C++ Classes
InheritsQGradient

List of all members, including inherited members

Public Functions

QConicalGradient()
QConicalGradient(const QPointF &center, qreal angle)
QConicalGradient(qreal cx, qreal cy, qreal angle)
QPointFcenter() const
voidsetCenter(const QPointF &center)
voidsetCenter(qreal x, qreal y)
qrealangle() const
voidsetAngle(qreal angle)

Detailed Description

The colors go counterclockwise around center(), starting at angle() degrees from 3 o'clock.

See also QGradient.

Differences from Qt

See QGradient.

Member Function Documentation

QConicalGradient::QConicalGradient()

Constructs a gradient at (0, 0) starting at 0 degrees.

QConicalGradient::QConicalGradient(const QPointF &center, qreal angle)

Constructs a gradient around center starting at angle degrees.

QConicalGradient::QConicalGradient(qreal cx, qreal cy, qreal angle)

Constructs a gradient around (cx, cy) starting at angle degrees.

qreal QConicalGradient::angle() const

Returns the angle where the gradient starts, in degrees counterclockwise from 3 o'clock.

QPointF QConicalGradient::center() const

Returns the center.

void QConicalGradient::setAngle(qreal angle)

Sets the angle where the gradient starts to angle degrees.

void QConicalGradient::setCenter(const QPointF &center)

Sets the center to center.

void QConicalGradient::setCenter(qreal x, qreal y)

This is an overloaded function.

Sets the center to (x, y).