Poppler Reference Manual | ||||
---|---|---|---|---|
Top | Description |
Synopsis
#include <poppler.h> union PopplerAction; PopplerDest; struct PopplerActionAny; struct PopplerActionGotoDest; struct PopplerActionGotoRemote; struct PopplerActionLaunch; struct PopplerActionUri; struct PopplerActionNamed; struct PopplerActionMovie; struct PopplerActionRendition; struct PopplerActionOCGState; struct PopplerActionJavascript; enum PopplerActionType; enum PopplerDestType; enum PopplerActionMovieOperation; PopplerActionLayer; enum PopplerActionLayerAction; PopplerAction * poppler_action_copy (PopplerAction *action
); void poppler_action_free (PopplerAction *action
); PopplerDest * poppler_dest_copy (PopplerDest *dest
); void poppler_dest_free (PopplerDest *dest
);
Details
union PopplerAction
union _PopplerAction { PopplerActionType type; PopplerActionAny any; PopplerActionGotoDest goto_dest; PopplerActionGotoRemote goto_remote; PopplerActionLaunch launch; PopplerActionUri uri; PopplerActionNamed named; PopplerActionMovie movie; PopplerActionRendition rendition; PopplerActionOCGState ocg_state; PopplerActionJavascript javascript; };
A data structure for holding actions
PopplerDest
typedef struct { PopplerDestType type; int page_num; double left; double bottom; double right; double top; double zoom; gchar *named_dest; guint change_left : 1; guint change_top : 1; guint change_zoom : 1; } PopplerDest;
Data structure for holding a destination
PopplerDestType |
type of destination |
page number | |
left coordinate | |
bottom coordinate | |
right coordinate | |
top coordinate | |
scale factor | |
gchar * |
name of the destination (POPPLER_DEST_NAMED only) |
guint |
whether left coordinate should be changed |
guint |
whether top coordinate should be changed |
guint |
whether scale factor should be changed |
struct PopplerActionGotoDest
struct PopplerActionGotoDest { PopplerActionType type; gchar *title; PopplerDest *dest; };
struct PopplerActionGotoRemote
struct PopplerActionGotoRemote { PopplerActionType type; gchar *title; gchar *file_name; PopplerDest *dest; };
struct PopplerActionLaunch
struct PopplerActionLaunch { PopplerActionType type; gchar *title; gchar *file_name; gchar *params; };
struct PopplerActionUri
struct PopplerActionUri { PopplerActionType type; gchar *title; char *uri; };
struct PopplerActionNamed
struct PopplerActionNamed { PopplerActionType type; gchar *title; gchar *named_dest; };
struct PopplerActionMovie
struct PopplerActionMovie { PopplerActionType type; gchar *title; PopplerActionMovieOperation operation; PopplerMovie *movie; };
struct PopplerActionRendition
struct PopplerActionRendition { PopplerActionType type; gchar *title; gint op; PopplerMedia *media; };
struct PopplerActionOCGState
struct PopplerActionOCGState { PopplerActionType type; gchar *title; GList *state_list; };
struct PopplerActionJavascript
struct PopplerActionJavascript { PopplerActionType type; gchar *title; gchar *script; };
enum PopplerActionType
typedef enum { POPPLER_ACTION_UNKNOWN, /* unknown action */ POPPLER_ACTION_NONE, /* no action specified */ POPPLER_ACTION_GOTO_DEST, /* go to destination */ POPPLER_ACTION_GOTO_REMOTE, /* go to destination in new file */ POPPLER_ACTION_LAUNCH, /* launch app (or open document) */ POPPLER_ACTION_URI, /* URI */ POPPLER_ACTION_NAMED, /* named action*/ POPPLER_ACTION_MOVIE, /* movie action */ POPPLER_ACTION_RENDITION, /* rendition action */ POPPLER_ACTION_OCG_STATE, /* Set-OCG-State action */ POPPLER_ACTION_JAVASCRIPT /* Javascript action */ } PopplerActionType;
Action types
unknown action | |
no action specified | |
go to destination | |
go to destination in another document | |
launch app (or open document | |
URI | |
predefined action | |
play movies. Since 0.14 | |
play multimedia content. Since 0.14 | |
state of layer. Since 0.14 | |
Javascript. Since 0.18 |
enum PopplerDestType
typedef enum { POPPLER_DEST_UNKNOWN, POPPLER_DEST_XYZ, POPPLER_DEST_FIT, POPPLER_DEST_FITH, POPPLER_DEST_FITV, POPPLER_DEST_FITR, POPPLER_DEST_FITB, POPPLER_DEST_FITBH, POPPLER_DEST_FITBV, POPPLER_DEST_NAMED } PopplerDestType;
Destination types
unknown destination | |
go to page with coordinates (left, top) positioned at the upper-left corner of the window and the contents of the page magnified by the factor zoom | |
go to page with its contents magnified just enough to fit the entire page within the window both horizontally and vertically | |
go to page with the vertical coordinate top positioned at the top edge of the window and the contents of the page magnified just enough to fit the entire width of the page within the window | |
go to page with the horizontal coordinate left positioned at the left edge of the window and the contents of the page magnified just enough to fit the entire height of the page within the window | |
go to page with its contents magnified just enough to fit the rectangle specified by the coordinates left, bottom, right, and top entirely within the window both horizontally and vertically | |
go to page with its contents magnified just enough to fit its bounding box entirely within the window both horizontally and vertically | |
go to page with the vertical coordinate top positioned at the top edge of the window and the contents of the page magnified just enough to fit the entire width of its bounding box within the window | |
go to page with the horizontal coordinate left positioned at the left edge of the window and the contents of the page magnified just enough to fit the entire height of its bounding box within the window | |
got to page specified by a name. See poppler_document_find_dest()
|
enum PopplerActionMovieOperation
typedef enum { POPPLER_ACTION_MOVIE_PLAY, POPPLER_ACTION_MOVIE_PAUSE, POPPLER_ACTION_MOVIE_RESUME, POPPLER_ACTION_MOVIE_STOP } PopplerActionMovieOperation;
Movie operations
play movie | |
pause playing movie | |
resume paused movie | |
stop playing movie |
Since 0.14
PopplerActionLayer
typedef struct { PopplerActionLayerAction action; GList *layers; } PopplerActionLayer;
Action to perform over a list of layers
PopplerActionLayerAction |
a PopplerActionLayerAction |
GList * |
list of PopplerLayers |
enum PopplerActionLayerAction
typedef enum { POPPLER_ACTION_LAYER_ON, POPPLER_ACTION_LAYER_OFF, POPPLER_ACTION_LAYER_TOGGLE } PopplerActionLayerAction;
Layer actions
set layer visibility on | |
set layer visibility off | |
reverse the layer visibility state |
Since 0.14
poppler_action_copy ()
PopplerAction * poppler_action_copy (PopplerAction *action
);
Copies action
, creating an identical PopplerAction.
|
a PopplerAction |
Returns : |
a new action identical to action
|
poppler_action_free ()
void poppler_action_free (PopplerAction *action
);
Frees action
|
a PopplerAction |
poppler_dest_copy ()
PopplerDest * poppler_dest_copy (PopplerDest *dest
);
Copies dest
, creating an identical PopplerDest.
|
a PopplerDest |
Returns : |
a new destination identical to dest
|