LinkMovementMethod
open class LinkMovementMethod : ScrollingMovementMethod
A movement method that traverses links in the text buffer and scrolls if necessary. Supports clicking on links with DPad Center or Enter.
Summary
Inherited functions |
|
From class BaseMovementMethod
Boolean |
canSelectArbitrarily()
|
Int |
getMovementMetaState(buffer: Spannable!, event: KeyEvent!)
Gets the meta state used for movement using the modifiers tracked by the text buffer as well as those present in the key event. The movement meta state excludes the state of locked modifiers or the SHIFT key since they are not used by movement actions (but they may be used for selection).
|
Boolean |
handleMovementKey(widget: TextView!, buffer: Spannable!, keyCode: Int, movementMetaState: Int, event: KeyEvent!)
Performs a movement key action. The default implementation decodes the key down and invokes movement actions such as down and up . onKeyDown(android.widget.TextView,android.text.Spannable,int,android.view.KeyEvent) calls this method once to handle an KeyEvent#ACTION_DOWN . onKeyOther(android.widget.TextView,android.text.Spannable,android.view.KeyEvent) calls this method repeatedly to handle each repetition of an KeyEvent#ACTION_MULTIPLE .
|
Unit |
initialize(widget: TextView!, text: Spannable!)
|
Boolean |
nextParagraph(widget: TextView, buffer: Spannable)
Performs a next paragraph movement action.
|
Boolean |
onGenericMotionEvent(widget: TextView!, text: Spannable!, event: MotionEvent!)
|
Boolean |
onKeyDown(widget: TextView!, text: Spannable!, keyCode: Int, event: KeyEvent!)
|
Boolean |
onKeyOther(widget: TextView!, text: Spannable!, event: KeyEvent!)
|
Boolean |
onKeyUp(widget: TextView!, text: Spannable!, keyCode: Int, event: KeyEvent!)
|
Boolean |
onTrackballEvent(widget: TextView!, text: Spannable!, event: MotionEvent!)
|
Boolean |
previousParagraph(widget: TextView, buffer: Spannable)
Performs a previous paragraph movement action.
|
|
Public constructors
LinkMovementMethod
LinkMovementMethod()
Public methods
canSelectArbitrarily
open fun canSelectArbitrarily(): Boolean
Protected methods
handleMovementKey
protected open fun handleMovementKey(
widget: TextView!,
buffer: Spannable!,
keyCode: Int,
movementMetaState: Int,
event: KeyEvent!
): Boolean
Parameters |
widget |
TextView!: The text view. |
buffer |
Spannable!: The text buffer. |
event |
KeyEvent!: The key event. |
keyCode |
Int: The key code. |
movementMetaState |
Int: The keyboard meta states used for movement. |
Return |
Boolean |
True if the event was handled. |