View
|
findView(int viewId)
Find view by Id.
|
int
|
getId()
Returns the identifier of this element, by default all elements return "0".
|
Object
|
getTag()
Returns this view's tag.
|
static
View
|
inflateXML(int layoutResId)
Inflate view from XMLLayout declared in the URS File.
|
static
View
|
inflateXML(InputStream xmlStream)
@return
|
boolean
|
isClickable()
Returns if the view is clickable.
|
boolean
|
isEnabled()
Return a boolean indicating if the view is enabled or not
|
boolean
|
isFocusable()
Returns if the view is focusable (for the devices that have a keyboard Ui
navigation).
|
boolean
|
isVisible()
Returns if the view is visible
|
void
|
runOnUiThread(Runnable action)
Calls action.run() asynchronously on the UI-Thread .
|
void
|
setBackground(Background background)
Sets the background on this view.
|
void
|
setBackground(int backgroundResId)
Sets the background on this view with a XML background definition.
|
void
|
setBackgroundColor(Color color)
Sets the background color on this view.
|
void
|
setBackgroundImage(int imageID)
Set the background image for this view.
|
void
|
setBackgroundImage(Image image)
Set the background image for this view.
|
void
|
setBorderColor(Color borderColor)
Sets the border color on this view.
|
void
|
setBorderWidth(int widthInDp)
Set the border width (size) in DP units.
|
void
|
setClickListener(ClickListener clickListener)
Sets a ClickListener to this view.
|
void
|
setClickable(boolean clickable)
Sets this view clickable.
|
void
|
setCornerRadius(int radiusSize)
Set the four corners radius, if the view has corners.
|
void
|
setDrawingCacheEnabled(boolean enabled)
Enables or disables the drawing cache.
|
void
|
setEnabled(boolean enabled)
Sets the state of this view to enabled or disabled.
|
void
|
setFocusable(boolean focusable)
Sets the view focusable.
|
void
|
setGestureDetector(GestureDetector detector)
Sets a GestureDetector on this view.
|
void
|
setHeight(int heightDp)
Sets the height of the view, in dp units (density-independent pixels).
|
void
|
setId(int id)
Sets a identifier/tag to this element
|
void
|
setInvalidateDisabled(boolean disabled)
If set to true, force the layout that contains the view to not be draw again
when its content changes.
|
void
|
setLayoutAlignment(int alignment)
Sets the view alignment into its parent.
|
void
|
setMargin(int uniformMarginDp)
Set the margin outside this view (used by Layout ), by setting on each
side the given value.
|
void
|
setMargin(int leftDp, int topDp, int rightDp, int bottomDp)
Set the margin outside this view (used by Layout ).
|
void
|
setMarginBottom(int marginBottomDp)
Sets the bottom margin with the given value.
|
void
|
setMarginLeft(int marginLeftDp)
Sets the left margin with the given value.
|
void
|
setMarginRight(int marginRightDp)
Sets the right margin with the given value.
|
void
|
setMarginTop(int marginTopDp)
Sets the top margin with the given value.
|
void
|
setPadding(int leftDp, int topDp, int rightDp, int bottomDp)
Sets the view padding.
|
void
|
setPadding(int uniformPaddingDp)
Sets the view padding, with for each side the value given in parameter.
|
void
|
setPaddingBottom(int paddingBottomDp)
Sets the bottom padding with the given value.
|
void
|
setPaddingLeft(int paddingLeftDp)
Sets the left padding with the given value.
|
void
|
setPaddingRight(int paddingRightDp)
Sets the right padding with the given value.
|
void
|
setPaddingTop(int paddingTopDp)
Sets the top padding with the given value.
|
void
|
setSize(int widthDp, int heightDp)
Sets the size of the view, in dp units (density-independent pixels).
|
void
|
setStretchHorizontalMode(int widthMode)
Sets the stretch horizontal mode.
|
void
|
setStretchMode(int horizontalMode, int verticalMode)
Sets the view content stretch mode.
|
void
|
setStretchVerticalMode(int heightMode)
Sets the stretch vertical mode.
|
void
|
setStyle(int styleResId)
|
void
|
setStyle(Style style)
|
void
|
setTag(Object tag)
Sets the tag associated with this view.
|
void
|
setTouchListener(TouchListener touchListener)
Register a listener to be invoked when a touch event is dispatched to this
view.
|
void
|
setTransformOrigin(float xOrigin, float yOrigin)
Sets the x and y location of the point around which the view will be scaled
or rotated when an animation occurs.
|
void
|
setVisible(boolean visible)
Sets the view's visibility : visible or invisible/hidden
|
void
|
setWidth(int widthDp)
Sets the width of the view, in dp units (density-independent pixels).
|