[−][src]Struct nanachi::context::Context
Fields
image: I
flatten_tolerance: f64
antialiasing: bool
join: Join
cap: Cap
matrix: Matrix2d
Implementations
impl<P, B, I, R> Context<P, B, I, R> where
P: Pixel,
B: Buffer<P>,
I: BorrowMut<B>,
R: BorrowMut<RasterizeBuffer>,
[src]
P: Pixel,
B: Buffer<P>,
I: BorrowMut<B>,
R: BorrowMut<RasterizeBuffer>,
pub fn low_quality(self) -> Context<P, B, I, R>
[src]
Set to low quality.
pub fn high_quality(self) -> Context<P, B, I, R>
[src]
Set to high quality.
pub fn fill<FC: FillColor<P>, C: Compositor<P>, FR: FillRule>(
&mut self,
path: &Path,
fill_style: &FillStyle<P, FC, C, FR>
)
[src]
&mut self,
path: &Path,
fill_style: &FillStyle<P, FC, C, FR>
)
Fill the path with specified FillStyle
.
pub fn stroke<FC: FillColor<P>, C: Compositor<P>, FR: FillRule>(
&mut self,
path: &Path,
fill_style: &FillStyle<P, FC, C, FR>,
width: f64
)
[src]
&mut self,
path: &Path,
fill_style: &FillStyle<P, FC, C, FR>,
width: f64
)
Draw stroke of the path with specified FillStyle
.
pub fn stroke_with_style<FC: FillColor<P>, C: Compositor<P>, FR: FillRule>(
&mut self,
path: &Path,
fill_style: &FillStyle<P, FC, C, FR>,
width: f64,
join: &Join,
cap: &Cap
)
[src]
&mut self,
path: &Path,
fill_style: &FillStyle<P, FC, C, FR>,
width: f64,
join: &Join,
cap: &Cap
)
pub fn clear<FC: FillColor<P>>(&mut self, fill_color: &FC)
[src]
Clear buffer entirely with specified FillColor
impl<'a, P> Context<P, GenericBuffer<P>, GenericBuffer<P>, RasterizeBuffer> where
P: Pixel,
[src]
P: Pixel,
pub fn from_pixel(width: u32, height: u32, pixel: P) -> Self
[src]
Create Context
with a GenericBuffer
.
impl<'a, P, B> Context<P, B, &'a mut B, RasterizeBuffer> where
P: Pixel,
B: Buffer<P>,
[src]
P: Pixel,
B: Buffer<P>,
pub fn from_image(image: &'a mut B) -> Self
[src]
impl<'a, P, B, I, R> Context<P, B, I, R> where
P: Pixel,
B: Buffer<P>,
I: BorrowMut<B>,
R: BorrowMut<RasterizeBuffer>,
[src]
P: Pixel,
B: Buffer<P>,
I: BorrowMut<B>,
R: BorrowMut<RasterizeBuffer>,
pub fn child<'b>(&'b mut self) -> ChildContext<'b, P, B>
[src]
Create child Context
.
pub fn transformed_context<'b>(
&'b mut self,
matrix: &Matrix2d
) -> ChildContext<'b, P, B>
[src]
&'b mut self,
matrix: &Matrix2d
) -> ChildContext<'b, P, B>
Create child Context
and transform.
Auto Trait Implementations
impl<P, B, I, R> RefUnwindSafe for Context<P, B, I, R> where
B: RefUnwindSafe,
I: RefUnwindSafe,
P: RefUnwindSafe,
R: RefUnwindSafe,
B: RefUnwindSafe,
I: RefUnwindSafe,
P: RefUnwindSafe,
R: RefUnwindSafe,
impl<P, B, I, R> Send for Context<P, B, I, R> where
B: Send,
I: Send,
P: Send,
R: Send,
B: Send,
I: Send,
P: Send,
R: Send,
impl<P, B, I, R> Sync for Context<P, B, I, R> where
B: Sync,
I: Sync,
P: Sync,
R: Sync,
B: Sync,
I: Sync,
P: Sync,
R: Sync,
impl<P, B, I, R> Unpin for Context<P, B, I, R> where
B: Unpin,
I: Unpin,
P: Unpin,
R: Unpin,
B: Unpin,
I: Unpin,
P: Unpin,
R: Unpin,
impl<P, B, I, R> UnwindSafe for Context<P, B, I, R> where
B: UnwindSafe,
I: UnwindSafe,
P: UnwindSafe,
R: UnwindSafe,
B: UnwindSafe,
I: UnwindSafe,
P: UnwindSafe,
R: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> SetParameter for T
pub fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
T: Parameter<Self>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,