[][src]Struct qt_gui::q_painter::PixmapFragment

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

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

C++ class: QPainter::PixmapFragment.

C++ documentation:

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

The sourceLeft, sourceTop, width and height variables are used as a source rectangle within the pixmap passed into the QPainter::drawPixmapFragments() function. The variables x, y, width and height are used to calculate the target rectangle that is drawn. x and y denotes the center of the target rectangle. The width and height in the target rectangle is scaled by the scaleX and scaleY values. The resulting target rectangle is then rotated rotation degrees around the x, y center point.

Methods

impl PixmapFragment[src]

pub unsafe fn copy_from(
    &mut self,
    other: impl CastInto<Ref<PixmapFragment>>
) -> MutRef<PixmapFragment>
[src]

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

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

C++ documentation:

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

The sourceLeft, sourceTop, width and height variables are used as a source rectangle within the pixmap passed into the QPainter::drawPixmapFragments() function. The variables x, y, width and height are used to calculate the target rectangle that is drawn. x and y denotes the center of the target rectangle. The width and height in the target rectangle is scaled by the scaleX and scaleY values. The resulting target rectangle is then rotated rotation degrees around the x, y center point.

pub unsafe fn create_6a(
    pos: impl CastInto<Ref<QPointF>>,
    source_rect: impl CastInto<Ref<QRectF>>,
    scale_x: c_double,
    scale_y: c_double,
    rotation: c_double,
    opacity: c_double
) -> CppBox<PixmapFragment>
[src]

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

Calls C++ function: static QPainter::PixmapFragment QPainter::PixmapFragment::create(const QPointF& pos, const QRectF& sourceRect, double scaleX = …, double scaleY = …, double rotation = …, double opacity = …).

C++ documentation:

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

This function was introduced in Qt 4.7.

pub unsafe fn create_5a(
    pos: impl CastInto<Ref<QPointF>>,
    source_rect: impl CastInto<Ref<QRectF>>,
    scale_x: c_double,
    scale_y: c_double,
    rotation: c_double
) -> CppBox<PixmapFragment>
[src]

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

Calls C++ function: static QPainter::PixmapFragment QPainter::PixmapFragment::create(const QPointF& pos, const QRectF& sourceRect, double scaleX = …, double scaleY = …, double rotation = …).

C++ documentation:

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

This function was introduced in Qt 4.7.

pub unsafe fn create_4a(
    pos: impl CastInto<Ref<QPointF>>,
    source_rect: impl CastInto<Ref<QRectF>>,
    scale_x: c_double,
    scale_y: c_double
) -> CppBox<PixmapFragment>
[src]

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

Calls C++ function: static QPainter::PixmapFragment QPainter::PixmapFragment::create(const QPointF& pos, const QRectF& sourceRect, double scaleX = …, double scaleY = …).

C++ documentation:

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

This function was introduced in Qt 4.7.

pub unsafe fn create_3a(
    pos: impl CastInto<Ref<QPointF>>,
    source_rect: impl CastInto<Ref<QRectF>>,
    scale_x: c_double
) -> CppBox<PixmapFragment>
[src]

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

Calls C++ function: static QPainter::PixmapFragment QPainter::PixmapFragment::create(const QPointF& pos, const QRectF& sourceRect, double scaleX = …).

C++ documentation:

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

This function was introduced in Qt 4.7.

pub unsafe fn create_2a(
    pos: impl CastInto<Ref<QPointF>>,
    source_rect: impl CastInto<Ref<QRectF>>
) -> CppBox<PixmapFragment>
[src]

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

Calls C++ function: static QPainter::PixmapFragment QPainter::PixmapFragment::create(const QPointF& pos, const QRectF& sourceRect).

C++ documentation:

This is a convenience function that returns a QPainter::PixmapFragment that is initialized with the pos, sourceRect, scaleX, scaleY, rotation, opacity parameters.

This function was introduced in Qt 4.7.

pub unsafe fn height(&self) -> c_double[src]

Returns the value of the height field.

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

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

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

C++ documentation:

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

The sourceLeft, sourceTop, width and height variables are used as a source rectangle within the pixmap passed into the QPainter::drawPixmapFragments() function. The variables x, y, width and height are used to calculate the target rectangle that is drawn. x and y denotes the center of the target rectangle. The width and height in the target rectangle is scaled by the scaleX and scaleY values. The resulting target rectangle is then rotated rotation degrees around the x, y center point.

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

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

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

C++ documentation:

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

The sourceLeft, sourceTop, width and height variables are used as a source rectangle within the pixmap passed into the QPainter::drawPixmapFragments() function. The variables x, y, width and height are used to calculate the target rectangle that is drawn. x and y denotes the center of the target rectangle. The width and height in the target rectangle is scaled by the scaleX and scaleY values. The resulting target rectangle is then rotated rotation degrees around the x, y center point.

pub unsafe fn opacity(&self) -> c_double[src]

Returns the value of the opacity field.

pub unsafe fn rotation(&self) -> c_double[src]

Returns the value of the rotation field.

pub unsafe fn scale_x(&self) -> c_double[src]

Returns the value of the scaleX field.

pub unsafe fn scale_y(&self) -> c_double[src]

Returns the value of the scaleY field.

pub unsafe fn set_height(&mut self, value: c_double)[src]

Sets the value of the height field.

pub unsafe fn set_opacity(&mut self, value: c_double)[src]

Sets the value of the opacity field.

pub unsafe fn set_rotation(&mut self, value: c_double)[src]

Sets the value of the rotation field.

pub unsafe fn set_scale_x(&mut self, value: c_double)[src]

Sets the value of the scaleX field.

pub unsafe fn set_scale_y(&mut self, value: c_double)[src]

Sets the value of the scaleY field.

pub unsafe fn set_source_left(&mut self, value: c_double)[src]

Sets the value of the sourceLeft field.

pub unsafe fn set_source_top(&mut self, value: c_double)[src]

Sets the value of the sourceTop field.

pub unsafe fn set_width(&mut self, value: c_double)[src]

Sets the value of the width field.

pub unsafe fn set_x(&mut self, value: c_double)[src]

Sets the value of the x field.

pub unsafe fn set_y(&mut self, value: c_double)[src]

Sets the value of the y field.

pub unsafe fn source_left(&self) -> c_double[src]

Returns the value of the sourceLeft field.

pub unsafe fn source_top(&self) -> c_double[src]

Returns the value of the sourceTop field.

pub unsafe fn width(&self) -> c_double[src]

Returns the value of the width field.

pub unsafe fn x(&self) -> c_double[src]

Returns the value of the x field.

pub unsafe fn y(&self) -> c_double[src]

Returns the value of the y field.

Trait Implementations

impl CppDeletable for PixmapFragment[src]

unsafe fn delete(&mut self)[src]

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

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

C++ documentation:

This class is used in conjunction with the QPainter::drawPixmapFragments() function to specify how a pixmap, or sub-rect of a pixmap, is drawn.

The sourceLeft, sourceTop, width and height variables are used as a source rectangle within the pixmap passed into the QPainter::drawPixmapFragments() function. The variables x, y, width and height are used to calculate the target rectangle that is drawn. x and y denotes the center of the target rectangle. The width and height in the target rectangle is scaled by the scaleX and scaleY values. The resulting target rectangle is then rotated rotation degrees around the x, y center point.

Auto Trait Implementations

Blanket Implementations

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

impl<T> From<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.

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

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

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

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

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