Struct icrate::AppKit::NSEPSImageRep
source · #[repr(C)]pub struct NSEPSImageRep { /* private fields */ }AppKit and AppKit_NSEPSImageRep only.Implementations§
source§impl NSEPSImageRep
impl NSEPSImageRep
pub unsafe fn imageRepWithData(eps_data: &NSData) -> Option<Id<Self, Shared>>
Foundation_NSData only.pub unsafe fn initWithData(
this: Option<Allocated<Self>>,
eps_data: &NSData
) -> Option<Id<Self, Shared>>
Foundation_NSData only.pub unsafe fn prepareGState(&self)
pub unsafe fn EPSRepresentation(&self) -> Id<NSData, Shared>
Foundation_NSData only.pub unsafe fn boundingBox(&self) -> NSRect
Methods from Deref<Target = NSImageRep>§
pub unsafe fn draw(&self) -> bool
AppKit_NSImageRep only.pub unsafe fn drawAtPoint(&self, point: NSPoint) -> bool
AppKit_NSImageRep only.pub unsafe fn drawInRect(&self, rect: NSRect) -> bool
AppKit_NSImageRep only.pub unsafe fn drawInRect_fromRect_operation_fraction_respectFlipped_hints(
&self,
dst_space_portion_rect: NSRect,
src_space_portion_rect: NSRect,
op: NSCompositingOperation,
requested_alpha: CGFloat,
respect_context_is_flipped: bool,
hints: Option<&NSDictionary<NSImageHintKey, Object>>
) -> bool
AppKit_NSImageRep and Foundation_NSDictionary only.pub unsafe fn size(&self) -> NSSize
AppKit_NSImageRep only.pub unsafe fn setSize(&self, size: NSSize)
AppKit_NSImageRep only.pub unsafe fn hasAlpha(&self) -> bool
AppKit_NSImageRep only.pub unsafe fn setAlpha(&self, alpha: bool)
AppKit_NSImageRep only.pub unsafe fn isOpaque(&self) -> bool
AppKit_NSImageRep only.pub unsafe fn setOpaque(&self, opaque: bool)
AppKit_NSImageRep only.pub unsafe fn colorSpaceName(&self) -> Id<NSColorSpaceName, Shared>
AppKit_NSImageRep only.pub unsafe fn setColorSpaceName(&self, color_space_name: &NSColorSpaceName)
AppKit_NSImageRep only.pub unsafe fn bitsPerSample(&self) -> NSInteger
AppKit_NSImageRep only.pub unsafe fn setBitsPerSample(&self, bits_per_sample: NSInteger)
AppKit_NSImageRep only.pub unsafe fn pixelsWide(&self) -> NSInteger
AppKit_NSImageRep only.pub unsafe fn setPixelsWide(&self, pixels_wide: NSInteger)
AppKit_NSImageRep only.pub unsafe fn pixelsHigh(&self) -> NSInteger
AppKit_NSImageRep only.pub unsafe fn setPixelsHigh(&self, pixels_high: NSInteger)
AppKit_NSImageRep only.pub unsafe fn layoutDirection(&self) -> NSImageLayoutDirection
AppKit_NSImageRep only.pub unsafe fn setLayoutDirection(&self, layout_direction: NSImageLayoutDirection)
AppKit_NSImageRep only.Methods from Deref<Target = Object>§
sourcepub unsafe fn ivar_ptr<T>(&self, name: &str) -> *mut Twhere
T: Encode,
pub unsafe fn ivar_ptr<T>(&self, name: &str) -> *mut Twhere
T: Encode,
Returns a pointer to the instance variable / ivar with the given name.
This is similar to [UnsafeCell::get], see that for more information
on what is and isn’t safe to do.
Usually you will have defined the instance variable yourself with
ClassBuilder::add_ivar, the type of the ivar T must match the
type used in that.
Attempting to access or modify private implementation details of a class that you do no control using this is not supported, and may invoke undefined behaviour.
Library implementors are strongly encouraged to expose a safe interface to the ivar.
Panics
May panic if the object has no ivar with the given name. May also
panic if the type encoding of the ivar differs from the type encoding
of T.
This should purely seen as help while debugging and is not guaranteed
(e.g. it may be disabled when debug_assertions are off).
Safety
The object must have an instance variable with the given name, and it
must be of type T. Any invariants that the object have assumed about
the value of the instance variable must not be violated.
No thread syncronization is done on accesses to the variable, so you must ensure that any access to the returned pointer do not cause data races, and that Rust’s mutability rules are not otherwise violated.
sourcepub unsafe fn ivar<T>(&self, name: &str) -> &Twhere
T: Encode,
pub unsafe fn ivar<T>(&self, name: &str) -> &Twhere
T: Encode,
Returns a reference to the instance variable with the given name.
See Object::ivar_ptr for more information, including on when this
panics.
Safety
The object must have an instance variable with the given name, and it
must be of type T.
No thread syncronization is done, so you must ensure that no other
thread is concurrently mutating the variable. This requirement can be
considered upheld if all mutation happens through Object::ivar_mut
(since that takes &mut self).
sourcepub unsafe fn get_ivar<T>(&self, name: &str) -> &Twhere
T: Encode,
👎Deprecated: Use Object::ivar instead.
pub unsafe fn get_ivar<T>(&self, name: &str) -> &Twhere
T: Encode,
Object::ivar instead.sourcepub unsafe fn ivar_mut<T>(&mut self, name: &str) -> &mut Twhere
T: Encode,
pub unsafe fn ivar_mut<T>(&mut self, name: &str) -> &mut Twhere
T: Encode,
Returns a mutable reference to the ivar with the given name.
See Object::ivar_ptr for more information, including on when this
panics.
Safety
The object must have an instance variable with the given name, and it
must be of type T.
This access happens through &mut self, which means we know it to be
the only reference, hence you do not need to do any work to ensure
that data races do not happen.
sourcepub unsafe fn get_mut_ivar<T>(&mut self, name: &str) -> &mut Twhere
T: Encode,
👎Deprecated: Use Object::ivar_mut instead.
pub unsafe fn get_mut_ivar<T>(&mut self, name: &str) -> &mut Twhere
T: Encode,
Object::ivar_mut instead.sourcepub unsafe fn set_ivar<T>(&mut self, name: &str, value: T)where
T: Encode,
pub unsafe fn set_ivar<T>(&mut self, name: &str, value: T)where
T: Encode,
Sets the value of the ivar with the given name.
This is just a helpful shorthand for Object::ivar_mut, see that
for more information.
Safety
Same as Object::ivar_mut.
Trait Implementations§
source§impl AsMut<NSEPSImageRep> for NSEPSImageRep
impl AsMut<NSEPSImageRep> for NSEPSImageRep
source§impl AsMut<NSImageRep> for NSEPSImageRep
impl AsMut<NSImageRep> for NSEPSImageRep
source§fn as_mut(&mut self) -> &mut NSImageRep
fn as_mut(&mut self) -> &mut NSImageRep
source§impl AsMut<NSObject> for NSEPSImageRep
impl AsMut<NSObject> for NSEPSImageRep
source§impl AsMut<Object> for NSEPSImageRep
impl AsMut<Object> for NSEPSImageRep
source§impl AsRef<NSEPSImageRep> for NSEPSImageRep
impl AsRef<NSEPSImageRep> for NSEPSImageRep
source§impl AsRef<NSImageRep> for NSEPSImageRep
impl AsRef<NSImageRep> for NSEPSImageRep
source§fn as_ref(&self) -> &NSImageRep
fn as_ref(&self) -> &NSImageRep
source§impl AsRef<NSObject> for NSEPSImageRep
impl AsRef<NSObject> for NSEPSImageRep
source§impl AsRef<Object> for NSEPSImageRep
impl AsRef<Object> for NSEPSImageRep
source§impl Borrow<NSImageRep> for NSEPSImageRep
impl Borrow<NSImageRep> for NSEPSImageRep
source§fn borrow(&self) -> &NSImageRep
fn borrow(&self) -> &NSImageRep
source§impl Borrow<NSObject> for NSEPSImageRep
impl Borrow<NSObject> for NSEPSImageRep
source§impl Borrow<Object> for NSEPSImageRep
impl Borrow<Object> for NSEPSImageRep
source§impl BorrowMut<NSImageRep> for NSEPSImageRep
impl BorrowMut<NSImageRep> for NSEPSImageRep
source§fn borrow_mut(&mut self) -> &mut NSImageRep
fn borrow_mut(&mut self) -> &mut NSImageRep
source§impl BorrowMut<NSObject> for NSEPSImageRep
impl BorrowMut<NSObject> for NSEPSImageRep
source§fn borrow_mut(&mut self) -> &mut NSObject
fn borrow_mut(&mut self) -> &mut NSObject
source§impl BorrowMut<Object> for NSEPSImageRep
impl BorrowMut<Object> for NSEPSImageRep
source§fn borrow_mut(&mut self) -> &mut Object
fn borrow_mut(&mut self) -> &mut Object
source§impl ClassType for NSEPSImageRep
impl ClassType for NSEPSImageRep
source§impl Debug for NSEPSImageRep
impl Debug for NSEPSImageRep
source§impl Deref for NSEPSImageRep
impl Deref for NSEPSImageRep
source§impl DerefMut for NSEPSImageRep
impl DerefMut for NSEPSImageRep
source§impl Hash for NSEPSImageRep
impl Hash for NSEPSImageRep
source§impl NSCoding for NSEPSImageRep
impl NSCoding for NSEPSImageRep
source§impl NSObjectProtocol for NSEPSImageRep
impl NSObjectProtocol for NSEPSImageRep
source§impl PartialEq<NSEPSImageRep> for NSEPSImageRep
impl PartialEq<NSEPSImageRep> for NSEPSImageRep
source§fn eq(&self, other: &NSEPSImageRep) -> bool
fn eq(&self, other: &NSEPSImageRep) -> bool
self and other values to be equal, and is used
by ==.