Condividi tramite


PrintDocumentAdapter.OnLayout Method

Definition

Called when the print attributes (page size, density, etc) changed giving you a chance to layout the content such that it matches the new constraints.

[Android.Runtime.Register("onLayout", "(Landroid/print/PrintAttributes;Landroid/print/PrintAttributes;Landroid/os/CancellationSignal;Landroid/print/PrintDocumentAdapter$LayoutResultCallback;Landroid/os/Bundle;)V", "GetOnLayout_Landroid_print_PrintAttributes_Landroid_print_PrintAttributes_Landroid_os_CancellationSignal_Landroid_print_PrintDocumentAdapter_LayoutResultCallback_Landroid_os_Bundle_Handler")]
public abstract void OnLayout (Android.Print.PrintAttributes? oldAttributes, Android.Print.PrintAttributes? newAttributes, Android.OS.CancellationSignal? cancellationSignal, Android.Print.PrintDocumentAdapter.LayoutResultCallback? callback, Android.OS.Bundle? extras);
[<Android.Runtime.Register("onLayout", "(Landroid/print/PrintAttributes;Landroid/print/PrintAttributes;Landroid/os/CancellationSignal;Landroid/print/PrintDocumentAdapter$LayoutResultCallback;Landroid/os/Bundle;)V", "GetOnLayout_Landroid_print_PrintAttributes_Landroid_print_PrintAttributes_Landroid_os_CancellationSignal_Landroid_print_PrintDocumentAdapter_LayoutResultCallback_Landroid_os_Bundle_Handler")>]
abstract member OnLayout : Android.Print.PrintAttributes * Android.Print.PrintAttributes * Android.OS.CancellationSignal * Android.Print.PrintDocumentAdapter.LayoutResultCallback * Android.OS.Bundle -> unit

Parameters

oldAttributes
PrintAttributes

The old print attributes.

newAttributes
PrintAttributes

The new print attributes.

cancellationSignal
CancellationSignal

Signal for observing cancel layout requests.

callback
PrintDocumentAdapter.LayoutResultCallback

Callback to inform the system for the layout result.

extras
Bundle

Additional information about how to layout the content.

Attributes

Remarks

Java documentation for android.print.PrintDocumentAdapter.onLayout(android.print.PrintAttributes, android.print.PrintAttributes, android.os.CancellationSignal, android.print.LayoutResultCallback, android.os.Bundle).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

See also