Struct core_graphics::context::CGContextRef
source · pub struct CGContextRef(_);
Implementations
sourceimpl CGContextRef
impl CGContextRef
pub fn flush(&self)
pub fn width(&self) -> size_t
pub fn height(&self) -> size_t
pub fn bytes_per_row(&self) -> size_t
pub fn set_fill_color(&self, color: &CGColor)
pub fn set_rgb_fill_color(
&self,
red: CGFloat,
green: CGFloat,
blue: CGFloat,
alpha: CGFloat
)
pub fn set_gray_fill_color(&self, gray: CGFloat, alpha: CGFloat)
pub fn set_blend_mode(&self, blend_mode: CGBlendMode)
pub fn set_allows_font_smoothing(&self, allows_font_smoothing: bool)
pub fn set_font_smoothing_style(&self, style: i32)
pub fn set_should_smooth_fonts(&self, should_smooth_fonts: bool)
pub fn set_allows_antialiasing(&self, allows_antialiasing: bool)
pub fn set_should_antialias(&self, should_antialias: bool)
pub fn set_allows_font_subpixel_quantization(
&self,
allows_font_subpixel_quantization: bool
)
pub fn set_should_subpixel_quantize_fonts(
&self,
should_subpixel_quantize_fonts: bool
)
pub fn set_allows_font_subpixel_positioning(
&self,
allows_font_subpixel_positioning: bool
)
pub fn set_should_subpixel_position_fonts(
&self,
should_subpixel_position_fonts: bool
)
pub fn set_text_drawing_mode(&self, mode: CGTextDrawingMode)
pub fn add_path(&self, path: &CGPathRef)
pub fn close_path(&self)
pub fn fill_path(&self)
pub fn fill_rect(&self, rect: CGRect)
pub fn draw_image(&self, rect: CGRect, image: &CGImage)
pub fn create_image(&self) -> Option<CGImage>
pub fn set_font(&self, font: &CGFont)
pub fn set_font_size(&self, size: CGFloat)
pub fn set_text_matrix(&self, t: &CGAffineTransform)
pub fn show_glyphs_at_positions(&self, glyphs: &[CGGlyph], positions: &[CGPoint])
pub fn save(&self)
pub fn restore(&self)
pub fn translate(&self, tx: CGFloat, ty: CGFloat)
pub fn scale(&self, sx: CGFloat, sy: CGFloat)
Trait Implementations
sourceimpl AsRef<CGContextRef> for CGContext
impl AsRef<CGContextRef> for CGContext
sourcefn as_ref(&self) -> &CGContextRef
fn as_ref(&self) -> &CGContextRef
Converts this type into a shared reference of the (usually inferred) input type.
sourceimpl Borrow<CGContextRef> for CGContext
impl Borrow<CGContextRef> for CGContext
sourcefn borrow(&self) -> &CGContextRef
fn borrow(&self) -> &CGContextRef
Immutably borrows from an owned value. Read more
Auto Trait Implementations
impl !RefUnwindSafe for CGContextRef
impl Send for CGContextRef
impl !Sync for CGContextRef
impl Unpin for CGContextRef
impl UnwindSafe for CGContextRef
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more