PdfActivity

open class PdfActivity : AppCompatActivity, PdfUi, PdfActivityListener, PdfActivityComponentsApi

Activity with fully integrated views and behaviour. Can be invoked by the simple helper methods showDocument and showDocument. For more advanced customization use PdfActivityIntentBuilder to generate an Intent with proper parameters.

Inheritors

Constructors

Link copied to clipboard
constructor()

Properties

Link copied to clipboard
Id of the AI Assistant menu item.
Link copied to clipboard
Id of the document editor menu item.
Link copied to clipboard
Id of the document infoview menu item.
Link copied to clipboard
Id of the edit-annotations menu item.
Link copied to clipboard
Id of the edit-content menu item.
Link copied to clipboard
Id of the outline view menu item.
Link copied to clipboard
Id of the reader view menu item.
Link copied to clipboard
Id of the search menu item.
Link copied to clipboard
Id of the settings menu item.
Link copied to clipboard
Id of the share menu item.
Link copied to clipboard
Id of the signature menu item.
Link copied to clipboard
Id of the thumbnail grid menu item.

Functions

Link copied to clipboard
Dispatches a key event to the PDF UI implementation first, then to the superclass.
Link copied to clipboard
Returns the PdfActivityConfiguration that was provided while launching this activity.
Link copied to clipboard
Re-runs the ToolbarItemsProvider and refreshes the main toolbar — the declarative analogue of invalidateOptionsMenu.
Link copied to clipboard
open fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent)
Link copied to clipboard
Called when a device configuration change occurs while the activity is running.
Link copied to clipboard
Called when document is successfully loaded and the document view has been laid out.
Link copied to clipboard
open fun onDocumentLoadFailed(@NonNull exception: Throwable)
Called if document loading has failed.
Link copied to clipboard
Handles selection of an options menu item.
Link copied to clipboard
Called when activity title must be set - before and after document was loaded.
Link copied to clipboard
open fun onTrimMemory(level: Int)
Called when the operating system determines that it is a good time to trim memory.
Link copied to clipboard
Called when any user interaction occurs.
Link copied to clipboard
Called when user interface visibility have changed.
Link copied to clipboard
open fun onWindowFocusChanged(hasFocus: Boolean)
Called when the window focus changes.
Link copied to clipboard
Replaces activity configuration.
Link copied to clipboard
Themes the main toolbar programmatically with a Compose UiColorScheme, instead of (or on top of) the XML theme attributes.
Link copied to clipboard
Sets the handler for main-toolbar item taps — the Compose-toolbar replacement for intercepting onOptionsItemSelected.
Link copied to clipboard
Sets the handler for taps on the main toolbar's navigation icon — the Compose-toolbar replacement for onSupportNavigateUp / Toolbar.setNavigationOnClickListener.
Link copied to clipboard
Customizes the main-toolbar items declaratively — the Compose-toolbar replacement for overriding onCreateOptionsMenu / onPrepareOptionsMenu.
Link copied to clipboard
open fun setToolbarNavigationIcon(@Nullable icon: ToolbarIcon, @Nullable contentDescription: String)
Sets the main toolbar's navigation (up / back) icon and its accessibility label — the Compose-toolbar replacement for getSupportActionBar().setDisplayHomeAsUpEnabled(true) or Toolbar.setNavigationIcon.
Link copied to clipboard
open fun showDocument(@NonNull context: Context, @NonNull documentUri: Uri, @Nullable configuration: PdfActivityConfiguration)
open fun showDocument(@NonNull context: Context, @NonNull documentUri: Uri, @Nullable password: String, @Nullable configuration: PdfActivityConfiguration)
Opens a new PdfActivity displaying a passed document.
Link copied to clipboard
open fun showImage(@NonNull context: Context, @NonNull imageUri: Uri, @Nullable configuration: PdfActivityConfiguration)
Opens a new PdfActivity displaying a passed image document.