pub unsafe trait NSTextAttachmentLayout: NSObjectProtocol {
// Provided methods
unsafe fn imageForBounds_attributes_location_textContainer(
&self,
bounds: CGRect,
attributes: &NSDictionary<NSAttributedStringKey, AnyObject>,
location: &ProtocolObject<dyn NSTextLocation>,
text_container: Option<&NSTextContainer>,
) -> Option<Retained<NSImage>>
where Self: Sized + Message { ... }
unsafe fn attachmentBoundsForAttributes_location_textContainer_proposedLineFragment_position(
&self,
attributes: &NSDictionary<NSAttributedStringKey, AnyObject>,
location: &ProtocolObject<dyn NSTextLocation>,
text_container: Option<&NSTextContainer>,
proposed_line_fragment: CGRect,
position: CGPoint,
) -> CGRect
where Self: Sized + Message { ... }
fn viewProviderForParentView_location_textContainer(
&self,
parent_view: Option<&NSView>,
location: &ProtocolObject<dyn NSTextLocation>,
text_container: Option<&NSTextContainer>,
) -> Option<Retained<NSTextAttachmentViewProvider>>
where Self: Sized + Message { ... }
}Available on crate feature
NSTextAttachment only.Expand description
Provided Methods§
Sourceunsafe fn imageForBounds_attributes_location_textContainer(
&self,
bounds: CGRect,
attributes: &NSDictionary<NSAttributedStringKey, AnyObject>,
location: &ProtocolObject<dyn NSTextLocation>,
text_container: Option<&NSTextContainer>,
) -> Option<Retained<NSImage>>
Available on crate features NSImage and NSTextContainer and NSTextRange and objc2-core-foundation only.
unsafe fn imageForBounds_attributes_location_textContainer( &self, bounds: CGRect, attributes: &NSDictionary<NSAttributedStringKey, AnyObject>, location: &ProtocolObject<dyn NSTextLocation>, text_container: Option<&NSTextContainer>, ) -> Option<Retained<NSImage>>
NSImage and NSTextContainer and NSTextRange and objc2-core-foundation only.§Safety
attributes generic should be of the correct type.
Sourceunsafe fn attachmentBoundsForAttributes_location_textContainer_proposedLineFragment_position(
&self,
attributes: &NSDictionary<NSAttributedStringKey, AnyObject>,
location: &ProtocolObject<dyn NSTextLocation>,
text_container: Option<&NSTextContainer>,
proposed_line_fragment: CGRect,
position: CGPoint,
) -> CGRect
Available on crate features NSTextContainer and NSTextRange and objc2-core-foundation only.
unsafe fn attachmentBoundsForAttributes_location_textContainer_proposedLineFragment_position( &self, attributes: &NSDictionary<NSAttributedStringKey, AnyObject>, location: &ProtocolObject<dyn NSTextLocation>, text_container: Option<&NSTextContainer>, proposed_line_fragment: CGRect, position: CGPoint, ) -> CGRect
NSTextContainer and NSTextRange and objc2-core-foundation only.§Safety
attributes generic should be of the correct type.
fn viewProviderForParentView_location_textContainer( &self, parent_view: Option<&NSView>, location: &ProtocolObject<dyn NSTextLocation>, text_container: Option<&NSTextContainer>, ) -> Option<Retained<NSTextAttachmentViewProvider>>
Available on crate features
NSResponder and NSTextContainer and NSTextRange and NSView only.Trait Implementations§
impl<T> ImplementedBy<T> for dyn NSTextAttachmentLayout
Source§impl ProtocolType for dyn NSTextAttachmentLayout
impl ProtocolType for dyn NSTextAttachmentLayout
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".