[][src]Struct qt_gui::QRgba64

#[repr(C)]pub struct QRgba64 { /* fields omitted */ }

The QRgba64 struct contains a 64-bit RGB color.

C++ class: QRgba64.

C++ documentation:

The QRgba64 struct contains a 64-bit RGB color.

QRgba64 is a 64-bit data-structure containing four 16-bit color channels: Red, green, blue and alpha.

QRgba64 can be used a replacement for QRgb when higher precision is needed. In particular a premultiplied QRgba64 can operate on unpremultiplied QRgb without loss of precision except for alpha 0.

Methods

impl QRgba64[src]

pub unsafe fn alpha(&self) -> u16[src]

Returns the 16-bit alpha channel.

Calls C++ function: quint16 QRgba64::alpha() const.

C++ documentation:

Returns the 16-bit alpha channel.

See also setAlpha().

pub unsafe fn alpha8(&self) -> u8[src]

Returns the alpha channel as an 8-bit.

Calls C++ function: quint8 QRgba64::alpha8() const.

C++ documentation:

Returns the alpha channel as an 8-bit.

pub unsafe fn blue(&self) -> u16[src]

Returns the 16-bit blue color component.

Calls C++ function: quint16 QRgba64::blue() const.

C++ documentation:

Returns the 16-bit blue color component.

See also setBlue().

pub unsafe fn blue8(&self) -> u8[src]

Returns the blue color component as an 8-bit.

Calls C++ function: quint8 QRgba64::blue8() const.

C++ documentation:

Returns the blue color component as an 8-bit.

pub unsafe fn copy_from_u64(&self, rgba: u64) -> CppBox<QRgba64>[src]

Assigns the value rgba to this instance of QRgba64 and returns it.

Calls C++ function: QRgba64 QRgba64::operator=(quint64 _rgba).

C++ documentation:

Assigns the value rgba to this instance of QRgba64 and returns it.

pub unsafe fn copy_from_q_rgba64(
    &self,
    other: impl CastInto<Ref<QRgba64>>
) -> Ref<QRgba64>
[src]

The QRgba64 struct contains a 64-bit RGB color.

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

C++ documentation:

The QRgba64 struct contains a 64-bit RGB color.

QRgba64 is a 64-bit data-structure containing four 16-bit color channels: Red, green, blue and alpha.

QRgba64 can be used a replacement for QRgb when higher precision is needed. In particular a premultiplied QRgba64 can operate on unpremultiplied QRgb without loss of precision except for alpha 0.

pub unsafe fn from_argb32(rgb: c_uint) -> CppBox<QRgba64>[src]

Constructs a QRgba64 value from the 32bit ARGB value rgb.

Calls C++ function: static QRgba64 QRgba64::fromArgb32(unsigned int rgb).

C++ documentation:

Constructs a QRgba64 value from the 32bit ARGB value rgb.

See also fromRgba().

pub unsafe fn from_rgba(
    red: u8,
    green: u8,
    blue: u8,
    alpha: u8
) -> CppBox<QRgba64>
[src]

Constructs a QRgba64 value from the four 8-bit color channels red, green, blue and alpha.

Calls C++ function: static QRgba64 QRgba64::fromRgba(quint8 red, quint8 green, quint8 blue, quint8 alpha).

C++ documentation:

Constructs a QRgba64 value from the four 8-bit color channels red, green, blue and alpha.

See also fromArgb32().

pub unsafe fn from_rgba64_1a(c: u64) -> CppBox<QRgba64>[src]

Returns c as a QRgba64 struct.

Calls C++ function: static QRgba64 QRgba64::fromRgba64(quint64 c).

C++ documentation:

Returns c as a QRgba64 struct.

See also fromArgb32().

pub unsafe fn from_rgba64_4a(
    red: u16,
    green: u16,
    blue: u16,
    alpha: u16
) -> CppBox<QRgba64>
[src]

Returns the QRgba64 quadruplet (r, g, b, a).

Calls C++ function: static QRgba64 QRgba64::fromRgba64(quint16 red, quint16 green, quint16 blue, quint16 alpha).

C++ documentation:

Returns the QRgba64 quadruplet (r, g, b, a).

See also fromRgba().

pub unsafe fn green(&self) -> u16[src]

Returns the 16-bit green color component.

Calls C++ function: quint16 QRgba64::green() const.

C++ documentation:

Returns the 16-bit green color component.

See also setGreen().

pub unsafe fn green8(&self) -> u8[src]

Returns the green color component as an 8-bit.

Calls C++ function: quint8 QRgba64::green8() const.

C++ documentation:

Returns the green color component as an 8-bit.

pub unsafe fn is_opaque(&self) -> bool[src]

Returns whether the color is fully opaque.

Calls C++ function: bool QRgba64::isOpaque() const.

C++ documentation:

Returns whether the color is fully opaque.

See also isTransparent() and alpha().

pub unsafe fn is_transparent(&self) -> bool[src]

Returns whether the color is transparent.

Calls C++ function: bool QRgba64::isTransparent() const.

C++ documentation:

Returns whether the color is transparent.

See also isOpaque() and alpha().

pub unsafe fn new() -> CppBox<QRgba64>[src]

Default constructs an instance of QRgba64.

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

C++ documentation:

Default constructs an instance of QRgba64.

pub unsafe fn new_copy(other: impl CastInto<Ref<QRgba64>>) -> CppBox<QRgba64>[src]

The QRgba64 struct contains a 64-bit RGB color.

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

C++ documentation:

The QRgba64 struct contains a 64-bit RGB color.

QRgba64 is a 64-bit data-structure containing four 16-bit color channels: Red, green, blue and alpha.

QRgba64 can be used a replacement for QRgb when higher precision is needed. In particular a premultiplied QRgba64 can operate on unpremultiplied QRgb without loss of precision except for alpha 0.

pub unsafe fn premultiplied(&self) -> CppBox<QRgba64>[src]

Returns the color with the alpha premultiplied.

Calls C++ function: QRgba64 QRgba64::premultiplied() const.

C++ documentation:

Returns the color with the alpha premultiplied.

See also unpremultiplied().

pub unsafe fn red(&self) -> u16[src]

Returns the 16-bit red color component.

Calls C++ function: quint16 QRgba64::red() const.

C++ documentation:

Returns the 16-bit red color component.

See also setRed().

pub unsafe fn red8(&self) -> u8[src]

Returns the red color component as an 8-bit.

Calls C++ function: quint8 QRgba64::red8() const.

C++ documentation:

Returns the red color component as an 8-bit.

pub unsafe fn set_alpha(&self, alpha: u16)[src]

Sets the alpha of this color to alpha.

Calls C++ function: void QRgba64::setAlpha(quint16 _alpha).

C++ documentation:

Sets the alpha of this color to alpha.

See also alpha().

pub unsafe fn set_blue(&self, blue: u16)[src]

Sets the blue color component of this color to blue.

Calls C++ function: void QRgba64::setBlue(quint16 _blue).

C++ documentation:

Sets the blue color component of this color to blue.

See also blue().

pub unsafe fn set_green(&self, green: u16)[src]

Sets the green color component of this color to green.

Calls C++ function: void QRgba64::setGreen(quint16 _green).

C++ documentation:

Sets the green color component of this color to green.

See also green().

pub unsafe fn set_red(&self, red: u16)[src]

Sets the red color component of this color to red.

Calls C++ function: void QRgba64::setRed(quint16 _red).

C++ documentation:

Sets the red color component of this color to red.

See also red().

pub unsafe fn to_argb32(&self) -> c_uint[src]

Returns the color as a 32-bit ARGB value.

Calls C++ function: unsigned int QRgba64::toArgb32() const.

C++ documentation:

Returns the color as a 32-bit ARGB value.

See also fromArgb32().

pub unsafe fn to_rgb16(&self) -> c_ushort[src]

Returns the color as a 16-bit RGB value.

Calls C++ function: unsigned short QRgba64::toRgb16() const.

C++ documentation:

Returns the color as a 16-bit RGB value.

See also toArgb32().

pub unsafe fn to_u64(&self) -> u64[src]

Returns the color as a 64bit unsigned integer

Calls C++ function: quint64 QRgba64::operator quint64() const.

C++ documentation:

Returns the color as a 64bit unsigned integer

pub unsafe fn unpremultiplied(&self) -> CppBox<QRgba64>[src]

Returns the color with the alpha unpremultiplied.

Calls C++ function: QRgba64 QRgba64::unpremultiplied() const.

C++ documentation:

Returns the color with the alpha unpremultiplied.

See also premultiplied().

Trait Implementations

impl CppDeletable for QRgba64[src]

unsafe fn delete(&self)[src]

The QRgba64 struct contains a 64-bit RGB color.

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

C++ documentation:

The QRgba64 struct contains a 64-bit RGB color.

QRgba64 is a 64-bit data-structure containing four 16-bit color channels: Red, green, blue and alpha.

QRgba64 can be used a replacement for QRgb when higher precision is needed. In particular a premultiplied QRgba64 can operate on unpremultiplied QRgb without loss of precision except for alpha 0.

Auto Trait Implementations

impl RefUnwindSafe for QRgba64

impl Send for QRgba64

impl Sync for QRgba64

impl Unpin for QRgba64

impl UnwindSafe for QRgba64

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T, U> CastInto<U> for T where
    U: CastFrom<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> StaticUpcast<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.