Struct jiao_qt::painter::Painter

source ·
pub struct Painter { /* private fields */ }

Implementations§

source§

impl Painter

source

pub fn new() -> Self

source

pub fn painter(&mut self) -> &CppBox<QPainter>

source

pub fn set_default_hints(&mut self)

Trait Implementations§

source§

impl Debug for Painter

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for Painter

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl PainterTrait for Painter

source§

fn save(&mut self)

Makes a copy of current state of canvas and saves it on an internal stack.
source§

fn restore(&mut self)

Restores to the state saved by a preceding call to Self::save and removes that state from internal stack.
source§

fn clear_all(&mut self)

source§

fn clip(&mut self)

Turns the current path into the current clipping region.
source§

fn fill(&mut self, path: &dyn PathTrait)

Fills the path with the current fill style.
source§

fn stroke(&mut self, path: &dyn PathTrait)

Strokes (outlines) the path with the current stoke style.
source§

fn rotate(&mut self, angle: f64)

Add a rotation to the transformation matrix.
source§

fn scale(&mut self, sx: f64, sy: f64)

Add a scaling transformation to the canvas units horizontally and/or vertically.
source§

fn translate(&mut self, point: PointF)

Add a translation transformation to the current matrix.
source§

fn draw_text(&mut self, text: &str, position: PointF)

Draw text at specific position.

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

const: unstable · source§

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

Mutably borrows from an owned value. Read more
source§

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

source§

unsafe fn cast_into(self) -> U

Performs the conversion. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

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

const: unstable · 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 Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.
source§

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

§

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

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.