NSTextInput

Trait NSTextInput 

Source
pub unsafe trait NSTextInput {
    // Provided methods
    unsafe fn insertText(&self, string: Option<&AnyObject>)
       where Self: Sized + Message { ... }
    unsafe fn doCommandBySelector(&self, selector: Option<Sel>)
       where Self: Sized + Message { ... }
    unsafe fn setMarkedText_selectedRange(
        &self,
        string: Option<&AnyObject>,
        sel_range: NSRange,
    )
       where Self: Sized + Message { ... }
    fn unmarkText(&self)
       where Self: Sized + Message { ... }
    fn hasMarkedText(&self) -> bool
       where Self: Sized + Message { ... }
    fn conversationIdentifier(&self) -> NSInteger
       where Self: Sized + Message { ... }
    fn attributedSubstringFromRange(
        &self,
        range: NSRange,
    ) -> Option<Retained<NSAttributedString>>
       where Self: Sized + Message { ... }
    fn markedRange(&self) -> NSRange
       where Self: Sized + Message { ... }
    fn selectedRange(&self) -> NSRange
       where Self: Sized + Message { ... }
    fn firstRectForCharacterRange(&self, range: NSRange) -> NSRect
       where Self: Sized + Message { ... }
    fn characterIndexForPoint(&self, point: NSPoint) -> NSUInteger
       where Self: Sized + Message { ... }
    fn validAttributesForMarkedText(&self) -> Option<Retained<NSArray>>
       where Self: Sized + Message { ... }
}
Available on crate feature NSInputManager only.
Expand description

Provided Methods§

Source

unsafe fn insertText(&self, string: Option<&AnyObject>)
where Self: Sized + Message,

👎Deprecated
§Safety
  • string should be of the correct type.
  • string might not allow None.
Source

unsafe fn doCommandBySelector(&self, selector: Option<Sel>)
where Self: Sized + Message,

👎Deprecated
§Safety

selector must be a valid selector.

Source

unsafe fn setMarkedText_selectedRange( &self, string: Option<&AnyObject>, sel_range: NSRange, )
where Self: Sized + Message,

👎Deprecated
§Safety
  • string should be of the correct type.
  • string might not allow None.
Source

fn unmarkText(&self)
where Self: Sized + Message,

👎Deprecated
Source

fn hasMarkedText(&self) -> bool
where Self: Sized + Message,

👎Deprecated
Source

fn conversationIdentifier(&self) -> NSInteger
where Self: Sized + Message,

👎Deprecated
Source

fn attributedSubstringFromRange( &self, range: NSRange, ) -> Option<Retained<NSAttributedString>>
where Self: Sized + Message,

👎Deprecated
Source

fn markedRange(&self) -> NSRange
where Self: Sized + Message,

👎Deprecated
Source

fn selectedRange(&self) -> NSRange
where Self: Sized + Message,

👎Deprecated
Source

fn firstRectForCharacterRange(&self, range: NSRange) -> NSRect
where Self: Sized + Message,

👎Deprecated
Source

fn characterIndexForPoint(&self, point: NSPoint) -> NSUInteger
where Self: Sized + Message,

👎Deprecated
Source

fn validAttributesForMarkedText(&self) -> Option<Retained<NSArray>>
where Self: Sized + Message,

👎Deprecated

Trait Implementations§

Source§

impl ProtocolType for dyn NSTextInput

Source§

const NAME: &'static str = "NSTextInput"

The name of the Objective-C protocol that this type represents. Read more
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 NSTextInput
where T: ?Sized + Message + NSTextInput,

Implementations on Foreign Types§

Source§

impl<T> NSTextInput for ProtocolObject<T>
where T: ?Sized + NSTextInput,

Implementors§

Source§

impl NSTextInput for NSInputManager

Source§

impl NSTextInput for NSTextView

Available on crate feature NSTextView only.