java.lang.Object
   ↳ android.view.View
     ↳ android.view.ViewGroup
       ↳ android.widget.FrameLayout
         ↳ com.pspdfkit.ui.forms.FormEditingBar

Class Overview

Bottom auxiliary bar displayed when filling forms. Provides buttons for navigating between form fields in tab order, clearing form field and finishing with form editing.

Summary

Nested Classes
interface FormEditingBar.OnFormEditingBarLifecycleListener Listener for the lifecycle of the FormEditingBar
[Expand]
Inherited Constants
From class android.view.ViewGroup
From class android.view.View
[Expand]
Inherited Fields
From class android.view.View
Public Constructors
FormEditingBar(Context context)
FormEditingBar(Context context, AttributeSet attrs)
FormEditingBar(Context context, AttributeSet attrs, int defStyleAttr)
FormEditingBar(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes)
Public Methods
void addOnFormEditingBarLifecycleListener(FormEditingBar.OnFormEditingBarLifecycleListener listener)
Adds an FormEditingBar.OnFormEditingBarLifecycleListener for listening to the form editing bar lifecycle.
void bindController(FormEditingController controller)
Binds to form editing controller.
int getBackgroundColor()
Returns background color set to the form editing bar.
int getIconsColor()
Returns color of the icons on this form editing bar.
int getNextIcon()
Return resource id of the icon marking navigation to the next form.
int getPrevIcon()
Return resource id of the icon marking navigation to the previous form.
int getTextColor()
Return color of the text on this form editing bar.
boolean isDisplayed()
True when form input bar is currently displayed on the screen.
void onChangeFormElementEditingMode(FormEditingController controller)
Called then form element editing mode changes, meaning another form element is being selected for editing.
void onClick(View v)
void onEnterFormElementEditingMode(FormEditingController controller)
Called when form element editing mode has been entered.
void onExitFormElementEditingMode(FormEditingController controller)
Called when form element editing mode has been exited.
void onFormElementUpdated(FormElement formElement)
Called when form element gets updated.
void onFormElementValidationFailed(FormElement formElement, String validationError)
Called when form element validation fails.
void onFormElementValidationSuccess(FormElement formElement)
Called when form element validation succeeded.
void onFormElementViewUpdated(FormElement formElement)
Called whenever form element view gets updated, listeners should update their UI accordingly.
void removeOnFormEditingBarLifecycleListener(FormEditingBar.OnFormEditingBarLifecycleListener listener)
void setBackgroundColor(int backgroundColor)
Sets background color to the form editing bar.
void setIconsColor(int iconColor)
Sets color of the icons on this form editing bar.
void setNextIcon(int nextIconResId)
Sets resource id of the icon marking navigation to the next form.
void setPrevIcon(int prevIconResId)
Sets resource id of the icon marking navigation to the previous form.
void setTextColor(int textColor)
Sets color of the text on this form editing bar.
void setVisibility(int visibility)
void unbindController()
Unbinds from form editing controller.
Protected Methods
boolean fitSystemWindows(Rect insets)
void onMeasure(int widthMeasureSpec, int heightMeasureSpec)
[Expand]
Inherited Methods
From class android.widget.FrameLayout
From class android.view.ViewGroup
From class android.view.View
From class java.lang.Object
From interface android.graphics.drawable.Drawable.Callback
From interface android.view.KeyEvent.Callback
From interface android.view.View.OnClickListener
From interface android.view.ViewManager
From interface android.view.ViewParent
From interface android.view.accessibility.AccessibilityEventSource
From interface com.pspdfkit.ui.special_mode.manager.FormManager.OnFormElementEditingModeChangeListener
From interface com.pspdfkit.ui.special_mode.manager.FormManager.OnFormElementUpdatedListener
From interface com.pspdfkit.ui.special_mode.manager.FormManager.OnFormElementViewUpdatedListener

Public Constructors

public FormEditingBar (Context context)

public FormEditingBar (Context context, AttributeSet attrs)

public FormEditingBar (Context context, AttributeSet attrs, int defStyleAttr)

public FormEditingBar (Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes)

Public Methods

public void addOnFormEditingBarLifecycleListener (FormEditingBar.OnFormEditingBarLifecycleListener listener)

Adds an FormEditingBar.OnFormEditingBarLifecycleListener for listening to the form editing bar lifecycle. If the listener has already been added previously, this method will be a no-op. Passing null is not allowed and will result in an exception.

Parameters
listener FormEditingBar.OnFormEditingBarLifecycleListener that should be notified. Must be non-null.

public void bindController (FormEditingController controller)

Binds to form editing controller. Animates form editing bar into view.

public int getBackgroundColor ()

Returns background color set to the form editing bar.

Returns
  • Background color applied to this form editing bar.

public int getIconsColor ()

Returns color of the icons on this form editing bar.

Returns
  • Tint of the icons on the bar.

public int getNextIcon ()

Return resource id of the icon marking navigation to the next form.

Returns
  • Next form navigation button icon.

public int getPrevIcon ()

Return resource id of the icon marking navigation to the previous form.

Returns
  • Previous form navigation button icon.

public int getTextColor ()

Return color of the text on this form editing bar.

Returns
  • Text color on form editing bar.

public boolean isDisplayed ()

True when form input bar is currently displayed on the screen.

public void onChangeFormElementEditingMode (FormEditingController controller)

Called then form element editing mode changes, meaning another form element is being selected for editing.

Parameters
controller Controller for managing form element editing.

public void onClick (View v)

public void onEnterFormElementEditingMode (FormEditingController controller)

Called when form element editing mode has been entered.

Parameters
controller Controller for managing form element editing.

public void onExitFormElementEditingMode (FormEditingController controller)

Called when form element editing mode has been exited.

Parameters
controller Controller for managing form element editing.

public void onFormElementUpdated (FormElement formElement)

Called when form element gets updated.

Parameters
formElement Form element that has been updated.

public void onFormElementValidationFailed (FormElement formElement, String validationError)

Called when form element validation fails.

Parameters
formElement Form element that failed to validate.
validationError Localized validation error.

public void onFormElementValidationSuccess (FormElement formElement)

Called when form element validation succeeded.

Parameters
formElement Form element that failed to validate.

public void onFormElementViewUpdated (FormElement formElement)

Called whenever form element view gets updated, listeners should update their UI accordingly.

public void removeOnFormEditingBarLifecycleListener (FormEditingBar.OnFormEditingBarLifecycleListener listener)

Removes a previously added FormEditingBar.OnFormEditingBarLifecycleListener. Upon calling this method the listener will no longer be notified of any lifecycle changes. If the listener has not been added previously, this method will be a no-op. Passing null is not allowed, and will result in an exception.

Parameters
listener FormEditingBar.OnFormEditingBarLifecycleListener that should be removed. Must be non-null.

public void setBackgroundColor (int backgroundColor)

Sets background color to the form editing bar.

Parameters
backgroundColor Background color to be applied to this form editing bar.

public void setIconsColor (int iconColor)

Sets color of the icons on this form editing bar.

Parameters
iconColor Tint of the icons on the bar.

public void setNextIcon (int nextIconResId)

Sets resource id of the icon marking navigation to the next form.

Parameters
nextIconResId Next form navigation button icon.

public void setPrevIcon (int prevIconResId)

Sets resource id of the icon marking navigation to the previous form.

Parameters
prevIconResId Previous form navigation button icon.

public void setTextColor (int textColor)

Sets color of the text on this form editing bar.

Parameters
textColor Text color on form editing bar.

public void setVisibility (int visibility)

public void unbindController ()

Unbinds from form editing controller. Animates form editing bar out of view.

Protected Methods

protected boolean fitSystemWindows (Rect insets)

protected void onMeasure (int widthMeasureSpec, int heightMeasureSpec)