Skip to main content

QGradient

Struct QGradient 

Source
pub struct QGradient { /* private fields */ }
Expand description

C++ class: QGradient.

Implementations§

Source§

impl QGradient

Source

pub unsafe fn coordinate_mode(&self) -> CoordinateMode

Calls C++ function: QGradient::CoordinateMode QGradient::coordinateMode() const.

Source

pub unsafe fn copy_from( &self, other: impl CastInto<Ref<QGradient>>, ) -> Ref<QGradient>

Calls C++ function: QGradient& QGradient::operator=(const QGradient& other).

Source

pub unsafe fn interpolation_mode(&self) -> InterpolationMode

Calls C++ function: QGradient::InterpolationMode QGradient::interpolationMode() const.

Source

pub unsafe fn new_0a() -> CppBox<QGradient>

Calls C++ function: [constructor] void QGradient::QGradient().

Source

pub unsafe fn new_1a(arg1: Preset) -> CppBox<QGradient>

Calls C++ function: [constructor] void QGradient::QGradient(QGradient::Preset arg1).

Source

pub unsafe fn new_copy( other: impl CastInto<Ref<QGradient>>, ) -> CppBox<QGradient>

Calls C++ function: [constructor] void QGradient::QGradient(const QGradient& other).

Source

pub unsafe fn set_color_at( &self, pos: c_double, color: impl CastInto<Ref<QColor>>, )

Calls C++ function: void QGradient::setColorAt(double pos, const QColor& color).

Source

pub unsafe fn set_coordinate_mode(&self, mode: CoordinateMode)

Calls C++ function: void QGradient::setCoordinateMode(QGradient::CoordinateMode mode).

Source

pub unsafe fn set_interpolation_mode(&self, mode: InterpolationMode)

Calls C++ function: void QGradient::setInterpolationMode(QGradient::InterpolationMode mode).

Source

pub unsafe fn set_spread(&self, spread: Spread)

Calls C++ function: void QGradient::setSpread(QGradient::Spread spread).

Source

pub unsafe fn set_stops( &self, stops: impl CastInto<Ref<QVectorOfQPairOfDoubleQColor>>, )

Calls C++ function: void QGradient::setStops(const QVector<QPair<double, QColor>>& stops).

Source

pub unsafe fn spread(&self) -> Spread

Calls C++ function: QGradient::Spread QGradient::spread() const.

Source

pub unsafe fn static_meta_object() -> Ref<QMetaObject>

Returns a reference to the staticMetaObject field.

Source

pub unsafe fn stops(&self) -> CppBox<QVectorOfQPairOfDoubleQColor>

Calls C++ function: QVector<QPair<double, QColor>> QGradient::stops() const.

Source

pub unsafe fn type_(&self) -> Type

Calls C++ function: QGradient::Type QGradient::type() const.

Trait Implementations§

Source§

impl CppDeletable for QGradient

Source§

unsafe fn delete(&self)

Calls C++ function: [destructor] void QGradient::~QGradient().

Source§

impl PartialEq<Ref<QGradient>> for QGradient

Source§

fn eq(&self, gradient: &Ref<QGradient>) -> bool

Calls C++ function: bool QGradient::operator==(const QGradient& gradient) const.

1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StaticDowncast<QConicalGradient> for QGradient

Source§

unsafe fn static_downcast(ptr: Ptr<QGradient>) -> Ptr<QConicalGradient>

Calls C++ function: QConicalGradient* static_cast<QConicalGradient*>(QGradient* ptr).

Source§

impl StaticDowncast<QLinearGradient> for QGradient

Source§

unsafe fn static_downcast(ptr: Ptr<QGradient>) -> Ptr<QLinearGradient>

Calls C++ function: QLinearGradient* static_cast<QLinearGradient*>(QGradient* ptr).

Source§

impl StaticDowncast<QRadialGradient> for QGradient

Source§

unsafe fn static_downcast(ptr: Ptr<QGradient>) -> Ptr<QRadialGradient>

Calls C++ function: QRadialGradient* static_cast<QRadialGradient*>(QGradient* ptr).

Source§

impl StaticUpcast<QGradient> for QConicalGradient

Source§

unsafe fn static_upcast(ptr: Ptr<QConicalGradient>) -> Ptr<QGradient>

Calls C++ function: QGradient* static_cast<QGradient*>(QConicalGradient* ptr).

Source§

impl StaticUpcast<QGradient> for QLinearGradient

Source§

unsafe fn static_upcast(ptr: Ptr<QLinearGradient>) -> Ptr<QGradient>

Calls C++ function: QGradient* static_cast<QGradient*>(QLinearGradient* ptr).

Source§

impl StaticUpcast<QGradient> for QRadialGradient

Source§

unsafe fn static_upcast(ptr: Ptr<QRadialGradient>) -> Ptr<QGradient>

Calls C++ function: QGradient* static_cast<QGradient*>(QRadialGradient* ptr).

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T, U> CastInto<U> for T
where U: CastFrom<T>,

Source§

unsafe fn cast_into(self) -> U

Performs the conversion. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> StaticUpcast<T> for T

Source§

unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>

Convert type of a const pointer. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.