Struct fltk::draw::Offscreen

source ·
pub struct Offscreen { /* private fields */ }
Expand description

Opaque type around Fl_Offscreen

Implementations§

source§

impl Offscreen

source

pub fn new(w: i32, h: i32) -> Option<Offscreen>

Creates a new offscreen type

source

pub unsafe fn uninit() -> Offscreen

Creates an uninitialized offscreen type

Safety

Leaves the offscreen in an uninitialized state

source

pub fn begin(&self)

Begins drawing in the offscreen

source

pub fn end(&self)

Ends drawing in the offscreen

source

pub fn copy(&self, x: i32, y: i32, w: i32, h: i32, src_x: i32, src_y: i32)

Copies the offscreen

source

pub fn rescale(&mut self)

Rescales the offscreen

source

pub fn is_valid(&self) -> bool

Checks the validity of the offscreen

source

pub unsafe fn shallow_copy(&self) -> Offscreen

Performs a shallow copy of the offscreen

Safety

This can lead to multiple mutable references to the same offscreen

Trait Implementations§

source§

impl Debug for Offscreen

source§

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

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

impl Drop for Offscreen

source§

fn drop(&mut self)

Executes the destructor for this type. Read more
source§

impl PartialEq for Offscreen

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

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

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for Offscreen

source§

impl Send for Offscreen

Available on non-crate feature single-threaded only.
source§

impl Sync for Offscreen

Available on non-crate feature single-threaded only.

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,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. 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 Twhere 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, U> TryFrom<U> for Twhere U: Into<T>,

§

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 Twhere U: TryFrom<T>,

§

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.