Trait objc2_ui_kit::NSTextSelectionDataSource

source ·
pub unsafe trait NSTextSelectionDataSource: NSObjectProtocol {
    // Provided methods
    unsafe fn documentRange(&self) -> Retained<NSTextRange>
       where Self: Sized + Message { ... }
    unsafe fn enumerateSubstringsFromLocation_options_usingBlock(
        &self,
        location: &ProtocolObject<dyn NSTextLocation>,
        options: NSStringEnumerationOptions,
        block: &Block<dyn Fn(*mut NSString, NonNull<NSTextRange>, *mut NSTextRange, NonNull<Bool>) + '_>
    )
       where Self: Sized + Message { ... }
    unsafe fn textRangeForSelectionGranularity_enclosingLocation(
        &self,
        selection_granularity: NSTextSelectionGranularity,
        location: &ProtocolObject<dyn NSTextLocation>
    ) -> Option<Retained<NSTextRange>>
       where Self: Sized + Message { ... }
    unsafe fn locationFromLocation_withOffset(
        &self,
        location: &ProtocolObject<dyn NSTextLocation>,
        offset: NSInteger
    ) -> Option<Retained<ProtocolObject<dyn NSTextLocation>>>
       where Self: Sized + Message { ... }
    unsafe fn offsetFromLocation_toLocation(
        &self,
        from: &ProtocolObject<dyn NSTextLocation>,
        to: &ProtocolObject<dyn NSTextLocation>
    ) -> NSInteger
       where Self: Sized + Message { ... }
    unsafe fn baseWritingDirectionAtLocation(
        &self,
        location: &ProtocolObject<dyn NSTextLocation>
    ) -> NSTextSelectionNavigationWritingDirection
       where Self: Sized + Message { ... }
    unsafe fn enumerateCaretOffsetsInLineFragmentAtLocation_usingBlock(
        &self,
        location: &ProtocolObject<dyn NSTextLocation>,
        block: &Block<dyn Fn(CGFloat, NonNull<ProtocolObject<dyn NSTextLocation>>, Bool, NonNull<Bool>) + '_>
    )
       where Self: Sized + Message { ... }
    unsafe fn lineFragmentRangeForPoint_inContainerAtLocation(
        &self,
        point: CGPoint,
        location: &ProtocolObject<dyn NSTextLocation>
    ) -> Option<Retained<NSTextRange>>
       where Self: Sized + Message { ... }
    unsafe fn enumerateContainerBoundariesFromLocation_reverse_usingBlock(
        &self,
        location: &ProtocolObject<dyn NSTextLocation>,
        reverse: bool,
        block: &Block<dyn Fn(NonNull<ProtocolObject<dyn NSTextLocation>>, NonNull<Bool>) + '_>
    )
       where Self: Sized + Message { ... }
    unsafe fn textLayoutOrientationAtLocation(
        &self,
        location: &ProtocolObject<dyn NSTextLocation>
    ) -> NSTextSelectionNavigationLayoutOrientation
       where Self: Sized + Message { ... }
}
Available on crate feature NSTextSelectionNavigation only.

Provided Methods§

source

unsafe fn documentRange(&self) -> Retained<NSTextRange>
where Self: Sized + Message,

Available on crate feature NSTextRange only.
source

unsafe fn enumerateSubstringsFromLocation_options_usingBlock( &self, location: &ProtocolObject<dyn NSTextLocation>, options: NSStringEnumerationOptions, block: &Block<dyn Fn(*mut NSString, NonNull<NSTextRange>, *mut NSTextRange, NonNull<Bool>) + '_> )
where Self: Sized + Message,

Available on crate features NSTextRange and block2 only.
source

unsafe fn textRangeForSelectionGranularity_enclosingLocation( &self, selection_granularity: NSTextSelectionGranularity, location: &ProtocolObject<dyn NSTextLocation> ) -> Option<Retained<NSTextRange>>
where Self: Sized + Message,

Available on crate features NSTextRange and NSTextSelection only.
source

unsafe fn locationFromLocation_withOffset( &self, location: &ProtocolObject<dyn NSTextLocation>, offset: NSInteger ) -> Option<Retained<ProtocolObject<dyn NSTextLocation>>>
where Self: Sized + Message,

Available on crate feature NSTextRange only.
source

unsafe fn offsetFromLocation_toLocation( &self, from: &ProtocolObject<dyn NSTextLocation>, to: &ProtocolObject<dyn NSTextLocation> ) -> NSInteger
where Self: Sized + Message,

Available on crate feature NSTextRange only.
source

unsafe fn baseWritingDirectionAtLocation( &self, location: &ProtocolObject<dyn NSTextLocation> ) -> NSTextSelectionNavigationWritingDirection
where Self: Sized + Message,

Available on crate feature NSTextRange only.
source

unsafe fn enumerateCaretOffsetsInLineFragmentAtLocation_usingBlock( &self, location: &ProtocolObject<dyn NSTextLocation>, block: &Block<dyn Fn(CGFloat, NonNull<ProtocolObject<dyn NSTextLocation>>, Bool, NonNull<Bool>) + '_> )
where Self: Sized + Message,

Available on crate features NSTextRange and block2 only.
source

unsafe fn lineFragmentRangeForPoint_inContainerAtLocation( &self, point: CGPoint, location: &ProtocolObject<dyn NSTextLocation> ) -> Option<Retained<NSTextRange>>
where Self: Sized + Message,

Available on crate feature NSTextRange only.
source

unsafe fn enumerateContainerBoundariesFromLocation_reverse_usingBlock( &self, location: &ProtocolObject<dyn NSTextLocation>, reverse: bool, block: &Block<dyn Fn(NonNull<ProtocolObject<dyn NSTextLocation>>, NonNull<Bool>) + '_> )
where Self: Sized + Message,

Available on crate features NSTextRange and block2 only.
source

unsafe fn textLayoutOrientationAtLocation( &self, location: &ProtocolObject<dyn NSTextLocation> ) -> NSTextSelectionNavigationLayoutOrientation
where Self: Sized + Message,

Available on crate feature NSTextRange only.

Trait Implementations§

source§

impl ProtocolType for dyn NSTextSelectionDataSource

source§

const NAME: &'static str = "NSTextSelectionDataSource"

The name of the Objective-C protocol that this type represents.
source§

fn protocol() -> Option<&'static AnyProtocol>

Get a reference to the Objective-C protocol object that this type represents. Read more
source§

impl<T> ImplementedBy<T> for dyn NSTextSelectionDataSource

Implementations on Foreign Types§

source§

impl<T> NSTextSelectionDataSource for ProtocolObject<T>

Implementors§

source§

impl NSTextSelectionDataSource for NSTextLayoutManager

Available on crate feature NSTextLayoutManager only.