Struct xpcom::interfaces::nsISelectionController
[−]
[src]
#[repr(C)]pub struct nsISelectionController { /* fields omitted */ }
interface nsISelectionController : nsISelectionDisplay
Methods
impl nsISelectionController
[src]
pub fn coerce<T: nsISelectionControllerCoerce>(&self) -> &T
[src]
Cast this nsISelectionController
to one of its base interfaces.
impl nsISelectionController
[src]
pub const SELECTION_NONE: i64
SELECTION_NONE: i64 = 0
pub const SELECTION_NORMAL: i64
SELECTION_NORMAL: i64 = 1
pub const SELECTION_SPELLCHECK: i64
SELECTION_SPELLCHECK: i64 = 2
pub const SELECTION_IME_RAWINPUT: i64
SELECTION_IME_RAWINPUT: i64 = 3
pub const SELECTION_IME_SELECTEDRAWTEXT: i64
SELECTION_IME_SELECTEDRAWTEXT: i64 = 4
pub const SELECTION_IME_CONVERTEDTEXT: i64
SELECTION_IME_CONVERTEDTEXT: i64 = 5
pub const SELECTION_IME_SELECTEDCONVERTEDTEXT: i64
SELECTION_IME_SELECTEDCONVERTEDTEXT: i64 = 6
pub const SELECTION_ACCESSIBILITY: i64
SELECTION_ACCESSIBILITY: i64 = 7
pub const SELECTION_FIND: i64
SELECTION_FIND: i64 = 8
pub const SELECTION_URLSECONDARY: i64
SELECTION_URLSECONDARY: i64 = 9
pub const SELECTION_URLSTRIKEOUT: i64
SELECTION_URLSTRIKEOUT: i64 = 10
pub const NUM_SELECTIONTYPES: i64
NUM_SELECTIONTYPES: i64 = 11
pub const SELECTION_ANCHOR_REGION: i64
SELECTION_ANCHOR_REGION: i64 = 0
pub const SELECTION_FOCUS_REGION: i64
SELECTION_FOCUS_REGION: i64 = 1
pub const SELECTION_WHOLE_SELECTION: i64
SELECTION_WHOLE_SELECTION: i64 = 2
pub const NUM_SELECTION_REGIONS: i64
NUM_SELECTION_REGIONS: i64 = 3
pub const SELECTION_OFF: i64
SELECTION_OFF: i64 = 0
pub const SELECTION_HIDDEN: i64
SELECTION_HIDDEN: i64 = 1
pub const SELECTION_ON: i64
SELECTION_ON: i64 = 2
pub const SELECTION_DISABLED: i64
SELECTION_DISABLED: i64 = 3
pub const SELECTION_ATTENTION: i64
SELECTION_ATTENTION: i64 = 4
pub const SCROLL_SYNCHRONOUS: i64
SCROLL_SYNCHRONOUS: i64 = 2
pub const SCROLL_FIRST_ANCESTOR_ONLY: i64
SCROLL_FIRST_ANCESTOR_ONLY: i64 = 4
pub const SCROLL_CENTER_VERTICALLY: i64
SCROLL_CENTER_VERTICALLY: i64 = 16
pub const SCROLL_OVERFLOW_HIDDEN: i64
SCROLL_OVERFLOW_HIDDEN: i64 = 32
pub const SCROLL_FOR_CARET_MOVE: i64
SCROLL_FOR_CARET_MOVE: i64 = 64
pub const MOVE_LEFT: i64
MOVE_LEFT: i64 = 0
/**
* nsFrameSelection::PhysicalMove depends on the ordering of these values;
* do not change without checking there!
*/
pub const MOVE_RIGHT: i64
MOVE_RIGHT: i64 = 1
pub const MOVE_UP: i64
MOVE_UP: i64 = 2
pub const MOVE_DOWN: i64
MOVE_DOWN: i64 = 3
pub unsafe fn SetDisplaySelection(&self, toggle: int16_t) -> nsresult
[src]
/**
* SetDisplaySelection will set the display mode for the selection. OFF,ON,DISABLED
*/
void setDisplaySelection (in short toggle);
pub unsafe fn GetDisplaySelection(&self, _retval: *mut int16_t) -> nsresult
[src]
/**
* GetDisplaySelection will get the display mode for the selection. OFF,ON,DISABLED
*/
short getDisplaySelection ();
pub unsafe fn GetSelection(
&self,
type_: int16_t,
_retval: *mut *const nsISelection
) -> nsresult
[src]
&self,
type_: int16_t,
_retval: *mut *const nsISelection
) -> nsresult
/**
* GetSelection will return the selection that the presentation
* shell may implement.
*
* @param aType This will hold the type of selection. This value must be one
* of RawSelectionType values.
* @param _return will hold the return value
*/
nsISelection getSelection (in short type);
pub unsafe fn ScrollSelectionIntoView(
&self,
type_: int16_t,
region: int16_t,
flags: int16_t
) -> nsresult
[src]
&self,
type_: int16_t,
region: int16_t,
flags: int16_t
) -> nsresult
/**
* ScrollSelectionIntoView scrolls a region of the selection,
* so that it is visible in the scrolled view.
*
* @param aType the selection to scroll into view. This value must be one
* of RawSelectionType values.
* @param aRegion the region inside the selection to scroll into view. //SelectionRegion
* @param aFlags the scroll flags. Valid bits include:
* SCROLL_SYNCHRONOUS: when set, scrolls the selection into view
* before returning. If not set, posts a request which is processed
* at some point after the method returns.
* SCROLL_FIRST_ANCESTOR_ONLY: if set, only the first ancestor will be scrolled
* into view.
* SCROLL_OVERFLOW_HIDDEN: if set, scrolls even if the overflow is specified
* as hidden.
* SCROLL_FOR_CARET_MOVE: set to indicate whether scrolling is in response
* to the caret being moved. Does not affect behavior (used for telemetry
* purposes only).
*
* Note that if isSynchronous is true, then this might flush the pending
* reflow. It's dangerous for some objects. See bug 418470 comment 12.
*/
void scrollSelectionIntoView (in short type, in short region, in short flags);
pub unsafe fn RepaintSelection(&self, type_: int16_t) -> nsresult
[src]
/**
* RepaintSelection repaints the selection specified by aType.
*
* @param aType specifies the selection to repaint.
*/
void repaintSelection (in short type);
pub unsafe fn SetCaretEnabled(&self, enabled: bool) -> nsresult
[src]
/**
* Set the caret as enabled or disabled. An enabled caret will
* draw or blink when made visible. A disabled caret will never show up.
* Can be called any time.
* @param aEnable PR_TRUE to enable caret. PR_FALSE to disable.
* @return always NS_OK
*/
void setCaretEnabled (in boolean enabled);
pub unsafe fn SetCaretReadOnly(&self, readOnly: bool) -> nsresult
[src]
/**
* Set the caret readonly or not. An readonly caret will
* draw but not blink when made visible.
* @param aReadOnly PR_TRUE to enable caret. PR_FALSE to disable.
* @return always NS_OK
*/
void setCaretReadOnly (in boolean readOnly);
pub unsafe fn GetCaretEnabled(&self, _retval: *mut bool) -> nsresult
[src]
/**
* Gets the current state of the caret.
* @param aEnabled [OUT] set to the current caret state, as set by SetCaretEnabled
* @return if aOutEnabled==null, returns NS_ERROR_INVALID_ARG
* else NS_OK
*/
boolean getCaretEnabled ();
pub unsafe fn GetCaretVisible(&self, aCaretVisible: *mut bool) -> nsresult
[src]
/**
* This is true if the caret is enabled, visible, and currently blinking.
* This is still true when the caret is enabled, visible, but in its "off"
* blink cycle.
*/
readonly attribute boolean caretVisible;
pub unsafe fn SetCaretVisibilityDuringSelection(
&self,
visibility: bool
) -> nsresult
[src]
&self,
visibility: bool
) -> nsresult
/**
* Show the caret even in selections. By default the caret is hidden unless the
* selection is collapsed. Use this function to show the caret even in selections.
* @param aVisibility PR_TRUE to show the caret in selections. PR_FALSE to hide.
* @return always NS_OK
*/
void setCaretVisibilityDuringSelection (in boolean visibility);
pub unsafe fn CharacterMove(&self, forward: bool, extend: bool) -> nsresult
[src]
/** CharacterMove will move the selection one character forward/backward in the document.
* this will also have the effect of collapsing the selection if the aExtend = PR_FALSE
* the "point" of selection that is extended is considered the "focus" point.
* or the last point adjusted by the selection.
* @param aForward forward or backward if PR_FALSE
* @param aExtend should it collapse the selection of extend it?
*/
void characterMove (in boolean forward, in boolean extend);
pub unsafe fn PhysicalMove(
&self,
direction: int16_t,
amount: int16_t,
extend: bool
) -> nsresult
[src]
&self,
direction: int16_t,
amount: int16_t,
extend: bool
) -> nsresult
/** PhysicalMove will move the selection one "unit" in a given direction
* within the document.
* this will also have the effect of collapsing the selection if the aExtend = PR_FALSE
* the "point" of selection that is extended is considered the "focus" point.
* or the last point adjusted by the selection.
* @param aDirection
* @param aAmount character/line; word/lineBoundary
* @param aExtend should it collapse the selection of extend it?
*/
void physicalMove (in short direction, in short amount, in boolean extend);
pub unsafe fn CharacterExtendForDelete(&self) -> nsresult
[src]
/**
* CharacterExtendForDelete will extend the selection one character cell
* forward in the document.
* this method is used internally for handling del key.
*/
[noscript] void characterExtendForDelete ();
pub unsafe fn CharacterExtendForBackspace(&self) -> nsresult
[src]
/**
* CharacterExtendForBackspace will extend the selection one character cell
* backward in the document.
* this method is used internally for handling backspace key only when we're
* after UTF-16 surrogates.
*/
[noscript] void characterExtendForBackspace ();
pub unsafe fn WordMove(&self, forward: bool, extend: bool) -> nsresult
[src]
/** WordMove will move the selection one word forward/backward in the document.
* this will also have the effect of collapsing the selection if the aExtend = PR_FALSE
* the "point" of selection that is extended is considered the "focus" point.
* or the last point adjusted by the selection.
* @param aForward forward or backward if PR_FALSE
* @param aExtend should it collapse the selection of extend it?
*/
void wordMove (in boolean forward, in boolean extend);
pub unsafe fn WordExtendForDelete(&self, forward: bool) -> nsresult
[src]
/** wordExtendForDelete will extend the selection one word forward/backward in the document.
* this method is used internally for handling ctrl[option]-backspace and ctrl[option]-del.
* @param aForward forward or backward if PR_FALSE
*/
[noscript] void wordExtendForDelete (in boolean forward);
pub unsafe fn LineMove(&self, forward: bool, extend: bool) -> nsresult
[src]
/** LineMove will move the selection one line forward/backward in the document.
* this will also have the effect of collapsing the selection if the aExtend = PR_FALSE
* the "point" of selection that is extended is considered the "focus" point.
* or the last point adjusted by the selection.
* @param aForward forward or backward if PR_FALSE
* @param aExtend should it collapse the selection of extend it?
*/
void lineMove (in boolean forward, in boolean extend);
pub unsafe fn IntraLineMove(&self, forward: bool, extend: bool) -> nsresult
[src]
/** IntraLineMove will move the selection to the front of the line or end of the line
* in the document.
* this will also have the effect of collapsing the selection if the aExtend = PR_FALSE
* the "point" of selection that is extended is considered the "focus" point.
* or the last point adjusted by the selection.
* @param aForward forward or backward if PR_FALSE
* @param aExtend should it collapse the selection of extend it?
*/
void intraLineMove (in boolean forward, in boolean extend);
pub unsafe fn PageMove(&self, forward: bool, extend: bool) -> nsresult
[src]
/** PageMove will move the selection one page forward/backward in the document.
* this will also have the effect of collapsing the selection if the aExtend = PR_FALSE
* the "point" of selection that is extended is considered the "focus" point.
* or the last point adjusted by the selection.
* @param aForward forward or backward if PR_FALSE
* @param aExtend should it collapse the selection of extend it?
*/
void pageMove (in boolean forward, in boolean extend);
pub unsafe fn CompleteScroll(&self, forward: bool) -> nsresult
[src]
/** CompleteScroll will move page view to the top or bottom of the document
* @param aForward forward or backward if PR_FALSE
*/
void completeScroll (in boolean forward);
pub unsafe fn CompleteMove(&self, forward: bool, extend: bool) -> nsresult
[src]
/** CompleteMove will move page view to the top or bottom of the document
* this will also have the effect of collapsing the selection if the aExtend = PR_FALSE
* the "point" of selection that is extended is considered the "focus" point.
* or the last point adjusted by the selection.
* @param aForward forward or backward if PR_FALSE
* @param aExtend should it collapse the selection of extend it?
*/
void completeMove (in boolean forward, in boolean extend);
pub unsafe fn ScrollPage(&self, forward: bool) -> nsresult
[src]
/** ScrollPage will scroll the page without affecting the selection.
* @param aForward scroll forward or backwards in selection
*/
void scrollPage (in boolean forward);
pub unsafe fn ScrollLine(&self, forward: bool) -> nsresult
[src]
/** ScrollLine will scroll line up or down dependent on the boolean
* @param aForward scroll forward or backwards in selection
*/
void scrollLine (in boolean forward);
pub unsafe fn ScrollCharacter(&self, right: bool) -> nsresult
[src]
/** ScrollCharacter will scroll right or left dependent on the boolean
* @param aRight if true will scroll right. if not will scroll left.
*/
void scrollCharacter (in boolean right);
pub unsafe fn SelectAll(&self) -> nsresult
[src]
/** SelectAll will select the whole page
*/
void selectAll ();
pub unsafe fn CheckVisibility(
&self,
node: *const nsIDOMNode,
startOffset: int16_t,
endOffset: int16_t,
_retval: *mut bool
) -> nsresult
[src]
&self,
node: *const nsIDOMNode,
startOffset: int16_t,
endOffset: int16_t,
_retval: *mut bool
) -> nsresult
/** CheckVisibility will return true if textnode and offsets are actually rendered
* in the current precontext.
* @param aNode textNode to test
* @param aStartOffset offset in dom to first char of textnode to test
* @param aEndOffset offset in dom to last char of textnode to test
* @param aReturnBool boolean returned TRUE if visible FALSE if not
*/
boolean checkVisibility (in nsIDOMNode node, in short startOffset, in short endOffset);
Methods from Deref<Target = nsISelectionDisplay>
pub fn coerce<T: nsISelectionDisplayCoerce>(&self) -> &T
[src]
Cast this nsISelectionDisplay
to one of its base interfaces.
pub const DISPLAY_TEXT: i64
pub const DISPLAY_IMAGES: i64
pub const DISPLAY_FRAMES: i64
pub const DISPLAY_ALL: i64
pub unsafe fn SetSelectionFlags(&self, toggle: int16_t) -> nsresult
[src]
void setSelectionFlags (in short toggle);
pub unsafe fn GetSelectionFlags(&self, _retval: *mut int16_t) -> nsresult
[src]
short getSelectionFlags ();
Trait Implementations
impl XpCom for nsISelectionController
[src]
const IID: nsIID
IID: nsIID = nsID(939641300, 36457, 19452, [158, 219, 181, 130, 120, 98, 31, 143])
fn query_interface<T: XpCom>(&self) -> Option<RefPtr<T>>
[src]
Perform a QueryInterface call on this object, attempting to dynamically cast it to the requested interface type. Returns Some(RefPtr) if the cast succeeded, and None otherwise. Read more
impl RefCounted for nsISelectionController
[src]
unsafe fn addref(&self)
[src]
Increment the reference count.
unsafe fn release(&self)
[src]
Decrement the reference count, potentially freeing backing memory.
impl Deref for nsISelectionController
[src]
type Target = nsISelectionDisplay
The resulting type after dereferencing.
fn deref(&self) -> &nsISelectionDisplay
[src]
Dereferences the value.