Package org.gnome.gtk
Interface PrintOperation.BeginPrintCallback
- All Superinterfaces:
FunctionPointer
- Enclosing class:
PrintOperation
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public static interface PrintOperation.BeginPrintCallback
extends FunctionPointer
Functional interface declaration of the
BeginPrintCallback
callback.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
run
(PrintContext context) Emitted after the user has finished changing print settings in the dialog, before the actual rendering starts.default MemorySegment
toCallback
(Arena arena) Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment)
method.default void
upcall
(MemorySegment sourcePrintOperation, MemorySegment context) Theupcall
method is called from native code.
-
Method Details
-
run
Emitted after the user has finished changing print settings in the dialog, before the actual rendering starts.A typical use for ::begin-print is to use the parameters from the
PrintContext
and paginate the document accordingly, and then set the number of pages withPrintOperation.setNPages(int)
. -
upcall
Theupcall
method is called from native code. The parameters are marshaled andrun(org.gnome.gtk.PrintContext)
is executed. -
toCallback
Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment)
method.- Specified by:
toCallback
in interfaceFunctionPointer
- Parameters:
arena
- the function pointer will be allocated in this arena- Returns:
- the native function pointer
-