Skip to main content

QLinearGradient

Struct QLinearGradient 

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

C++ class: QLinearGradient.

Implementations§

Source§

impl QLinearGradient

Source

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

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

Source

pub unsafe fn final_stop(&self) -> CppBox<QPointF>

Calls C++ function: QPointF QLinearGradient::finalStop() const.

Source

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

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

Source

pub unsafe fn new_2a( start: impl CastInto<Ref<QPointF>>, final_stop: impl CastInto<Ref<QPointF>>, ) -> CppBox<QLinearGradient>

Calls C++ function: [constructor] void QLinearGradient::QLinearGradient(const QPointF& start, const QPointF& finalStop).

Source

pub unsafe fn new_4a( x_start: c_double, y_start: c_double, x_final_stop: c_double, y_final_stop: c_double, ) -> CppBox<QLinearGradient>

Calls C++ function: [constructor] void QLinearGradient::QLinearGradient(double xStart, double yStart, double xFinalStop, double yFinalStop).

Source

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

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

Source

pub unsafe fn set_final_stop_1a(&self, stop: impl CastInto<Ref<QPointF>>)

Calls C++ function: void QLinearGradient::setFinalStop(const QPointF& stop).

Source

pub unsafe fn set_final_stop_2a(&self, x: c_double, y: c_double)

Calls C++ function: void QLinearGradient::setFinalStop(double x, double y).

Source

pub unsafe fn set_start_1a(&self, start: impl CastInto<Ref<QPointF>>)

Calls C++ function: void QLinearGradient::setStart(const QPointF& start).

Source

pub unsafe fn set_start_2a(&self, x: c_double, y: c_double)

Calls C++ function: void QLinearGradient::setStart(double x, double y).

Source

pub unsafe fn start(&self) -> CppBox<QPointF>

Calls C++ function: QPointF QLinearGradient::start() const.

Methods from Deref<Target = 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 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 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 QLinearGradient

Source§

unsafe fn delete(&self)

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

Source§

impl Deref for QLinearGradient

Source§

fn deref(&self) -> &QGradient

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

Source§

type Target = QGradient

The resulting type after dereferencing.
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 StaticUpcast<QGradient> for QLinearGradient

Source§

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

Calls C++ function: QGradient* static_cast<QGradient*>(QLinearGradient* 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<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
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.