LayerAV_Layer
ObjectAVDoc

An AVDoc is a view of a PDF document in a window. Usually there is one AVDoc per displayed document. Unlike a PDDoc, an AVDoc has a window associated with it. Starting with Acrobat 7.0, it is possible to have multiple windows open on the same document. An API client can track the coming and going of document windows using three new notifications. It can also query for all windows open for an AVDoc using two new API calls.



Define Summary
 Define
 kAVDocSplitterPinnedLeft
Specifies a special value for AVDocSetSplitterPosition() and AVDocGetSplitterPosition().
 kAVDocSplitterPinnedRight
Specifies a special value for AVDocSetSplitterPosition() and AVDocGetSplitterPosition().
 kAVDocStatusKeyAlwaysInformText
 kAVDocStatusKeyDefaultsToChecked
 kAVDocStatusKeyHelpText
 kAVDocStatusKeyLargeIcon
 kAVDocStatusKeyName
 kAVDocStatusKeySmallIcon
 kAVDocStatusKeyTipText
 kAVDocViewDefKeyBringToFront
boolean
 kAVDocViewDefKeyOCGStates
cab
 kAVDocViewDefKeyOverViewMode
int
 kAVDocViewDefKeyOverViewPos
int
 kAVDocViewDefKeyOverViewX
int
 kAVDocViewDefKeyOverViewY
int
 kAVDocViewDefKeyPageViewBead
binary: PDBead
 kAVDocViewDefKeyPageViewLayoutMode
int
 kAVDocViewDefKeyPageViewPageNum
int
 kAVDocViewDefKeyPageViewStartThread
int
 kAVDocViewDefKeyPageViewThreadIndex
int
 kAVDocViewDefKeyPageViewX
int
 kAVDocViewDefKeyPageViewY
int
 kAVDocViewDefKeyPageViewZoom
int
 kAVDocViewDefKeyPageViewZoomType
int
 kAVDocViewDefKeyWindowFrame
binary: AVRect
 kAVDocViewDefKeyWindowMaximized
binary: AVRect
Typedef Summary
 Typedef
 AVDoc
A view of a PDF document in a window. There is one AVDoc per displayed document. Unlike a PDDoc, an AVDoc has a window associated with it.
 AVDocForceOpenOption
 AVDocOpenParams
 AVDocOpenParamsRec
 AVDocPrintNupData
 AVDocPrintNupDataRec
 AVDocPrintOverrideData
 AVDocPrintOverrideDataRec
 AVDocPrintParams
A structure that specifies how to print a document. It specifies rasterization parameters used by AVDocPrintParams. The constant DPI values are defined in AVExpT.h.
 AVDocPrintParamsRec
 AVDocPrintRasterizeData
 AVDocPrintRasterizeDataRec
 AVDocPrintSepsParams
EmitFlags
 AVDocPrintSepsParamsRec
 AVDocPrintTileData
 AVDocPrintTileDataRec
 AVDocSaveParams
 AVDocSaveParamsRec
 AVDocSelectionServer
 AVDocSelectionServerRec
 AVDocServerType
 AVDocViewDef
 AVDocViewDefRec
Enumeration Summary
 Enumeration
  _t_AVDocForceOpenOption
Parameter to control the security mode in which document is opened. If kDoNotForce (the default mode), Acrobat applies it's own logic. If kForceOpenInProtectedView, PDF will be opened in Protected View only. If kForceOpenAsTrusted, PDF will be opened in trusted mode only.
  _t_AVDocServerType
Constant values indicating the type of document server being used for a document.
  AVDocOpenFlags
Flags used while opening an AVDoc.
Structure Summary
 Structure
 _t_AVDocOpenParams
Parameters used when opening a file.
 _t_AVDocPrintNupData
N-up and booklet printing options for AVDocPrintParams. It is used in the call to AVDocPrintPagesWithParams().
 _t_AVDocPrintOverrideData
A structure specifying override parameters used by AVDocPrintParams.
 _t_AVDocPrintParams
A structure that specifies how to print a document.
 _t_AVDocPrintRasterizeData
A structure specifying rasterization parameters used by AVDocPrintParams. The constant DPI values are defined in AVExpT.h.
 _t_AVDocPrintSepsParams
A structure specifying color separation printing parameters used by AVDocPrintSeparations().
 _t_AVDocPrintTileData
For AVDocPrintParams - used in the call AVDocPrintPagesWithParams().
 _t_AVDocSaveParams
A structure used by AVDocDoSaveAsWithParams() containing parameters that a client wishing to save a file might want to specify. It is passed in by address to AVDocDoSaveAsWithParams() with a size field so that current clients replacing AVDocDoSaveAsWithParams() will not break in the future if new open specifications are provided.
 _t_AVDocSelectionServer
A data structure containing callbacks that implement a selection server. The callbacks implement the selection server functions. For example, they can add an item to the selection, remove an item from the selection, or copy the current selection to the clipboard.
 _t_AVDocViewDef
A structure that defines a view of a document, including page, zoom, and so on.
Callback Summary
 Callback
 AVDocEnumProc
A callback used by AVAppEnumDocs(). It is called once for each open AVDoc.
 AVDocPermReqProc
A callback that can be associated with an AVDoc when it is opened (via an AVDocOpenParamsRec). It can restrict the set operations allowed on the document. When AVDocPermRequest() is called, this callback must be consulted to deny or grant the permission. If it denies permission, AVDocPermRequest() will also deny permission. If it grants permission, the security handler for the document will be consulted to determine the result of AVDocPermRequest(). This callback can only deny permissions allowed by the security handler; it cannot grant permissions that the security handler does not grant.
 AVDocSelectionAcquireQuadsProc
A callback for AVDocSelectionServer that gets a quad-based region for the selection.
 AVDocSelectionAddedToSelectionProc
A callback for AVDocSelectionServer that adds the specified item to the selection, highlights it, and returns the new selection containing the newly-added item.
 AVDocSelectionCanCopyProc
A callback for AVDocSelectionServer. It is used to determine whether the current selection can be copied. This controls, for example, whether the Copy menu item is enabled.
 AVDocSelectionCanCutProc
A callback for AVDocSelectionServer. It is used to determine whether the current selection can be cut. This controls, for example, whether the Cut menu item is enabled.
 AVDocSelectionCanDeleteProc
A callback for AVDocSelectionServer. It is used to determine whether the current selection can be deleted. This controls, for example, whether the Delete menu item is enabled.
 AVDocSelectionCanPasteFromPlatformProc
Determines whether a selection can be pasted.
 AVDocSelectionCanPasteProc
A callback for AVDocSelectionServer. It is used to determine whether the current selection can be pasted. This controls, for example, whether the Paste menu item is enabled.
 AVDocSelectionCanPropertiesProc
A callback for AVDocSelectionServer. It is used to determine whether the current selection has user-specified properties. This controls whether the Properties menu item is enabled.
 AVDocSelectionCanSelectAllProc
A callback for AVDocSelectionServer. It is used to determine whether the current selection type can perform a select all operation. This controls whether the Select All menu item is enabled.
 AVDocSelectionCopyProc
A callback for AVDocSelectionServer. It copies the selected item to the clipboard. The Acrobat viewer will have already cleared the clipboard and placed some private data onto it, in order to identify the selection server that put data on the clipboard. Because of this, a plug-in must not clear the clipboard, and should only add its private data. In addition, if the current selection can be reasonably represented as text, plug-ins are strongly encouraged to place a text representation of the selection onto the clipboard, in addition to their own private format.
 AVDocSelectionCutProc
A callback for AVDocSelectionServer. It cuts the current selection. See the discussion under AVDocSelectionCopyProc() for information on how the selection server must use the clipboard.
 AVDocSelectionDeleteProc
A callback for AVDocSelectionServer. It deletes the current selection.
 AVDocSelectionEnumPageRangesProc
A callback for AVDocSelectionServer. It allows enumeration of the set of pages the selection covers.
 AVDocSelectionEnumSelectionProc
(Optional) A callback for AVDocSelectionServer. It is called by AVDocEnumSelection(). This callback enumerates the current selection, calling the specified AVSelectionEnumProc() for each item in the selection (the selection server is free to decide what constitutes an item).
 AVDocSelectionGetAVRectProc
Called to identify the bounding rectangle of a selection. It is used by the Info palette to display the width and height of the selection.
 AVDocSelectionGetSelectionTypeProc
A callback for AVDocSelectionServer. It provides a way for a single selection server to register different selection types based on the selection data. If this callback is not supplied, the selection type defaults to the return value from AVDocSelectionGetTypeProc().
 AVDocSelectionGettingSelectionProc
A callback for AVDocSelectionServer. It is called when the selection is set (for example, via AVDocSetSelection() ).
 AVDocSelectionGetTypeProc
A callback for AVDocSelectionServer. It returns the selection type this server handles (for example, 'Text' or 'Bookmark'). This information is used so that the Acrobat viewer knows which selection server to call.
 AVDocSelectionHighlightSelectionExProc
 AVDocSelectionHighlightSelectionProc
(Previously known as AVDocHighlightSelectionProc) Callback for AVDocSelectionServer. It highlights the selection. This method is unnecessary if the selection type highlights itself (as in the case of annotations).
 AVDocSelectionKeyDownProc
(Optional) A callback for AVDocSelectionServer. It handles a key press. It is needed only if the selection server processes key presses.
 AVDocSelectionLosingSelectionProc
A callback for AVDocSelectionServer. This method is called by AVDocClearSelection (among others), to let the selection server responsible for the old selection do whatever cleanup it needs.
 AVDocSelectionPasteFromPlatformProc
Paste the selection.
 AVDocSelectionPasteProc
A callback for AVDocSelectionServer. It pastes the current selection from the clipboard.
 AVDocSelectionPropertiesProc
(Optional) A callback for AVDocSelectionServer that displays the set properties user interface, if any, for the selection server and lets the user set the server's properties. This callback is not needed unless the selection server has properties that can be set by the user (for example, text highlight color). This callback is called by AVDocDoSaveAsWithParams().
 AVDocSelectionRemovedFromSelectionProc
A callback for AVDocSelectionServer that de-highlights the old item given in remData, and returns a new curData or NULL if failure occurred.
 AVDocSelectionSelectAllProc
A callback for AVDocSelectionServer that selects all items of the current type.
 AVDocSelectionShowMenuProc
Called to request that the selection server display a context menu appropriate for the current selection.
 AVDocSelectionShowSelectionProc
A callback for AVDocSelectionServer. It changes the view (for example, by scrolling the current page or moving to the appropriate page) so that the current selection is visible.
 AVDocSelectionUnicodeKeyDownProc
(Optional) A callback for AVDocSelectionServer. It handles a key press using Unicode values. It is needed only if the selection server processes key presses.
Method Summary
 Method
 
void AVDocActivePageViewDidChange(AVDoc avDoc, AVPageView newPageView, AVPageView oldPageView, void* clientData)
Called when the document's page view changes.
 
ASInt32 AVDocAlert(AVDoc doc, AVIconType iconType, const char* msg, const char* button1, const char* button2, const char* button3, ASBool beep)
Displays an alert containing the specified message, icon, and one to three buttons with the specified titles. See AVAlert for more information.
 
ASBool AVDocAlertConfirm(AVDoc doc, const char* msg)
Displays a dialog box containing the ALERT_CAUTION icon, the specified message, and OK and Cancel buttons. The method also performs a system beep. See AVDocAlert() for more information.
 
void AVDocAlertNote(AVDoc doc, const char* msg)
Displays a dialog box containing the ALERT_NOTE icon, the specified message and an OK button. The method also performs a system beep. See AVDocAlert() for more information.
 
ASInt32 AVDocAlertYesNo(AVDoc doc, AVIconType iconType, const char* msg, ASBool cancel, ASBool beep)
Displays a dialog box containing the specified message, icon, and two or three buttons with the titles Yes, No, and (optionally) Cancel. See AVDocAlert() for more information.
 
ASBool AVDocApplyRedactions(AVDoc avDoc, PDApplyRedactionParams applyParams, ASBool showConfirmation, ASBool showWarnings, ASBool showErrors)
Applies a set of redaction marks to the document, permanently removing the affected document content and the marks themselves.
 
void AVDocAVWindowDidChange(AVDoc doc, AVWindow oldWindow, AVWindow newWindow, void* clientData)
The active window associated with a document has changed. This is the window returned by AVDocGetAVWindow() .
 
Begins an undo group for the document. To create an undo group, call this method, create each instance with its handler and data, and call AVDocEndUndoOperation().
 
Brings the specified document to front. i.e. Makes its window and main view visible.
 
ASBool AVDocClearSelection(AVDoc doc, ASBool highlight)
Clears and destroys the current selection by calling the appropriate selection server's AVDocSelectionLosingSelectionProc().
 
Clears the entire undo list for the AVDoc and releases all associated AVUndo objects.
 
ASBool AVDocClose(AVDoc doc, ASBool noSave)
Closes the document window, optionally prompting the user to save the document if it has been modified. When this method closes the AVDoc, it also closes the underlying PDDoc.
 
PDAction AVDocCopyAction(AVDoc fromDoc, PDAction anAction, AVDoc toDoc)
Makes a copy of the action for the (possibly different) specified AVDoc. It calls the AVActionCopyProc() callback in AVActionHandlerProcs.
 
PDAction AVDocCopyActionCommon(AVDoc fromDoc, PDAction anAction, AVDoc toDoc)
Makes a copy of the action for the (possibly different) specified AVDoc.
 
void AVDocCopyAdditionalActions(AVDoc avFr, CosObj coFr, AVDoc avTo, CosObj coTo)
Copies any additional actions (AA) from a Cos Dictionary to a Cos Dictionary in the (possibly different) specified AVDoc.
 
PDAnnot AVDocCopyAnnot(AVDoc fromDoc, PDAnnot anAnnot, AVDoc toDoc)
Makes a copy of the annotation for the (possibly different) specified AVDoc. It calls the AVAnnotHandlerCopyProc() callback in AVAnnotHandler.
 
PDAnnot AVDocCopyAnnotCommon(AVDoc fromDoc, PDAnnot anAnnot, AVDoc toDoc)
Makes a copy of the annotation for the (possibly different) specified AVDoc.
 
Copies the current selection to the clipboard, if possible. The selection is copied if the selection server has a AVDocSelectionCopyProc() callback, and the selection server's AVDocSelectionCanCopyProc() callback returns true. If the selection server does not have a AVDocSelectionCanCopyProc() method, a default value of true is used.
 
Deletes the specified document's current selection, if possible. The selection is deleted if changing the selection is currently permitted, the selection server has an AVDocSelectionDeleteProc() callback, and the selection server's AVDocSelectionCanDeleteProc() callback returns true. If the selection server does not have a AVDocSelectionCanDeleteProc() callback, a default value of true is used.
 
void AVDocDidActivate(AVDoc doc, void* clientData)
An AVDoc has activated. At the time this notification is broadcast, it is possible that the window being activated has not yet been brought to the front. For this reason, the AVAppFrontDocDidChange() notification is often more useful.
 
void AVDocDidAddToSelection(AVDoc doc, ASAtom selType, void* selData, void* addData, void* clientData)
The document's selection has been added to or had something removed.
 
void AVDocDidClearSelection(AVDoc doc, void* clientData)
A document's selection has been cleared.
 
void AVDocDidClickName(AVDoc doc, CosObj NameObj, void* clientData)
Acrobat executed an action to go to a named destination.
 
void AVDocDidClose(AVDoc doc, void* clientData)
A document has been closed. Although An AVDoc is passed to the routine called by this notification, the document has already been closed but not freed. As a result, all the routine can really do is manipulate any private data in the underlying PDF file at the time this notification occurs.
 
void AVDocDidDeactivate(AVDoc doc, void* clientData)
A document was deactivated.
 
void AVDocDidDeleteSelection(AVDoc doc, ASAtom selType, void* selData, void* clientData)
Called when a user deletes the current selection.
 
void AVDocDidOpen(AVDoc doc, ASInt32 error, void* clientData)
A document has been opened.
 
void AVDocDidPerformAction(AVDoc doc, PDAction action, ASInt32 err, void* clientData)
An action was performed.
 
void AVDocDidPrint(AVDoc doc, void* clientData)
This notification is broadcast after printing ends.
 
void AVDocDidRemoveFromSelection(AVDoc doc, ASAtom selType, void* selData, void* remData, void* clientData)
The document's selection has had something removed.
 
void AVDocDidSetSelection(AVDoc doc, ASAtom selType, void* selData, void* clientData)
The document's selection has been set.
 
ASBool AVDocDoActionPropsDialog(AVDoc doc, PDAction* action, const char* dialogTitle)
Displays a modal dialog box that allows a user to specify an action. For example, it is used by forms to add actions to fields.
 
void AVDocDoAnnotProperties(AVDoc doc, ASInt32 pageNum, PDAnnot annot)
Show the properties dialog box for the specified annotation.
 
ASBool AVDocDoCopyAs(AVDoc avDoc)
Prompts the user with a standard file dialog box and copies the file byte for byte. It displays a progress monitor showing the progress of the file copy.
 
Performs the print operation, including user dialog boxes.
 
ASBool AVDocDoSave(AVDoc doc)
Saves a file, handling any user interface (for example, a Save File dialog box) as needed. Clients do not need to call this method directly, but it is available for clients that need to override the Acrobat viewer's built-in save method. For example, it can be used to save the changes made to a PDF file into a special file, but not save the original PDF file.
 
ASBool AVDocDoSaveAs(AVDoc doc)
Displays a file dialog box which can be used to save the document to a new name. It allows clients (such as Optimizer) to do their own file saving.
 
Saves a file, using the parameters specified in params.
 
Displays the user interface, if any, for setting the current selection's properties. It does this by invoking the AVDocSelectionPropertiesProc() callback, if any, of the current selection's selection server.
 
void AVDocEndUndoOperation(AVDoc doc, const ASText undoTitle, const ASText redoTitle)
Ends an undo group for the document. To create an undo group, call AVDocBeginUndoOperation(), create each instance with its handler and data, and call this method.
 
void AVDocEnumSelection(AVDoc doc, AVSelectionEnumProc proc, void* clientData)
Enumerates the elements of the current selection by calling the current selection server's AVDocSelectionEnumSelectionProc() callback. If the selection server does not have an AVDocSelectionEnumSelectionProc(), it calls proc and passes the entire selection to it in the aSelectedObject parameter.
 
AVDoc AVDocFromPDDoc(PDDoc pdDoc)
Gets the AVDoc associated with a PDDoc.
 
Gets the active tool for the AVDoc. The call provides the additional context needed to retrieve the active tool for documents that are displayed in external windows such as a web browser.
 
AVWindow AVDocGetAVWindow(AVDoc doc)
Gets the AVWindow in which the document is displayed. If more than one window is open for a document, this call returns the active window for that document, which is the one with which the user is interacting.
 
ASInt32 AVDocGetBookmarks(AVDoc avDoc, AVBookmarkFilter avBookmarkFilter, PDBookmark** pPDBookmarkArray)
Gets the set of bookmarks for a given document that satisfies the input filter. It is the client's responsibility to release the memory associated with the bookmark array using ASfree().
 
AVTArraySize AVDocGetClientName(AVDoc avDoc, char* buffer, AVTBufferSize bufSize)
Gets the AVDoc client (container application) name.
 
ASBool AVDocGetDisplayTitle(AVDoc doc, ASText title)
Gets the display-title of a given doc. Display title is the text that appears on application title bar when the doc is the active document.
 
Gets the tool that was active for this document before the current tool became active.
 
AVPageView AVDocGetNthPageView(AVDoc avDoc, ASCount n)
Gets the specified AVPageView for the specified document.
 
AVWindow AVDocGetNthWindow(AVDoc avDoc, ASCount n)
Gets the specified AVWindow for the specified document. If the index is out of range, NULL is returned. The windows are enumerated in no particular order. Specifically, the window at index 0 is not guaranteed to be the active window.
 
Gets the number of page views for the specified document.
 
ASCount AVDocGetNumWindows(AVDoc avDoc)
Returns the number of windows currently open for the document.
 
void AVDocGetPageText(AVDoc doc, PDPageNumber pageNum, PDTextSelect pdText, ASAtom format, AVTextCopyProc copyProc, void* clientData)
Gets the text from the specified text selection, converts it to the specified format, and passes it to a user-supplied procedure.
 
AVPageView AVDocGetPageView(AVDoc doc)
Gets the AVPageView for the specified document.
 
PDDoc AVDocGetPDDoc(AVDoc avDoc)
Gets the PDDoc to associate with the specified AVDoc.
 
Gets the current selection for the specified document.
 
AVDocSelectionServer AVDocGetSelectionServerByType(ASAtom type)
Gets the selection server that handles the specified selection type.
 
Gets the current selection's type for the specified document.
 
AVDocServerType AVDocGetServerType(AVDoc doc)
Gets the server type for the specified document.
 
Gets the splitter position. The splitter is the vertical division between the bookmark/thumbnail pane and the document pane. The default splitter location is saved in the Acrobat viewer's preferences file, and can be read and set using AVAppGetPreference() and AVAppSetPreference().
 
AVUndo AVDocGetTopUndo(AVDoc doc, const char* desiredType)
Returns the most recent AVUndo record in the document's undo list, if it of the desired type.
 
void AVDocGetTopUndoAndRedo(AVDoc doc, AVUndo* undo, AVUndo* redo, const char* desiredType)
Returns the most recent undo and redo records in the document's undo list, if they are of the desired type.
 
Fills out the given AVDocViewDef structure with the information needed to restore this document's state at a later date. You must set the use fields as desired.
 
void AVDocGetViewDefEx(AVDoc doc, ASCab viewDef)
Fills out the given view definition with the information needed to restore this document's state at a later date. If you pass an empty ASCab, the method fills it with all of the view information. Otherwise, it fills only those fields that are present in the ASCab.
 
PDPageMode AVDocGetViewMode(AVDoc doc)
Gets the current view mode.
 
ASBool AVDocIsDead(AVDoc avDoc)
Determines whether a given document is dead. When the connection to a document is severed (for example, when its HTTP connection is broken) the document becomes dead for an interval before it is closed. During that interval, the document may be visible and open, but no operations should be performed on the document.
 
Determines whether a given document is displayed in an application's external window (such as in a web browser's window).
 
Checks whether a given document is opened in Protected View or not. Protected View provides an additional level of security. When Protected View in enabled, PDFs are displayed in a restricted environment called a sandbox. This isolation of the PDFs reduces the risk of security breaches in areas outside the sandbox. For more information please refer to the Application Security Guide at www.adobe.com/go/acroappsecurity
 
Determines whether an AVDoc is read-only.
 
ASBool AVDocIsSlow(AVDoc doc)
Determines whether a given document is on a slow file system (such as a web browser).
 
AVDoc AVDocOpenFromASFileWithParams(ASFile file, const ASText tempTitle, AVDocOpenParams params)
Opens and displays a document from a file, using the specified parameters to control the window's size, location, and visibility.
 
AVDoc AVDocOpenFromASFileWithParamString(ASFile file, const ASText tempTitle, AVDocOpenParams p, const char* s)
Opens and displays a document from an ASFile, using the specified parameters to control the window's size, location, and visibility, and passing a URL open action string to control how the file is opened. For more information, see Parameters for Opening PDF Files.
 
AVDoc AVDocOpenFromFile(ASPathName pathName, ASFileSys fileSys, const ASText tempTitle)
Opens and displays a document from a file. This is equivalent to AVDocOpenFromASFileWithParams(pathName, fileSys, tempTitle, NULL). If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().
 
AVDoc AVDocOpenFromFileWithParams(ASPathName pathName, ASFileSys fileSys, const ASText tempTitle, AVDocOpenParams params)
Opens and displays a document from a file, using the specified parameters to control the window's size, location, and visibility.
 
AVDoc AVDocOpenFromFileWithParamString(ASPathName pathName, ASFileSys fileSys, const ASText tempTitle, AVDocOpenParams p, const char* s)
Opens and displays a document from a file, using the specified parameters to control the window's size, location, and visibility, and passing a URL open action string to control how the file is opened. For more information, see the document Parameters for Opening PDF Files.
 
AVDoc AVDocOpenFromPDDoc(PDDoc doc, const ASText tempTitle)
Opens and returns an AVDoc view of pdDoc. This method is equivalent to AVDocOpenFromPDDocWithParams(pdDoc, tempTitle, NULL). If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().
 
AVDoc AVDocOpenFromPDDocWithParams(PDDoc pdDoc, const ASText tempTitle, AVDocOpenParams params)
Opens and displays a document from a PDDoc, using the specified parameters to control the window's size, location, and visibility.
 
AVDoc AVDocOpenFromPDDocWithParamString(PDDoc pdDoc, const ASText tempTitle, AVDocOpenParams p, const char* s)
Opens and displays a document from a PDDoc, using the specified parameters to control the window's size, location, and visibility, and passing a URL open action string to control how the file is opened. For more information, see the document Parameters for Opening PDF Files.
 
Performs an action.
 
Same as AVDocPerformAction(), but provides context for the execution of the action.
 
An exact way to ask if an operation is permitted. This routine should be used to query all user interface-level permissions (for example, to determine whether a tool button or menu item is enabled or whether a tool can act upon a given document). This routine should be used instead of some combination of AVDocIsReadOnly(), AVDocIsExternal(), and PDDocPermRequest(). AVDocPermRequest() calls PDDocPermRequest() internally in the process of determining whether to grant the request.
 
void AVDocPopupContentsWillChange(AVDoc doc, PDAnnot annot, void* clientData)
The contents of a popup note have change but have not yet been set in the PDAnnot, thus the change is intermediate. The contents will be changed when input focus is lost by the popup note.
 
void AVDocPrintDialogWasCancelled(AVDoc doc, void* clientData)
This notification will be broadcast when the user cancels the print dialog. It serves as the alternate to AVDocDidPrint() . The AVDocDidPrint() notification is not sent when the print dialog is cancelled.
 
void AVDocPrintPages(AVDoc doc, AVPageIndex firstPage, AVPageIndex lastPage, ASInt32 psLevel, ASBool binaryOK, ASBool shrinkToFit)
Prints without displaying any user dialog boxes. The current printer, page settings, and job settings are used. Printing is complete when this method returns.
 
Prints a document with a full range of options. Printing is complete when this method returns. It performs embedded printing; that is, it allows a PDF page to print within a bounding rectangle on a page. It allows interactive printing to the specified printer (Windows, Mac OS, and UNIX).
 
Prints document color separations using the supplied parameters. Printing is complete when this method returns.
 
Registers a new selection server with the Acrobat viewer. Selection servers allow the selection of items other than those that can be selected in the as-shipped Acrobat viewer. For example, a selection server could allow a user to select a sampled image.
 
void AVDocSaveOptimized(AVDoc avDoc, const PDFOptParamsRec* pdfOptParams)
This method invokes the PDF Optimizer tool on a specified AVDoc. An optimized document is created using the settings specified in the PDFOptParamsRec structure. The optimized document is saved to the disk at the location specified in the parameter's structure. If the operation is successful, the active document is closed and the optimized document is opened for viewing. If the operation fails, the active document remains open.
 
Enumerates the pages on which there is a selection by calling the current selection server's AVDocSelectionEnumPageRangesProc() callback.
 
ASBool AVDocSendAuxData(AVDoc avDoc, ASAtom auxDataType, void* auxData, AVTBufferSize auxDataLen)
Sends auxiliary data to an AVDoc. If an AVAuxDataHandler exists for the data type, the handler is called with avDoc, auxDataType, and auxData. The definition of the auxiliary data is dependent on the AVAuxDataHandler.
 
void AVDocSetActiveTool(AVDoc doc, AVTool tool, ASBool persistent)
Sets the active tool for the AVDoc.
 
void AVDocSetClientName(AVDoc avDoc, char* clientName)
Sets the AVDoc client (container application) name. This method can be used by clients that open documents in the viewer via DDE or Apple events. Most clients will not open documents in this way, however, making this method unnecessary for most clients.
 
void AVDocSetDead(AVDoc doc, ASBool dead)
Indicates that the file stream for this document is terminated, although the AVDoc is still open. No more data can be read from this AVDoc.
 
void AVDocSetReadOnly(AVDoc doc, ASBool readOnly)
Sets the read-only state of an AVDoc.
 
ASBool AVDocSetSelection(AVDoc doc, ASAtom type, void* data, ASBool highlight)
Sets the document's current selection to the specified selection by calling the appropriate selection server's AVDocSelectionGettingSelectionProc() callback. It clears the previous selection, if any, by calling the previous selection server's AVDocSelectionLosingSelectionProc() callback.
 
void AVDocSetSplitterPosition(AVDoc doc, ASInt16 newPosition)
Sets the splitter position. The splitter is the vertical division between the bookmark/thumbnail pane and the document pane. The default splitter location is saved in the Acrobat viewer's preferences file, and can be read and set using AVAppGetPreference() and AVAppSetPreference().
 
Sets the document's state to match the information in viewDef.
 
void AVDocSetViewDefEx(AVDoc doc, ASCab viewDef)
Sets the document's state to match the information in viewDef.
 
void AVDocSetViewMode(AVDoc doc, PDPageMode newMode)
Sets the current view mode.
 
Displays the current selection by calling the selection server's AVDocSelectionShowSelectionProc() callback. It does nothing if the document has no selection, or the current selection's server has no AVDocSelectionShowSelectionProc() callback.
 
void AVDocWantsToDie(AVDoc doc, void* clientData)
An AVDoc object's file stream has been terminated by The AVDocSetDead() method.
 
void AVDocWillClearSelection(AVDoc doc, ASAtom selType, void* selData, void* clientData)
A document's selection is about to be cleared.
 
void AVDocWillClose(AVDoc doc, void* clientData)
An AVDoc will be closed. Neither this notification nor AVDocDidClose() are broadcast if the user selects Cancel when prompted to save a modified document as it is closed.
 
void AVDocWillOpenFromFile(ASPathName fileName, ASFileSys fileSys, void* clientData)
An AVDoc will be opened from a file.
 
void AVDocWillOpenFromPDDoc(PDDoc pdDoc, void* clientData)
An AVDoc will be opened from a PDF file.
 
void AVDocWillPerformAction(AVDoc doc, PDAction action, void* clientData)
An action is about to be performed.
 
void AVDocWillPrint(AVDoc doc, void* clientData)
This notification is broadcast before a document is printed, before any marks are made on the first page.
 
void AVDocWillRefreshUI(AVDoc doc, void* clientData)
The UI is doing a full refresh (rebuild and relayout) as done in AVUIEnvironment::RefreshUI, so notify any AVDoc with components that will be affected by a the UI refresh. Currently (as of 8/24/12) this type of refresh is only done for updates related to Touch and Accesibility preferences.
 
void AVDocWindowWasAdded(AVDoc doc, AVWindow window, void* clientData)
A new window was created for a document. This will be called for all windows created for a document, including the initial window. It will arrive before AVDocDidOpen() .
 
void AVDocWindowWasRemoved(AVDoc doc, AVWindow window, void* clientData)
A window was removed from a document. This is called after the association between the window and document has been severed but before the window is destroyed.
Defines Detail
kAVDocSplitterPinnedLeft 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocSplitterPinnedLeft (0)

Description

Specifies a special value for AVDocSetSplitterPosition() and AVDocGetSplitterPosition().

See Also


File: AVExpT.h
Line: 2950
kAVDocSplitterPinnedRight 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocSplitterPinnedRight (ASMAXInt16)

Description

Specifies a special value for AVDocSetSplitterPosition() and AVDocGetSplitterPosition().

See Also


File: AVExpT.h
Line: 2958
kAVDocStatusKeyAlwaysInformText 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocStatusKeyAlwaysInformText PrefText"

File: AVExpT.h
Line: 10068
kAVDocStatusKeyDefaultsToChecked 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocStatusKeyDefaultsToChecked DefaultsToChecked"

File: AVExpT.h
Line: 10071
kAVDocStatusKeyHelpText 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocStatusKeyHelpText HelpText"

File: AVExpT.h
Line: 10067
kAVDocStatusKeyLargeIcon 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocStatusKeyLargeIcon LargeIcon"

File: AVExpT.h
Line: 10070
kAVDocStatusKeyName 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocStatusKeyName Name"

File: AVExpT.h
Line: 10065
kAVDocStatusKeySmallIcon 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocStatusKeySmallIcon SmallIcon"

File: AVExpT.h
Line: 10069
kAVDocStatusKeyTipText 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocStatusKeyTipText TipText"

File: AVExpT.h
Line: 10066
kAVDocViewDefKeyBringToFront 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyBringToFront "bringToFront"

Description

boolean


File: AVExpT.h
Line: 2184
kAVDocViewDefKeyOCGStates 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyOCGStates "ocgStates"

Description

cab


File: AVExpT.h
Line: 2262
kAVDocViewDefKeyOverViewMode 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyOverViewMode "overViewMode"

Description

int


File: AVExpT.h
Line: 2232
kAVDocViewDefKeyOverViewPos 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyOverViewPos "overViewPos"

Description

int


File: AVExpT.h
Line: 2237
kAVDocViewDefKeyOverViewX 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyOverViewX "overViewX"

Description

int


File: AVExpT.h
Line: 2242
kAVDocViewDefKeyOverViewY 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyOverViewY "overViewY"

Description

int


File: AVExpT.h
Line: 2247
kAVDocViewDefKeyPageViewBead 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewBead "pageViewBead"

Description

binary: PDBead


File: AVExpT.h
Line: 2227
kAVDocViewDefKeyPageViewLayoutMode 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewLayoutMode "pageViewLayoutMode"

Description

int


File: AVExpT.h
Line: 2189
kAVDocViewDefKeyPageViewPageNum 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewPageNum "pageViewPageNum"

Description

int


File: AVExpT.h
Line: 2194
kAVDocViewDefKeyPageViewStartThread 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewStartThread "pageViewStartThread"

Description

int


File: AVExpT.h
Line: 2217
kAVDocViewDefKeyPageViewThreadIndex 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewThreadIndex "pageViewThreadIndex"

Description

int


File: AVExpT.h
Line: 2222
kAVDocViewDefKeyPageViewX 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewX "pageViewX"

Description

int


File: AVExpT.h
Line: 2207
kAVDocViewDefKeyPageViewY 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewY "pageViewY"

Description

int


File: AVExpT.h
Line: 2212
kAVDocViewDefKeyPageViewZoom 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewZoom "pageViewZoom"

Description

int


File: AVExpT.h
Line: 2204
kAVDocViewDefKeyPageViewZoomType 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyPageViewZoomType "pageViewZoomType"

Description

int


File: AVExpT.h
Line: 2199
kAVDocViewDefKeyWindowFrame 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyWindowFrame "windowFrame"

Description

binary: AVRect


File: AVExpT.h
Line: 2252
kAVDocViewDefKeyWindowMaximized 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

#define kAVDocViewDefKeyWindowMaximized "windowMaximized"

Description

binary: AVRect


File: AVExpT.h
Line: 2257

Typedefs Detail
AVDoc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef struct _t_AVDoc* AVDoc;

A view of a PDF document in a window. There is one AVDoc per displayed document. Unlike a PDDoc, an AVDoc has a window associated with it.

See Also


File: AVExpT.h
Line: 1041
AVDocForceOpenOption 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocForceOpenOption AVDocForceOpenOption;

File: AVExpT.h
Line: 2492
AVDocOpenParams 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocOpenParams AVDocOpenParams;

File: AVExpT.h
Line: 2689
AVDocOpenParamsRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocOpenParams AVDocOpenParamsRec;

File: AVExpT.h
Line: 2689
AVDocPrintNupData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintNupData AVDocPrintNupData;

File: AVExpT.h
Line: 6571
AVDocPrintNupDataRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintNupData AVDocPrintNupDataRec;

File: AVExpT.h
Line: 6571
AVDocPrintOverrideData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintOverrideData AVDocPrintOverrideData;

File: AVExpT.h
Line: 6702
AVDocPrintOverrideDataRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintOverrideData AVDocPrintOverrideDataRec;

File: AVExpT.h
Line: 6702
AVDocPrintParams 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintParams AVDocPrintParams;

A structure that specifies how to print a document. It specifies rasterization parameters used by AVDocPrintParams. The constant DPI values are defined in AVExpT.h.

See Also


File: AVExpT.h
Line: 6712
AVDocPrintParamsRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintParams AVDocPrintParamsRec;

File: AVExpT.h
Line: 6980
AVDocPrintRasterizeData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintRasterizeData AVDocPrintRasterizeData;

File: AVExpT.h
Line: 6649
AVDocPrintRasterizeDataRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintRasterizeData AVDocPrintRasterizeDataRec;

File: AVExpT.h
Line: 6649
AVDocPrintSepsParams 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintSepsParams AVDocPrintSepsParams;

File: AVExpT.h
Line: 6984
AVDocPrintSepsParamsRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintSepsParams AVDocPrintSepsParamsRec;

File: AVExpT.h
Line: 7079
AVDocPrintTileData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintTileData AVDocPrintTileData;

File: AVExpT.h
Line: 6524
AVDocPrintTileDataRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocPrintTileData AVDocPrintTileDataRec;

File: AVExpT.h
Line: 6524
AVDocSaveParams 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocSaveParams AVDocSaveParams;

File: AVExpT.h
Line: 7552
AVDocSaveParamsRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocSaveParams AVDocSaveParamsRec;

File: AVExpT.h
Line: 7552
AVDocSelectionServer 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocSelectionServer AVDocSelectionServer;

File: AVExpT.h
Line: 2174
AVDocSelectionServerRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocSelectionServer AVDocSelectionServerRec;

File: AVExpT.h
Line: 2174
AVDocServerType 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocServerType AVDocServerType;

File: AVExpT.h
Line: 2941
AVDocViewDef 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocViewDef AVDocViewDef;

File: AVExpT.h
Line: 2355
AVDocViewDefRec 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

typedef _t_AVDocViewDef AVDocViewDefRec;

File: AVExpT.h
Line: 2355

Enumeration Detail
_t_AVDocForceOpenOption
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

enum _t_AVDocForceOpenOption {
 kDoNotForce
}

File: AVExpT.h
Line: 2484

_t_AVDocServerType 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

enum _t_AVDocServerType {
 AVDocServerUnknown,
 
 AVDocServerDefault,
 
 AVDocServerInternal = AVDocServerDefault,
 
 AVDocServerExternal,
 
 AVDocServerHelp
}

See Also


File: AVExpT.h
Line: 2930

Elements
AVDocServerUnknown  

Unknown server type.

 
AVDocServerDefault  

The default document server (used for most documents).

 
AVDocServerInternal  

The same as the default document server.

 
AVDocServerExternal  

Used for external documents, shown in a web browser.

 
AVDocServerHelp  

A server used for documents displayed in the help window.

AVDocOpenFlags 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

enum AVDocOpenFlags {
 kAVDocOpenWithNoFlags = 0x00000000,
 
 kAVDocOpenInNewWindow = 0x00000001
}

File: AVExpT.h
Line: 2497


Structure Detail
_t_AVDocOpenParams
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocOpenParams {
 ASSize_t size; 
 
 ASBool useFrame; 
 
 AVScreenRect frame; 
 
 ASBool useVisible; 
 
 ASBool visible; 
 
 ASBool useServerType; 
 
 const char* serverType; 
 
 void* serverCreationData; 
 
 ASBool useSourceDoc; 
 
 AVDoc sourceDoc; 
 
 ASBool useReadOnly; 
 
 ASBool readOnly; 
 
 ASBool useViewType; 
 
 const char* viewType; 
 
 ASBool useViewDef; 
 
 AVDocViewDef viewDef; 
 
 ASBool usePermReqProc; 
 
 AVDocPermReqProc permReqProc; 
 
 ASCab openActions; 
 
 ASBool suppressDialogs; 
 
 ASBool useCollectionPref; 
 
 ASBool collectionPref; 
 
 ASBool useMinimize; 
 
 ASBool minimize; 
 
 ASBool forceOpenProtectedView; 
 
 AVDocForceOpenOption forceOpenOption; 
 
 AVDocOpenFlags openFlags; 
}

Parameters used when opening a file.

In UNIX, it is not possible to set the frame of the NULL document (that is, the window to show when no document is open) using this data structure.

See Also


File: AVExpT.h
Line: 2517

Elements
size  

The size of the data structure. It must be set to sizeof( AVDocOpenParamsRec).

 
useFrame  

If true, frame is used to specify the size and location of the window into which the document is opened. If false, frame is ignored and the default frame is used instead. See also visible.

 
frame  

An AVRect specifying the size and location of the window into which the document is opened. On Mac OS, the coordinates are global screen coordinates. On Windows, the coordinates are MDI client coordinates. See also visible.

 
useVisible  

If true, visible is used to determine whether the window is visible after the document is opened. If false, visible is ignored. See also visible.

 
visible  

Specifies the window's visibility. If visible is false and useVisible is true, frame is ignored regardless of the setting of useFrame. On Mac OS, if true, the document is opened into a visible window. If false, the document is opened into a hidden window. On Windows, if true, the document is opened in a visible window. If false, the document is opened in a minimized window.

 
useServerType  

Indicates whether the serverType and serverCreationData fields are used.

 
serverType  

The name of the AVDoc server for this AVDoc: EXTERNAL means the AVDoc server for an external window.

 
serverCreationData  

Platform-dependent server data to associate with the AVDoc server. For a serverType of EXTERNAL, it must be of type ExternalDocServerCreationData.

 
useSourceDoc  

Indicates whether the sourceDoc field is used.

 
sourceDoc  

An AVDoc whose window will be taken over by a new document. sourceDoc will be closed at the same time.

 
useReadOnly  

Indicates whether the readOnly field is used.

 
readOnly  

If true, open the document in read-only mode.

 
useViewType  

Indicates whether the viewType field is used.

 
viewType  

The type of view to open for the document.

Permissible values:

Value

Description

"AVPageView"

Displays only the AVPageView, which is the window that displays the PDF file. It does not display scrollbars, the toolbar, or the bookmark or thumbnails pane. Annotations, such as links, are active.

"AVDocView"

Displays the AVPageView, scrollbars, and bookmark and thumbnails pane. Annotations, such as links, are active.

"AVExternalView"

Displays the AVPageView, scrollbars, toolbar, and bookmark or thumbnails pane. Annotations, such as links, are active.

"AVEmbeddedView"

Embeds the PDF file in an external document such as an HTML file. It shows the first page of the PDF file. No scrollbars are visible. The toolbar and bookmark or thumbnails pane are visible. Annotations, such as links, are neither displayed nor active.

 
useViewDef  

Indicates whether the viewDef field is used.

 
viewDef  

Initial view with which to open the document. It must be an AVDocViewDef.

 
usePermReqProc  

A boolean indicating whether the permReqProc field be used.

 
permReqProc  

Returns PDPermReqDenied to deny a permission, PDPermReqGranted to grant one.

 
openActions  

An expanded and more flexible version of the viewDef field. If both are specified, the older AVDocViewDef takes precedence.

 
suppressDialogs  

Indicates whether to suppress any non-alert dialog boxes that may be triggered by opening the document.

 
useCollectionPref  

A PDF 1.7+ file may contain a collection dictionary that specifies a target document, which is an embedded file within the host document that should be opened instead of the host. Assuming the caller is opening a collection document that specifies such a target document, the following applies:

  • If useCollectionPref is set to false, then collectionPref is ignored, and:

  • If useCollectionPref is true and collectionPref is true, then all APIs will open the target document, honoring the collection dictionary.

  • If useCollectionPref is true and collectionPref is false, then all APIs will open the host document, ignoring the collection dictionary.

AVDocOpenFromFileWithParams() and AVDocOpenFromPDDocWithParams() exhibit different default behavior since the expectation around opening an AVDoc from a file versus a PDDoc is different; a caller would be surprised if AVDocOpenFromPDDoc() did not return an AVDoc for that same PDDoc. The caller should generally set useCollectionPref to false unless special behavior is required.

 
useMinimize  

If true, minimize is used to determine whether the window is minimized after the document is opened. If false, minimize is ignored. See also minimize.

 
minimize  

Specifies the window's minimize state.

 
forceOpenProtectedView  

DEPRECATED in Acrobat 11. Use forceOpenOption.

 
forceOpenOption  

This parameter controls the mode in which PDF will open.

 
openFlags  

Flags to use while opening the AVDoc.

_t_AVDocPrintNupData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

N-up and booklet printing options for AVDocPrintParams. It is used in the call to AVDocPrintPagesWithParams().


File: AVExpT.h
Line: 6529

Elements
size  

Set this to be the size of this struct.

 
numPagesPerSheetH  

The number of pages on the horizontal direction of the page. The total number of pages per sheet is (numPagesPerSheetH * numPagesPerSheetV). It is ignored if the page scaling mode, pageSize, is kAVPageSizeBooklet.

 
numPagesPerSheetV  

The number of pages on the vertical direction of the page. The total number of pages per sheet is (numPagesPerSheetH * numPagesPerSheetV). It is ignored if the page scaling mode, pageSize, is kAVPageSizeBooklet.

 
pageOrder  

N-up page order. It is ignored if the page scaling mode, pageSize, is kAVPageSizeBooklet.

 
pageBorder  

Print page borders during N-up printing.

 
autoRotate  

Automatically rotate each page to match the page orientation to the available paper area.

 
bookletBinding  

Booklet page binding direction. It is ignored if the page scaling mode, pageSize, is not kAVPageSizeBooklet.

 
bookletDuplexMode  

Booklet duplex printing mode. It is ignored if the page scaling mode, pageSize, is not kAVPageSizeBooklet.

 
bookletSubsetFrom  

Booklet subset printing range: the first sheet (a valid sheet number starts from 0). If this value is -1, it represents the last sheet number. The default value is 0. It is ignored if the page scaling mode, pageSize, is not kAVPageSizeBooklet.

 
bookletSubsetTo  

Booklet subset printing range: the last sheet (a valid sheet number starts from 0). If this value is -1, it represents the last sheet number. The default value is -1. It is ignored if the page scaling mode, pageSize, is not kAVPageSizeBooklet.

_t_AVDocPrintOverrideData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocPrintOverrideData {
 ASSize_t size; 
 
 AVColorForcing colorOverride; 
 
 AVUseValue usePrinterCRD; 
 
 AVUseValue useT1Conversion; 
}

A structure specifying override parameters used by AVDocPrintParams.

See Also


File: AVExpT.h
Line: 6656

Elements
size  

The size of the data structure. It must be set to sizeof(AVDocPrintOverrideDataRec).

 
colorOverride  

Determines whether to use color forcing. The default is AVColorForceNone. It can be used to send 1-bit or 8-bit data to the printer, instead of 24-bit data. It is ignored on Mac OS.

 
usePrinterCRD  

Determines whether to allow the viewer to decide if it should use the printer's PostScript Color Rendering Dictionary. The default is kAVuseAuto, which is normally true. It is false when the printer is listed as broken, which occurs in these cases:

  • When printer-based color management is used, printers whose CRD is incorrect produce light gray or peach for white expressed in an ICC color space.

  • The CRDs for Xerox Phaser 740 and Xerox DocuPrint N2125 are known to be incorrect, and this may be so for others, especially in these printer families. It is possible to change the printer defaults such as listing additional printers, or to remove a printer from the broken list if the driver is fixed. Contact Adobe technical support for details.

 
useT1Conversion  

Determines whether to allow the viewer to decide if it should use T1 color conversion (that is, convert Type1 fonts to more efficient font representations) for better performance. It is ignored on Mac OS. The default is kAVuseAuto, which is normally true, except in cases where the printer cannot handle optimized fonts and needs full, slow, Type1 fonts. Only the Windows 16-bit HP LJ 4siMX driver is known to be in this category. It is possible to change the printer defaults such as listing additional printers, or to remove a printer from the broken list if the driver if fixed. Contact Adobe technical support for details.

_t_AVDocPrintParams 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocPrintParams {
 ASSize_t size; 
 
 ASBool interactive; 
 
 ASBool cancelDialog; 
 
 ASInt32 firstPage; 
 
 ASInt32 lastPage; 
 
 ASInt32 psLevel; 
 
 ASBool binaryOK; 
 
 ASBool shrinkToFit; 
 
 ASAtom fileSysName; 
 
 ASPathName filePathName; 
 
 ASPlatformPrinterSpec printerSpec; 
 
 ASBool embedded; 
 
 AVRect embeddedRect; 
 
 ASBool emitToPrinter; 
 
 ASBool emitToFile; 
 
 ASBool doColorSeparations; 
 
 ASEnum8 emitFileOption; 
 
 ASEnum8 emitFontOption; 
 
 ASUns32 emitFlags; 
 
 PDPageRange ranges; 
 
 AVTSmallArraySize numRanges; 
 
 ASBool TTasT42; 
 
 ASBool printAsImage; 
 
 ASBool printerHasFarEastFonts; 
 
 ASBool reverse; 
 
 ASInt32 pageSpec; 
 
 ASInt32 transparencyLevel; 
 
 char destProfile[256]; 
 
 AVPageSize pageSize; 
 
 AVDocPrintTileData tileData; 
 
 AVDocPrintRasterizeData rasterData; 
 
 AVDocPrintOverrideData overrideData; 
 
 ASFixedRect selectRect; 
 
 PDOCContext ocContext; 
 
 ASUTF16Val userNote[kPrintUserNoteLen]; 
 
 AVResourcePolicy resPolicy; 
 
 ASUns32 marksFlags; 
 
 AVDocPrintNupData nUpData; 
 
 ASInt32 marksStyle; 
 
 ASBool printDialogWasCancelled; 
 
 AVWindow parentWindow; 
 
 char proofProfile[256]; 
 
 char* ppdPath; 
 
 ASPathName customMarksFileName; 
 
 ASInt32 numCopies; 
 
 AVPrintDuplexType duplexType; 
 
 ASBool saveToner; 
}

A structure that specifies how to print a document.

See Also


File: AVExpT.h
Line: 6735

Elements
size  

The size of the data structure. It must be set to sizeof(AVDocPrintParamsRec).

 
interactive  

Displays a Print dialog box and print status window while printing. It is mutually exclusive with embedded, emitToPrinter, and emitToFile.

 
cancelDialog  

If interactive is false and cancelDialog is true, a Cancel dialog box appears.

 
firstPage  

The first page to be printed; a zero-based value. It is used if emitToPrinter or emitToFile is true. If -1, all pages are printed.

 
lastPage  

The last page to be printed. It is used if emitToPrinter or emitToFile is true. If firstPage is -1, this page is ignored.

 
psLevel  

Used if emitToPrinter or emitToFile is true. If printing to PostScript, 2 means level 2, 3 means level 3.

 
binaryOK  

Used if emitToPrinter or emitToFile is true. It is set to true if a binary channel to the printer is supported.

 
shrinkToFit  

Deprecated. Use pageSize instead.

Used if emitToPrinter or emitToFile is true. If pageSize is uninitialized and this is true, the page is shrunk or expanded to fit the printer page size.

 
fileSysName  

The file system name; see filePathName. It is used if emitToPrinter or emitToFile is true. For the operation of printing to a printer (emitToPrinter = true), if filePathName is specified, fileSysName must be the name of the default file system. You can get the file system's name from the ASFileSysGetFileSysNameProc() callback in the ASFileSysRec of the file system you are using.

 
filePathName  

Used if emitToPrinter or emitToFile is true. If non-NULL, filePathName is a platform path for the specified fileSysName, or, if fileSysName is ASAtomNull, it is one of the following:

Possible types:

Operating System

Type

Windows

A C-string path name.

Mac OS

An FSSpecPtr.

UNIX

A C-string path name.

If emitToPrinter is true and filePathName is non-NULL, the system printer driver is used to emit the output stream to the file. This is implemented for Windows only.

 
printerSpec  

Optionally used if interactive, embedded, or emitToPrinter is true. If it is NULL, a default system printer is used. If it is non-NULL, printerSpec is a platform-specific value. It must be an ASPlatformPrinterSpec.

 
embedded  

true if it is an embedded view of a page to print, false otherwise. It is mutually exclusive with interactive, emitToPrinter, and emitToFile. firstPage only is used. The last page is ignored. The printer must be specified as a metafile or a CGrafPtr.

 
embeddedRect  

The size of the embedded output in device units.

 
emitToPrinter  

If true, use the system printer driver for output. If filePathName is specified, it uses the driver to create the file. It raises genErrBadParm if an invalid parameter is provided (for example, printing to PDFWriter, Distiller, or to a printer that has been un-installed). It is mutually exclusive with interactive, embedded and emitToFile.

 
emitToFile  

If true, emit non-interactive output to a file. It is used to emit color separations or EPS. This flag cannot be used with the Adobe Reader. It is mutually exclusive with interactive, embedded and emitToPrinter.

 
doColorSeparations  

Perform level 1 color separations. See Color Separation Conventions for PostScript Language Programs, Technical Note #5044.

 
emitFileOption  

File output options: PostScript or EPS, with or without a preview.

Possible values:

Value

Description

kAVEmitFilePS

PostScript file.

kAVEmitFileEPSNoPrev

EPS file with no preview.

kAVEmitFileEPSMacStdPrev

EPS file with standard preview.

kAVEmitFileEPSMacExtPrev

EPS file with extended preview.

 
emitFontOption  

Font output options. It must be one of EmitFontOptions.

 
emitFlags  

Additional emit options, such as kAVEmitHalftones. It must be one of the Emit Flags.

 
ranges  

Must be a PDPageRange. It takes precedence over the firstPage and lastPage members.

 
numRanges  

The range of pages to print.

 
TTasT42  

If true, send TrueType fonts as TrueType fonts (level 3 and most level 2 PostScript printers). If false, convert TrueType to Type 1. This is typically only desirable for Level 1 PostScript where no TrueType handling is present.

 
printAsImage  

If true, print pages as an image.

 
printerHasFarEastFonts  

If true, do not download Far East fonts to the printer.

 
reverse  

Print from lastPage to firstPage.

 
pageSpec  

Indicates odd, even, or all pages to be printed within the range. It is only meaningful when the firstPage and lastPage parameters are used. It can be either PDAllPages, PDEvenPagesOnly, or PDOddPagesOnly.

 
transparencyLevel  

Deprecated. Set to 0 and use rasterData instead. The transparency level reflects the pull-down on the Advanced print dialog box for controlling how much rasterization should be performed when flattening transparent objects during printing.

Possible values:

Value

Description

1

The entire page will be rasterized. Use this setting for printing or exporting complex pages with many transparent objects. It is ideal for fast output at low resolution; higher resolution will yield higher quality but increase processing time. The size of saved files or print spool files may be large.

2

It maintains simpler vector objects, but rasterizes more complex areas involving transparency. It is ideal for artwork with only a few transparent objects. Some printers may yield rough transitions between bordering vector and raster objects and make hairlines appear thicker. It is appropriate for low memory systems.

3

It maintains most objects as vector data, but rasterizes very complex transparent regions. It is generally the best setting for printing and exporting most pages. With some printers, it improves transition issues between bordering vector and raster objects.

4

It maintains most of the page content as vectors, rasterizing only extremely complex areas. It produces high quality output that is generally resolution-independent. Higher occurrences of transparent regions will increase processing time. With some printers, it improves transition issues between bordering vector and raster objects.

5

The entire page is printed or exported as vector data, to the greatest extent possible. This produces the highest quality resolution-independent output. Processing of complex pages may be very time- and memory-intensive.

 
destProfile  

Represents the name of the destination profile to use when doing host-based color management.

 
tileData  

If NULL, it uses default values.

 
rasterData  

If NULL, it uses default values.

 
overrideData  

If NULL, it uses default values.

 
selectRect  

The area (in pts) of the page(s) to print. If NULL, print the whole page.

 
ocContext  

The optional content context to use. If NULL, use the current on-screen OC state, but apply print- specific AutoState changes from the default occonfig object's AS entry

 
userNote  

A short note to the user that appears in the print dialog box.

 
resPolicy  

A font and resource Policy, such as kAVResPolicySendAtStart. It must be one of AVResourcePolicy.

 
marksFlags  

Determines which printer marks should be emitted, such as kAVCropMarks and so on.

 
nUpData  

N-up printing control parameters. If NULL, it uses default values.

 
marksStyle  

When marksFlags is non-zero, use marksStyle to determine which printer mark style to use. See marksStyleType (makes kAVEasternStyleMarks obsolete)

 
printDialogWasCancelled  

Determines whether the user cancelled the print dialog box.

 
parentWindow  

The parent window of the dialog box (ignored on the Mac platform). It may be NULL.

 
proofProfile  

Represents the name of the proofing profile when doing proofing.

 
customMarksFileName  

If markStyle >= kLastMarkType, customMarksFileName should be a valid file name representing a valid .mrk file for custom printer marks.

 
numCopies  

Specify the number of copies with which to prepopulate the print dialog box. It may be ignored in certain cases.

 
duplexType  

Specify the duplex request.

 
saveToner  

Whether Lean print optimizations should be turned on.

_t_AVDocPrintRasterizeData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocPrintRasterizeData {
 ASSize_t size; 
 
 AVRasterizeFlags flags; 
 
 ASInt32 transparency; 
 
 ASUns32 bitmapResolution; 
 
 ASUns32 gradientResolution; 
 
 ASUns32 printAsImageResolution; 
}

A structure specifying rasterization parameters used by AVDocPrintParams. The constant DPI values are defined in AVExpT.h.

See Also


File: AVExpT.h
Line: 6624

Elements
size  

The size of the data structure. It must be set to sizeof(AVDocPrintRasterizeData).

 
flags  

An OR of the bit flags that control the rasterization method to use for printing.

 
transparency  

The degree of transparency in the range 1 to 100, where 1 means all raster, and 100 means preserve as much transparency data as possible.

 
bitmapResolution  

The DPI for bitmaps. The default is 300. This value is also used when printAsImage is true.

 
gradientResolution  

The DPI for the gradient's interior to the object (not the edges). It can generally be lower than the bitmapResolution. The default is 150.

 
printAsImageResolution  

The default is 300.

_t_AVDocPrintSepsParams 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocPrintSepsParams {
 ASSize_t size; 
 
 AVDoc avDoc; 
 
 ASInt32 firstPage; 
 
 ASInt32 lastPage; 
 
 ASAtom fileSysName; 
 
 ASPathName filePathName; 
 
 ASEnum8 emitFileOption; 
 
 ASUns32 emitFlags; 
 
 AVPageSize pageSize; 
 
 AVDocPrintRasterizeData rasterData; 
 
 AVDocPrintOverrideData overrideData; 
 
 PDHostSepsSpec sepsSpec; 
 
 ASBool inRip; 
 
 ASInt32 trapType; 
 
 ASPlatformPrinterSpec printerSpec; 
}

A structure specifying color separation printing parameters used by AVDocPrintSeparations().

See Also


File: AVExpT.h
Line: 7005

Elements
size  

The size of the data structure. It must be set to sizeof(AVDocPrintSepsParamsRec).

 
avDoc  

The document for which to print color separations.

 
firstPage  

firstPage, lastPage, psLevel, binaryOk, and shrinkToFit are used if emitToPrinter or emitToFile is true. The first page to be printed. The first page number is 0. If -1, all pages are printed.

 
lastPage  

The last page to be printed. This is ignored if the firstPage is -1.

 
fileSysName  

The method creates an output file for each plate for each page, using the fileSysName for the file system, and the filePathName as the root file name for each file. It appends the page number followed by the colorant name to each output file name. If filePathName is not a valid path name to a file to which Acrobat can open and write, the method raises an exception using the value returned by ASFileSysOpenFile().

 
filePathName  

The method creates an output file for each plate for each page, using the fileSysName for the file system, and the filePathName as the root file name for each file. It appends the page number followed by the colorant name to each output file name. If filePathName is not a valid path name to a file to which Acrobat can open and write, the method raises an exception using the value returned by ASFileSysOpenFile().

 
emitFileOption  

Not used.

 
emitFlags  

Additional emit options. It must be one of the Emit Flags.

 
pageSize  

Not used.

 
rasterData  

NULL uses default values.

 
overrideData  

NULL uses default values.

 
sepsSpec  

The separations specification parameter structure.

 
inRip  

If true, generate in-RIP seps.

 
trapType  

For Acrobat 8, trapType controls the type of trapping desired.

 
printerSpec  

Optionally used if interactive, embedded, or emitToPrinter is true. If it is NULL, a default system printer is used. If it is non-NULL, printerSpec is a platform-specific value. It must be an ASPlatformPrinterSpec.

_t_AVDocPrintTileData 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocPrintTileData {
 ASSize_t size; 
 
 ASUns32 overlap; 
 
 ASFixed scale; 
 
 ASBool label; 
 
 AVTileMark markType; 
}

For AVDocPrintParams - used in the call AVDocPrintPagesWithParams().


File: AVExpT.h
Line: 6513

Elements
size  

Set this to be the size of this struct.

 
overlap  

The distance that tiles overlap in points.

 
scale  

A value of 1.0 indicates normal scale.

 
markType  

Uses the AVTileMark enum.

_t_AVDocSaveParams 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocSaveParams {
 ASSize_t size; 
 
 ASBool useSaveDialog; 
 
 ASBool dontAllowConversions; 
 
 const char* filterID; 
 
 ASBool useDefaults; 
}

A structure used by AVDocDoSaveAsWithParams() containing parameters that a client wishing to save a file might want to specify. It is passed in by address to AVDocDoSaveAsWithParams() with a size field so that current clients replacing AVDocDoSaveAsWithParams() will not break in the future if new open specifications are provided.

See Also


File: AVExpT.h
Line: 7536

Elements
size  

The size of the data structure. It must be set to sizeof(AVDocSaveParamsRec).

 
useSaveDialog  

Use the standard file Save dialog box.

 
dontAllowConversions  

(Acrobat 5.0 and later) Do not use "convert from PDF" handlers.

 
filterID  

The ID of the default filter (NULL means PDF).

 
useDefaults  

Bypass the dialog box and use the default path, etc.

_t_AVDocSelectionServer 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

struct _t_AVDocSelectionServer {
 ASSize_t size; 
 
 AVDocSelectionGetTypeProc GetType; 
 
 AVDocSelectionGettingSelectionProc GettingSelection; 
 
 AVDocSelectionAddedToSelectionProc AddedToSelection; 
 
 AVDocSelectionLosingSelectionProc LosingSelection; 
 
 AVDocSelectionRemovedFromSelectionProc RemovedFromSelection; 
 
 AVDocSelectionCanSelectAllProc CanSelectAll; 
 
 AVDocSelectionSelectAllProc SelectAll; 
 
 AVDocSelectionCanPropertiesProc CanProperties; 
 
 AVDocSelectionPropertiesProc Properties; 
 
 AVDocSelectionCanDeleteProc CanDelete; 
 
 AVDocSelectionDeleteProc Delete; 
 
 AVDocSelectionCanCopyProc CanCopy; 
 
 AVDocSelectionCopyProc Copy; 
 
 AVDocSelectionEnumSelectionProc EnumSelection; 
 
 AVDocSelectionShowSelectionProc ShowSelection; 
 
 AVDocSelectionCanCutProc CanCut; 
 
 AVDocSelectionCutProc Cut; 
 
 AVDocSelectionCanPasteProc CanPaste; 
 
 AVDocSelectionPasteProc Paste; 
 
 AVDocSelectionKeyDownProc KeyDown; 
 
 AVDocSelectionHighlightSelectionProc HighlightSelection; 
 
 AVDocSelectionGetSelectionTypeProc GetSelectionType; 
 
 AVDocSelectionEnumPageRangesProc EnumPageRanges; 
 
 AVDocSelectionGetAVRectProc GetAVRect; 
 
 AVDocSelectionShowMenuProc ShowMenu; 
 
 AVDocSelectionHighlightSelectionExProc HighlightSelectionEx; 
 
 AVDocSelectionAcquireQuadsProc AcquireQuads; 
 
 AVDocSelectionCanPasteFromPlatformProc CanPasteFromPlatform; 
 
 AVDocSelectionPasteFromPlatformProc PasteFromPlatform; 
 
 AVDocSelectionUnicodeKeyDownProc UnicodeKeyDown; 
 
 ASAtom Type; 
}

A data structure containing callbacks that implement a selection server. The callbacks implement the selection server functions. For example, they can add an item to the selection, remove an item from the selection, or copy the current selection to the clipboard.

See Also


File: AVExpT.h
Line: 2067

Elements
size  

The size of the data structure. It must be set to sizeof(AVDocSelectionServerRec).

 
GetType  

Obsolete. Use the Type field instead.

 
GettingSelection  

Highlight the seclection.

 
AddedToSelection  

Add the item to the selection.

 
LosingSelection  

De-highlight the selection.

 
RemovedFromSelection  

Remove the item from the selection.

 
CanSelectAll  

Determine whether the current selection type can perform a select all operation.

 
SelectAll  

Select all items of the current type.

 
CanProperties  

Determine whether the current selection has user-specified properties.

 
Properties  

Display the set properties user interface.

 
CanDelete  

Determine whether the current selection can be deleted.

 
Delete  

Delete the current selection.

 
CanCopy  

Determine whether the current selection can be copied.

 
Copy  

Copy the selected item to the clipboard.

 
EnumSelection  

Enumerates the current selection.

 
ShowSelection  

Change the view so that the current selection is visible.

 
CanCut  

Determine whether the current selection can be cut.

 
Cut  

Cut the current selection.

 
CanPaste  

Determine whether the current selection can be pasted.

 
Paste  

Paste the current selection from the clipboard.

 
KeyDown  

Handles a key press.

 
HighlightSelection  

Highlight the selection.

 
GetSelectionType  

Get the selection type so that a single selection server can register different selection types based on the selection data.

 
EnumPageRanges  

Allow enumeration of the set of pages the selection covers.

 
GetAVRect  

Identify the bounding rectangle of a selection.

 
ShowMenu  

Request that the selection server display a context menu appropriate for the current selection.

 
HighlightSelectionEx  

Highlight the selection.

 
AcquireQuads  

Get a quad-based region for the selection.

 
CanPasteFromPlatform  

Determine whether a selection can be pasted.

 
PasteFromPlatform  

Paste the selection.

 
UnicodeKeyDown  

Handles a key press using Unicode values.

 
Type  

The selection type.

_t_AVDocViewDef 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

A structure that defines a view of a document, including page, zoom, and so on.

See Also


File: AVExpT.h
Line: 2280

Elements
size  

The size of the data structure. It must be set to sizeof( AVDocViewDef).

 
bringToFront  

If true, bring the window to the front; if false, do not bring the window to the front.

 
usePageViewInfo  

If true, use the next 6 page view fields. If false, do not use them.

 
pageViewLayoutMode  

The page layout mode; it must be one of PDLayoutMode.

 
pageViewPageNum  

The page number.

 
pageViewZoomType  

The zoom type; it must be one of AVZoomType.

 
pageViewZoom  

The zoom factor; it is used if pageViewZoomType is AVZoomNoVary. Use zero to inherit the zoom.

 
pageViewX  

The x-coordinate to scroll to.

 
pageViewY  

The y-coordinate to scroll to.

 
pageViewStartThread  

If true, use the next two article thread fields. If false, do not use them.

 
pageViewThreadIndex  

The current thread index.

 
pageViewBead  

The current PDBead.

 
useOverViewInfo  

If true, use the next four view fields. If false, do not use them.

 
overViewMode  

The PDPageMode to use.

 
overViewPos  

The position of the splitter.

 
overViewX  

The x-coordinate to scroll to in the bookmark or thumbnail pane.

 
overViewY  

The y-coordinate to scroll to in the bookmark or thumbnail pane.

 
useWindowInfo  

If true, use the windowFrame field. If false, do not use it.

 
windowFrame  

The new window frame in which to display the document.

 
windowMaximized  

Is the window frame maximized.

 
unused2  

Currently unused.

Callbacks Detail
AVDocEnumProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocEnumProc)(AVDoc doc, void *clientData)

A callback used by AVAppEnumDocs(). It is called once for each open AVDoc.

See Also


File: AVExpT.h
Line: 1542
AVDocPermReqProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

PDPermReqStatus (*AVDocPermReqProc)(AVDoc doc, PDPermReqObj obj, PDPermReqOpr opr)

A callback that can be associated with an AVDoc when it is opened (via an AVDocOpenParamsRec). It can restrict the set operations allowed on the document. When AVDocPermRequest() is called, this callback must be consulted to deny or grant the permission. If it denies permission, AVDocPermRequest() will also deny permission. If it grants permission, the security handler for the document will be consulted to determine the result of AVDocPermRequest(). This callback can only deny permissions allowed by the security handler; it cannot grant permissions that the security handler does not grant.


File: AVExpT.h
Line: 2418
AVDocSelectionAcquireQuadsProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASArraySize (*AVDocSelectionAcquireQuadsProc)(AVDoc doc, void *data, ASInt32 pageNum, ASFixedQuad **quads)

A callback for AVDocSelectionServer that gets a quad-based region for the selection.


File: AVExpT.h
Line: 2012
AVDocSelectionAddedToSelectionProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void * (*AVDocSelectionAddedToSelectionProc)(AVDoc doc, void *curData, void *addData, ASBool highlight)

A callback for AVDocSelectionServer that adds the specified item to the selection, highlights it, and returns the new selection containing the newly-added item.

See Also


File: AVExpT.h
Line: 1635
AVDocSelectionCanCopyProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCanCopyProc)(AVDoc doc, void *selData)

A callback for AVDocSelectionServer. It is used to determine whether the current selection can be copied. This controls, for example, whether the Copy menu item is enabled.

The Copy menu item is only enabled if the selection server's AVDocSelectionCanCopyProc() returns true and the selection server has an AVDocSelectionCopyProc().

See Also


File: AVExpT.h
Line: 1768
AVDocSelectionCanCutProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCanCutProc)(AVDoc doc, void *data)

A callback for AVDocSelectionServer. It is used to determine whether the current selection can be cut. This controls, for example, whether the Cut menu item is enabled.

The Cut menu item is only enabled if the selection server's AVDocSelectionCanCutProc() returns true and the selection server has an AVDocSelectionCutProc().

See Also


File: AVExpT.h
Line: 1836
AVDocSelectionCanDeleteProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCanDeleteProc)(AVDoc doc, void *selData)

A callback for AVDocSelectionServer. It is used to determine whether the current selection can be deleted. This controls, for example, whether the Delete menu item is enabled.

The Delete menu item is only enabled if the selection server's AVDocSelectionCanDeleteProc() returns true and the selection server has an AVDocSelectionDeleteProc().

See Also

AVDocSelectionCanDeleteProc
AVDocDeleteSelection

File: AVExpT.h
Line: 1741
AVDocSelectionCanPasteFromPlatformProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCanPasteFromPlatformProc)(AVDoc doc)

Determines whether a selection can be pasted.


File: AVExpT.h
Line: 2018
AVDocSelectionCanPasteProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCanPasteProc)(AVDoc doc)

A callback for AVDocSelectionServer. It is used to determine whether the current selection can be pasted. This controls, for example, whether the Paste menu item is enabled.

The Paste menu item is only enabled if the selection server's AVDocSelectionCanPasteProc() returns true and the selection server has an AVDocSelectionPasteProc().

See Also


File: AVExpT.h
Line: 1864
AVDocSelectionCanPropertiesProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCanPropertiesProc)(AVDoc doc, void *selData)

A callback for AVDocSelectionServer. It is used to determine whether the current selection has user-specified properties. This controls whether the Properties menu item is enabled.

The Properties menu item will not be enabled if the selection server does not have a AVDocSelectionPropertiesProc() callback.

See Also


File: AVExpT.h
Line: 1711
AVDocSelectionCanSelectAllProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCanSelectAllProc)(AVDoc doc, void *selData)

A callback for AVDocSelectionServer. It is used to determine whether the current selection type can perform a select all operation. This controls whether the Select All menu item is enabled.

See Also


File: AVExpT.h
Line: 1684
AVDocSelectionCopyProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCopyProc)(AVDoc doc, void *selData)

A callback for AVDocSelectionServer. It copies the selected item to the clipboard. The Acrobat viewer will have already cleared the clipboard and placed some private data onto it, in order to identify the selection server that put data on the clipboard. Because of this, a plug-in must not clear the clipboard, and should only add its private data. In addition, if the current selection can be reasonably represented as text, plug-ins are strongly encouraged to place a text representation of the selection onto the clipboard, in addition to their own private format.

See Also

AVDocCopySelection
UnixAppClipboardGetItemId

File: AVExpT.h
Line: 1787
AVDocSelectionCutProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionCutProc)(AVDoc doc, void *data)

A callback for AVDocSelectionServer. It cuts the current selection. See the discussion under AVDocSelectionCopyProc() for information on how the selection server must use the clipboard.

See Also

UnixAppClipboardGetItemId

File: AVExpT.h
Line: 1847
AVDocSelectionDeleteProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionDeleteProc)(AVDoc doc, void *selData)

A callback for AVDocSelectionServer. It deletes the current selection.

See Also


File: AVExpT.h
Line: 1751
AVDocSelectionEnumPageRangesProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionEnumPageRangesProc)(AVDoc doc, void *selectionData, AVSelectionPageRangeEnumProc enumProc, void *clientData)

A callback for AVDocSelectionServer. It allows enumeration of the set of pages the selection covers.

See Also


File: AVExpT.h
Line: 1951
AVDocSelectionEnumSelectionProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionEnumSelectionProc)(AVDoc doc, void *data, AVSelectionEnumProc proc, void *clientData)

(Optional) A callback for AVDocSelectionServer. It is called by AVDocEnumSelection(). This callback enumerates the current selection, calling the specified AVSelectionEnumProc() for each item in the selection (the selection server is free to decide what constitutes an item).

If omitted, the selection is enumerated by calling proc once, passing the entire selection to it.

See Also


File: AVExpT.h
Line: 1809
AVDocSelectionGetAVRectProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionGetAVRectProc)(AVDoc doc, PDPageNumber pageNo, AVDevRect *rect, void *data)

Called to identify the bounding rectangle of a selection. It is used by the Info palette to display the width and height of the selection.

Rectangle coordinates are in device space.


File: AVExpT.h
Line: 1972
AVDocSelectionGetSelectionTypeProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASAtom (*AVDocSelectionGetSelectionTypeProc)(AVDoc doc, void *data)

A callback for AVDocSelectionServer. It provides a way for a single selection server to register different selection types based on the selection data. If this callback is not supplied, the selection type defaults to the return value from AVDocSelectionGetTypeProc().

This callback does not affect existing selection servers.

See Also


File: AVExpT.h
Line: 1933
AVDocSelectionGettingSelectionProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionGettingSelectionProc)(AVDoc doc, void *selData, ASBool highlight)

A callback for AVDocSelectionServer. It is called when the selection is set (for example, via AVDocSetSelection() ).

In addition to its other functionality, this callback must also highlight the specified selection, if requested, using the selection server's AVDocSelectionHighlightSelectionProc() callback.

See Also


File: AVExpT.h
Line: 1610
AVDocSelectionGetTypeProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASAtom (*AVDocSelectionGetTypeProc)(void)

A callback for AVDocSelectionServer. It returns the selection type this server handles (for example, 'Text' or 'Bookmark'). This information is used so that the Acrobat viewer knows which selection server to call.

See Also


File: AVExpT.h
Line: 1595
AVDocSelectionHighlightSelectionExProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionHighlightSelectionExProc)(AVDoc doc, AVPageView pageView, void *data)

File: AVExpT.h
Line: 1916
AVDocSelectionHighlightSelectionProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionHighlightSelectionProc)(AVDoc doc, void *data)

(Previously known as AVDocHighlightSelectionProc) Callback for AVDocSelectionServer. It highlights the selection. This method is unnecessary if the selection type highlights itself (as in the case of annotations).

See Also


File: AVExpT.h
Line: 1909
AVDocSelectionKeyDownProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionKeyDownProc)(AVDoc doc, void *data, AVKeyCode key, AVFlagBits16 flags)

(Optional) A callback for AVDocSelectionServer. It handles a key press. It is needed only if the selection server processes key presses.


File: AVExpT.h
Line: 1891
AVDocSelectionLosingSelectionProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionLosingSelectionProc)(AVDoc doc, void *selData, ASBool highlight)

A callback for AVDocSelectionServer. This method is called by AVDocClearSelection (among others), to let the selection server responsible for the old selection do whatever cleanup it needs.

In addition to its other functionality, it must de-highlight the specified selection (if requested), using the selection server's AVDocSelectionHighlightSelectionProc() callback.

See Also


File: AVExpT.h
Line: 1653
AVDocSelectionPasteFromPlatformProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionPasteFromPlatformProc)(AVDoc doc)

Paste the selection.


File: AVExpT.h
Line: 2024
AVDocSelectionPasteProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionPasteProc)(AVDoc doc)

A callback for AVDocSelectionServer. It pastes the current selection from the clipboard.

See Also


File: AVExpT.h
Line: 1874
AVDocSelectionPropertiesProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionPropertiesProc)(AVDoc doc, void *selData)

(Optional) A callback for AVDocSelectionServer that displays the set properties user interface, if any, for the selection server and lets the user set the server's properties. This callback is not needed unless the selection server has properties that can be set by the user (for example, text highlight color). This callback is called by AVDocDoSaveAsWithParams().

See Also


File: AVExpT.h
Line: 1725
AVDocSelectionRemovedFromSelectionProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void * (*AVDocSelectionRemovedFromSelectionProc)(AVDoc doc, void *curData, void *remData, ASBool highlight)

A callback for AVDocSelectionServer that de-highlights the old item given in remData, and returns a new curData or NULL if failure occurred.

See Also


File: AVExpT.h
Line: 1671
AVDocSelectionSelectAllProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void * (*AVDocSelectionSelectAllProc)(AVDoc doc, void *selData)

A callback for AVDocSelectionServer that selects all items of the current type.

See Also


File: AVExpT.h
Line: 1695
AVDocSelectionShowMenuProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionShowMenuProc)(AVDoc doc, void *data, AVDevCoord x, AVDevCoord y)

Called to request that the selection server display a context menu appropriate for the current selection.

The given coordinates provide a suggested location for displaying the menu and are in device space for the current AVPageView.


File: AVExpT.h
Line: 1991
AVDocSelectionShowSelectionProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void (*AVDocSelectionShowSelectionProc)(AVDoc doc, void *data)

A callback for AVDocSelectionServer. It changes the view (for example, by scrolling the current page or moving to the appropriate page) so that the current selection is visible.

See Also


File: AVExpT.h
Line: 1820
AVDocSelectionUnicodeKeyDownProc 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool (*AVDocSelectionUnicodeKeyDownProc)(AVDoc doc, void *data, ASCount numUTF16Vals, const ASUTF16Val *utf16Vals, AVFlagBits16 flags)

(Optional) A callback for AVDocSelectionServer. It handles a key press using Unicode values. It is needed only if the selection server processes key presses.

If this callback is provided, all key events will be passed to it; the KeyDown callback will never be called.

The application may pass several Unicode characters to the UnicodeKeyDown callback. For example, if the user invokes an IME to compose a string of text, the entire text string may be passed to the UnicodeKeyDown callback at once. This behavior may also vary across platforms. If the callback returns true the application assumes the selection server processed all of the characters; if the callback returns false the viewer assumes the selection server processed none of the characters.


File: AVExpT.h
Line: 2054

Method Detail
AVDocActivePageViewDidChange()
Product availability: All
Platform availability: All

Syntax

void AVDocActivePageViewDidChange(AVDoc avDoc, AVPageView newPageView, AVPageView oldPageView, void* clientData)

Called when the document's page view changes.

Parameters

avDoc — 

The AVDoc whose page view has changed.

 
newPageView — 

The new AVPageView.

 
oldPageView — 

The old AVPageView.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 2164
AVDocAlert() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASInt32 AVDocAlert(AVDoc doc, AVIconType iconType, const char* msg, const char* button1, const char* button2, const char* button3, ASBool beep)

Displays an alert containing the specified message, icon, and one to three buttons with the specified titles. See AVAlert for more information.

On the Windows platform, the modal parent for doc (as returned by WinAppGetModalParent()) is used as the owner window of the message dialog box. As such, this method can be used to display alert dialog boxes in the context of an external window that is a web browser.

Rules for the buttons:

Parameters

doc — 

(Windows only) The AVDoc whose modal parent is used as the owner window of the message dialog box.

 
iconType — 

The icon to display. It must be one of the AVAlert Icons. Mac users: These constants are defined as per the standard Mac user interface guidelines.

 
msg — 

The message to display.

 
button1 — 

IN The title for the first button; it cannot be NULL.

 
button2 — 

IN The title for the second button; it may be NULL (if so, button3 is not displayed).

 
button3 — 

IN The title for the third button; it may be NULL.

 
beep — 

IN Pass true to perform a system beep when the alert is shown.

Returns

The button number (1, 2, or 3) on which the user clicked.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 4312
AVDocAlertConfirm() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocAlertConfirm(AVDoc doc, const char* msg)

Displays a dialog box containing the ALERT_CAUTION icon, the specified message, and OK and Cancel buttons. The method also performs a system beep. See AVDocAlert() for more information.

Parameters

doc — 

IN/OUT (Windows only) The AVDoc whose modal parent is used as the owner window of the message dialog box.

 
msg — 

IN/OUT The message to display.

Returns

true if the user clicked OK, false if the user clicked Cancel.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 4343
AVDocAlertNote() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocAlertNote(AVDoc doc, const char* msg)

Displays a dialog box containing the ALERT_NOTE icon, the specified message and an OK button. The method also performs a system beep. See AVDocAlert() for more information.

Parameters

doc — 

IN/OUT (Windows only) The AVDoc whose modal parent is used as the owner window of the message dialog box.

 
msg — 

IN/OUT The message to display.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 4326
AVDocAlertYesNo() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASInt32 AVDocAlertYesNo(AVDoc doc, AVIconType iconType, const char* msg, ASBool cancel, ASBool beep)

Displays a dialog box containing the specified message, icon, and two or three buttons with the titles Yes, No, and (optionally) Cancel. See AVDocAlert() for more information.

Parameters

doc — 

IN/OUT (Windows only) The AVDoc whose modal parent is used as the owner window of the message dialog box.

 
iconType — 

IN/OUT The icon to display. It must be one of the AVAlert Icons. Mac users: These constants are defined as per the standard Mac user interface guidelines.

 
msg — 

IN/OUT The message to display.

 
cancel — 

IN/OUT true if a Cancel button should be provided, false otherwise.

 
beep — 

IN/OUT true if it beeps, false otherwise.

Returns

The button number (1, 2, or 3) on which the user clicked.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 4368
AVDocApplyRedactions() 
Product availability: Acrobat
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocApplyRedactions(AVDoc avDoc, PDApplyRedactionParams applyParams, ASBool showConfirmation, ASBool showWarnings, ASBool showErrors)

Applies a set of redaction marks to the document, permanently removing the affected document content and the marks themselves.

Parameters

avDoc — 

IN/OUT The document to which the redaction marks should be applied.

 
applyParams — 

IN/OUT A pointer to a PDApplyRedactionParams object, specifying which redaction marks to apply and what parameters to use when applying them. If this parameter is NULL, all redaction marks present in the document will be applied.

 
showConfirmation — 

IN A boolean value indicating that a confirmation dialog should be presented to the user before beginning the application process.

 
showWarnings — 

IN A boolean value indicating that warning dialogs should be displayed.

 
showErrors — 

IN A boolean value indicating that error dialogs should be displayed.

Returns

true if the document's content was changed, false otherwise.

See Also

Exceptions

pdErrBadAnnotation is raised if any specified redaction marks are invalid.

File: AVProcs.h
Line: 9890
AVDocAVWindowDidChange() 
Product availability: All
Platform availability: All

Syntax

void AVDocAVWindowDidChange(AVDoc doc, AVWindow oldWindow, AVWindow newWindow, void* clientData)

The active window associated with a document has changed. This is the window returned by AVDocGetAVWindow() .

Parameters

doc — 

The document.

 
oldWindow — 

The previous active window for the document (which may be NULL).

 
newWindow — 

The new active window for the document.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also


File: PIPokes.h
Line: 2584
AVDocBeginUndoOperation() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocBeginUndoOperation(AVDoc doc)

Begins an undo group for the document. To create an undo group, call this method, create each instance with its handler and data, and call AVDocEndUndoOperation().

All AVUndo objects that are added to a group are presented in the user interface as a single undo operation. Undo groups that are nested in other groups are considered part of the parent group.

Parameters

doc — 

The document whose undo group is started.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 8730
AVDocBringToFront() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocBringToFront(AVDoc doc)

Brings the specified document to front. i.e. Makes its window and main view visible.

Parameters

doc — 

The AVDoc to bring to front.

Returns

TRUE if doc was successfully brought to front. FALSE otherwise.

Since

PI_ACROVIEW_VERSION >= 0x000C0003

File: AVProcs.h
Line: 10332
AVDocClearSelection() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocClearSelection(AVDoc doc, ASBool highlight)

Clears and destroys the current selection by calling the appropriate selection server's AVDocSelectionLosingSelectionProc().

Parameters

doc — 

IN/OUT The document whose selection is cleared.

 
highlight — 

IN/OUT Pass true to instruct the Acrobat viewer to remove the selection's highlighting, if it has not already been removed. The selection handler may only mark the highlighted regions of the display as invalid, but does not force an immediate redraw of the page view. Use AVPageViewDrawNow() to force an immediate redraw if you wish.

Returns

true if the current selection was cleared, false otherwise.

See Also

Notifications

Broadcasts AVDocWillClearSelection() if the selection type is not ASAtomNull.

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1170
AVDocClearUndos() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocClearUndos(AVDoc doc)

Clears the entire undo list for the AVDoc and releases all associated AVUndo objects.

Parameters

doc — 

The document whose undo list is cleared.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 8691
AVDocClose() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocClose(AVDoc doc, ASBool noSave)

Closes the document window, optionally prompting the user to save the document if it has been modified. When this method closes the AVDoc, it also closes the underlying PDDoc.

You can replace this method with your own version, using HFTReplaceEntry().

Parameters

doc — 

IN/OUT The document to close.

 
noSave — 

IN/OUT If true, the document is closed without prompting the user and without saving, even if the document has been modified. Because this can cause data loss without user approval, use this feature judiciously. If false, it prompts the user to save the document if it has been modified.

Returns

true if the document closed, false if it did not (for example, if the user was prompted with the Save dialog box and chose Cancel). The document will always close if noSave is true.

See Also

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 889
AVDocCopyAction() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

PDAction AVDocCopyAction(AVDoc fromDoc, PDAction anAction, AVDoc toDoc)

Makes a copy of the action for the (possibly different) specified AVDoc. It calls the AVActionCopyProc() callback in AVActionHandlerProcs.

It raises the standard exceptions if memory limit problems occur.

Parameters

fromDoc — 

IN/OUT The document containing the action.

 
anAction — 

IN/OUT The PDAction to copy.

 
toDoc — 

IN/OUT The document to which the action is copied.

Returns

A copy of the action.

Exceptions

avErrBadActionCopy is raised if the associated action handler has not implemented the AVActionCopyProc() callback.
pdErrBadAction is raised if the action dictionary is invalid.
pdErrOpNotPermitted is raised if the user does not have the required permissions level for destDoc to perform this operation.

Since

PI_ACROVIEW_VERSION >= 0x00020003

File: AVProcs.h
Line: 3837
AVDocCopyActionCommon() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

PDAction AVDocCopyActionCommon(AVDoc fromDoc, PDAction anAction, AVDoc toDoc)

Makes a copy of the action for the (possibly different) specified AVDoc.

This copy includes only those fields that are described in the PDF Reference as common to all actions (this list currently includes Type, S, and Next). This method is a proper starting point for the design of a Copy method for a custom action. This allows a client to concentrate on those member objects specific to the custom action.

It raises the standard exceptions if memory limit problems occur.

Parameters

fromDoc — 

The document containing the action.

 
anAction — 

The PDAction to copy.

 
toDoc — 

The document to which the action is copied.

Returns

A copy of the action.

Since

PI_ACROVIEW_VERSION >= 0x00020003

File: AVProcs.h
Line: 3859
AVDocCopyAdditionalActions() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocCopyAdditionalActions(AVDoc avFr, CosObj coFr, AVDoc avTo, CosObj coTo)

Copies any additional actions (AA) from a Cos Dictionary to a Cos Dictionary in the (possibly different) specified AVDoc.

This method copies the following keys: E, X, D, U, O, C, FP, PP, NP, and LP. This method is designed to aid clients in copying additional actions for pages.

For copying annotations, it is better to use AVDocCopyAnnotCommon().

This method raises the standard exceptions if memory limit problems occur.

Parameters

avFr — 

The document containing srcDict.

 
coFr — 

The dictionary from which the action is copied.

 
avTo — 

The document to which the action is copied.

 
coTo — 

The dictionary to which the action is copied.

Exceptions

cosErrExpectedDict is raised if the object stored under the /AA key in srcDict is not a CosDict.

Since

PI_ACROVIEW_VERSION >= 0x00020003

File: AVProcs.h
Line: 3886
AVDocCopyAnnot() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

PDAnnot AVDocCopyAnnot(AVDoc fromDoc, PDAnnot anAnnot, AVDoc toDoc)

Makes a copy of the annotation for the (possibly different) specified AVDoc. It calls the AVAnnotHandlerCopyProc() callback in AVAnnotHandler.

Parameters

fromDoc — 

The document containing the annotation.

 
anAnnot — 

The annotation to copy.

 
toDoc — 

The document to which the annotation is copied.

Returns

A copy of the annotation.

Exceptions

avErrBadAnnotationCopy is raised if the associated annotation handler has not implemented the AVAnnotHandlerCopyProc() callback. It raises the standard exceptions if memory limit problems occur.

Since

PI_ACROVIEW_VERSION >= 0x00020003

File: AVProcs.h
Line: 3788
AVDocCopyAnnotCommon() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

PDAnnot AVDocCopyAnnotCommon(AVDoc fromDoc, PDAnnot anAnnot, AVDoc toDoc)

Makes a copy of the annotation for the (possibly different) specified AVDoc.

This copy includes only those fields that are described in the PDF Reference as common to all annotations (this list currently includes Type, Subtype, Rect, Border, C, T, M, F, H, AS, BS, and AA). This method is a proper starting point for the design of a Copy method for a custom annotation. This allows a client to concentrate on those member objects specific to the custom annotation.

It raises the standard exceptions if memory limit problems occur.

Parameters

fromDoc — 

The document whose annotation is copied.

 
anAnnot — 

The annotation to copy.

 
toDoc — 

The document to which the annotation is copied.

Returns

A copy of the annotation.

Since

PI_ACROVIEW_VERSION >= 0x00020003

File: AVProcs.h
Line: 3812
AVDocCopySelection() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocCopySelection(AVDoc doc)

Copies the current selection to the clipboard, if possible. The selection is copied if the selection server has a AVDocSelectionCopyProc() callback, and the selection server's AVDocSelectionCanCopyProc() callback returns true. If the selection server does not have a AVDocSelectionCanCopyProc() method, a default value of true is used.

The selection is copied by calling the selection server's AVDocSelectionCopyProc() callback.

It only raises those exceptions raised by the selection server's AVDocSelectionCopyProc() and AVDocSelectionCanCopyProc() callbacks.

Parameters

doc — 

IN/OUT The document whose selection is copied.

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1189
AVDocDeleteSelection() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocDeleteSelection(AVDoc doc)

Deletes the specified document's current selection, if possible. The selection is deleted if changing the selection is currently permitted, the selection server has an AVDocSelectionDeleteProc() callback, and the selection server's AVDocSelectionCanDeleteProc() callback returns true. If the selection server does not have a AVDocSelectionCanDeleteProc() callback, a default value of true is used.

The selection is deleted by calling the selection server's AVDocSelectionDeleteProc() callback.

It only raises those exceptions raised by the selection server's AVDocSelectionDeleteProc() and AVDocSelectionCanDeleteProc() callbacks.

Parameters

doc — 

IN/OUT The document whose selection is deleted.

Returns

true if the current selection was actually deleted, false otherwise.

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1144
AVDocDidActivate() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidActivate(AVDoc doc, void* clientData)

An AVDoc has activated. At the time this notification is broadcast, it is possible that the window being activated has not yet been brought to the front. For this reason, the AVAppFrontDocDidChange() notification is often more useful.

Parameters

doc — 

The document that was activated.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 146
AVDocDidAddToSelection() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidAddToSelection(AVDoc doc, ASAtom selType, void* selData, void* addData, void* clientData)

The document's selection has been added to or had something removed.

Parameters

doc — 

The document containing the selection.

 
selType — 

The ASAtom corresponding to the current selection type. See AVDocSetSelection() for a list of selection types.

 
selData — 

A pointer to the current selection data after the selection has been added. The format and contents of selData depend on selType.

 
addData — 

A pointer to the added selection data. The format and contents of addData depend on selType.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1191
AVDocDidClearSelection() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidClearSelection(AVDoc doc, void* clientData)

A document's selection has been cleared.

Parameters

doc — 

The document whose selection was cleared.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 2493
AVDocDidClickName() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidClickName(AVDoc doc, CosObj NameObj, void* clientData)

Acrobat executed an action to go to a named destination.

Parameters

doc — 

The document containing the named destination.

 
NameObj — 

The Cos object corresponding to the named destination.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .


File: PIPokes.h
Line: 1635
AVDocDidClose() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidClose(AVDoc doc, void* clientData)

A document has been closed. Although An AVDoc is passed to the routine called by this notification, the document has already been closed but not freed. As a result, all the routine can really do is manipulate any private data in the underlying PDF file at the time this notification occurs.

Parameters

doc — 

The document that was closed.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

Notifications


File: PIPokes.h
Line: 196
AVDocDidDeactivate() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidDeactivate(AVDoc doc, void* clientData)

A document was deactivated.

Parameters

doc — 

The document that was deactivated.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 166
AVDocDidDeleteSelection() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidDeleteSelection(AVDoc doc, ASAtom selType, void* selData, void* clientData)

Called when a user deletes the current selection.

Parameters

doc — 

The document containing the selection.

 
selType — 

The selection's type. See AVDocSetSelection() for a list of those available.

 
selData — 

Server-dependent selection data.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1815
AVDocDidOpen() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidOpen(AVDoc doc, ASInt32 error, void* clientData)

A document has been opened.

Calling AVDocClose() within this notification is forbidden.

Parameters

doc — 

The document that was opened.

 
error — 

The error code. error is set to 0 if no errors occurred while opening the file. If an error occurred, error contains the error code.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 117
AVDocDidPerformAction() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidPerformAction(AVDoc doc, PDAction action, ASInt32 err, void* clientData)

An action was performed.

The following methods broadcast this notification if the document has an open action:

Parameters

doc — 

The document containing the action that was performed.

 
action — 

The action that was performed.

 
err — 

The error code. err is set to 0 if no errors occurred while performing the action. If an error occurred, err contains the error code.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 297
AVDocDidPrint() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidPrint(AVDoc doc, void* clientData)

This notification is broadcast after printing ends.

Parameters

doc — 

IN/OUT The document that was printed.

 
clientData — 

IN/OUT A pointer to a block of user-supplied data that was passed in by the calling application when this notification was registered for using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1339
AVDocDidRemoveFromSelection() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidRemoveFromSelection(AVDoc doc, ASAtom selType, void* selData, void* remData, void* clientData)

The document's selection has had something removed.

Parameters

doc — 

The document whose selection was removed.

 
selType — 

The ASAtom corresponding to the current selection type. See AVDocSetSelection() for a list of selection types.

 
selData — 

A pointer to the current selection data after the selection has been deleted. The format and contents of selData depend on selType..

 
remData — 

The item removed from the selection. The format and contents of remData depend on selType.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1215
AVDocDidSetSelection() 
Product availability: All
Platform availability: All

Syntax

void AVDocDidSetSelection(AVDoc doc, ASAtom selType, void* selData, void* clientData)

The document's selection has been set.

Parameters

doc — 

The document whose selection was set.

 
selType — 

The ASAtom corresponding to the current selection type. See AVDocSetSelection() for a list of selection types.

 
selData — 

A pointer to the current selection data. The format and contents of selData depend on selType.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 236
AVDocDoActionPropsDialog() 
Product availability: Acrobat
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocDoActionPropsDialog(AVDoc doc, PDAction* action, const char* dialogTitle)

Displays a modal dialog box that allows a user to specify an action. For example, it is used by forms to add actions to fields.

Parameters

doc — 

IN/OUT The document in which the action is specified.

 
action — 

IN/OUT The specified action.

 
dialogTitle — 

IN/OUT The title for the dialog box.

Returns

true if the user clicked the Set Link button, false if the user clicked Cancel.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 3634
AVDocDoAnnotProperties() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocDoAnnotProperties(AVDoc doc, ASInt32 pageNum, PDAnnot annot)

Show the properties dialog box for the specified annotation.

Parameters

doc — 

The document containing the annotation.

 
pageNum — 

The page number where the annotation is located.

 
annot — 

The annotation.

Exceptions

genErrBadParam is raised if the page number does not correspond to the page where the annotation is located.

Since

PI_ACROVIEW_VERSION >= 0x00070000

File: AVProcs.h
Line: 9646
AVDocDoCopyAs() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocDoCopyAs(AVDoc avDoc)

Prompts the user with a standard file dialog box and copies the file byte for byte. It displays a progress monitor showing the progress of the file copy.

Parameters

avDoc — 

IN/OUT The document to copy.

Returns

true if the copy was successful, false otherwise.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 3937
AVDocDoPrint() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocDoPrint(AVDoc doc)

Performs the print operation, including user dialog boxes.

You can replace this method with your own version, using HFTReplaceEntry().

Parameters

doc — 

IN/OUT The document to print.

See Also

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 3958
AVDocDoSave() 
Product availability: Acrobat
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocDoSave(AVDoc doc)

Saves a file, handling any user interface (for example, a Save File dialog box) as needed. Clients do not need to call this method directly, but it is available for clients that need to override the Acrobat viewer's built-in save method. For example, it can be used to save the changes made to a PDF file into a special file, but not save the original PDF file.

You can replace this method with your own version, using HFTReplaceEntry().

Parameters

doc — 

The document to save.

Returns

true if the document was successfully saved, false otherwise.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 3206
AVDocDoSaveAs() 
Product availability: Acrobat
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocDoSaveAs(AVDoc doc)

Displays a file dialog box which can be used to save the document to a new name. It allows clients (such as Optimizer) to do their own file saving.

You can replace this method with your own version, using HFTReplaceEntry().

Parameters

doc — 

The document to save.

Returns

true if the document was successfully saved, false otherwise.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 3696
AVDocDoSaveAsWithParams() 
Product availability: Acrobat
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocDoSaveAsWithParams(AVDoc doc, AVDocSaveParams params)

Saves a file, using the parameters specified in params.

You can replace this method with your own version, using HFTReplaceEntry().

Parameters

doc — 

IN/OUT The document to save.

 
params — 

IN/OUT A structure with information describing how the AVDoc is saved.

Returns

true if the document was successfully saved, false otherwise.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 3978
AVDocDoSelectionProperties() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocDoSelectionProperties(AVDoc doc)

Displays the user interface, if any, for setting the current selection's properties. It does this by invoking the AVDocSelectionPropertiesProc() callback, if any, of the current selection's selection server.

It only raises those exceptions raised by the selection server's AVDocSelectionPropertiesProc() callback.

Parameters

doc — 

IN/OUT The document containing the selection whose properties are set.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1232
AVDocEndUndoOperation() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocEndUndoOperation(AVDoc doc, const ASText undoTitle, const ASText redoTitle)

Ends an undo group for the document. To create an undo group, call AVDocBeginUndoOperation(), create each instance with its handler and data, and call this method.

Parameters

doc — 

The document whose undo group is ended.

 
undoTitle — 

The title to be used as the "Undo" string in the user interface.

 
redoTitle — 

The title to be used as the "Redo" string in the user interface.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 8749
AVDocEnumSelection() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocEnumSelection(AVDoc doc, AVSelectionEnumProc proc, void* clientData)

Enumerates the elements of the current selection by calling the current selection server's AVDocSelectionEnumSelectionProc() callback. If the selection server does not have an AVDocSelectionEnumSelectionProc(), it calls proc and passes the entire selection to it in the aSelectedObject parameter.

It only raises those exceptions raised by the selection server's AVDocSelectionEnumSelectionProc() callback, and those raised by proc.

Parameters

doc — 

The document whose selection is enumerated.

 
proc — 

A user-supplied callback to call for each element in the selection. The enumeration ends if proc returns false.

 
clientData — 

A pointer to user-supplied data to pass to proc each time it is called.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1217
AVDocFromPDDoc() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocFromPDDoc(PDDoc pdDoc)

Gets the AVDoc associated with a PDDoc.

Parameters

pdDoc — 

IN/OUT The PDDoc whose AVDoc is to be returned.

Returns

The AVDoc if an AVDoc is already opened for this PDDoc. Otherwise it returns NULL.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00050000

File: AVProcs.h
Line: 5554
AVDocGetActiveTool() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVTool AVDocGetActiveTool(AVDoc doc)

Gets the active tool for the AVDoc. The call provides the additional context needed to retrieve the active tool for documents that are displayed in external windows such as a web browser.

Parameters

doc — 

The document whose active tool is obtained, or NULL to get the active tool for the main application window.

Returns

The active tool object.

See Also

Exceptions

genErrNoMemory

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 9384
AVDocGetAVWindow() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVWindow AVDocGetAVWindow(AVDoc doc)

Gets the AVWindow in which the document is displayed. If more than one window is open for a document, this call returns the active window for that document, which is the one with which the user is interacting.

Parameters

doc — 

The document whose AVWindow is obtained.

Returns

The document's AVWindow.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 924
AVDocGetBookmarks() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASInt32 AVDocGetBookmarks(AVDoc avDoc, AVBookmarkFilter avBookmarkFilter, PDBookmark** pPDBookmarkArray)

Gets the set of bookmarks for a given document that satisfies the input filter. It is the client's responsibility to release the memory associated with the bookmark array using ASfree().

Parameters

avDoc — 

IN The document containing the bookmarks

 
avBookmarkFilter — 

The filter applied to the bookmarks. See the definition of AVBookmarkFilter in AVExpT.h. The default is 0.

 
pPDBookmarkArray — 

OUT A pointer to an array for storing the bookmarks If this parameter is NULL, it does not copy the PDBookmark associated with the bookmarks. If this parameter is not NULL, a bookmark array is allocated and assigned to this pointer. The bookmarks that satisfy the filter are copied into this array.

Returns

The number of bookmarks copied into the array.

Since

PI_ACROVIEW_VERSION >= 0x00070000

File: AVProcs.h
Line: 9575
AVDocGetClientName() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVTArraySize AVDocGetClientName(AVDoc avDoc, char* buffer, AVTBufferSize bufSize)

Gets the AVDoc client (container application) name.

This method can be used by a client to determine which client application caused the Acrobat viewer to open a document.

Parameters

avDoc — 

The document whose client name is obtained.

 
buffer — 

(Filled by the method) The buffer into which the client name is written. It may contain up to 255 characters. The client name is NULL-terminated. If the client name is longer than bufSize, the first bufSize-1 bytes are copied into it, followed by a NULL.

 
bufSize — 

The size of buffer in bytes.

Returns

The number of characters written into buffer, excluding the NULL termination. It returns 0 if the specified document does not have a client associated with it.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020001

File: AVProcs.h
Line: 3229
AVDocGetDisplayTitle() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocGetDisplayTitle(AVDoc doc, ASText title)

Gets the display-title of a given doc. Display title is the text that appears on application title bar when the doc is the active document.

Parameters

doc
 
title

Returns

true If title is assigned a value, false otherwise.

Since

PI_ACROVIEW_VERSION >= 0x000C0003

File: AVProcs.h
Line: 10347
AVDocGetLastActiveTool() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVTool AVDocGetLastActiveTool(AVDoc avDoc)

Gets the tool that was active for this document before the current tool became active.

Parameters

avDoc

Returns

The last active tool. If only one tool has ever been active, it is returned.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00070000

File: AVProcs.h
Line: 9588
AVDocGetNthPageView() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVPageView AVDocGetNthPageView(AVDoc avDoc, ASCount n)

Gets the specified AVPageView for the specified document.

Parameters

avDoc — 

The document whose AVPageView is obtained.

 
n — 

The index of the page view to obtain. The index range is 0 to (AVDocGetNumPageViews-1).

Returns

The document's nth AVPageView.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 7812
AVDocGetNthWindow() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVWindow AVDocGetNthWindow(AVDoc avDoc, ASCount n)

Gets the specified AVWindow for the specified document. If the index is out of range, NULL is returned. The windows are enumerated in no particular order. Specifically, the window at index 0 is not guaranteed to be the active window.

Parameters

avDoc — 

The document whose AVWindow is obtained.

 
n — 

The index of the window to obtain. The index range is 0 to (AVDocGetNumWindows()-1).

Returns

The document's nth AVWindow.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00070000

File: AVProcs.h
Line: 9615
AVDocGetNumPageViews() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASCount AVDocGetNumPageViews(AVDoc avDoc)

Gets the number of page views for the specified document.

Parameters

avDoc — 

The document whose page view count is obtained.

Returns

The number of AVPageView objects associated with the document, as an ASCount.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 7799
AVDocGetNumWindows() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASCount AVDocGetNumWindows(AVDoc avDoc)

Returns the number of windows currently open for the document.

Parameters

avDoc — 

IN The document

Returns

The number of windows open for the document.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00070000

File: AVProcs.h
Line: 9599
AVDocGetPageText() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocGetPageText(AVDoc doc, PDPageNumber pageNum, PDTextSelect pdText, ASAtom format, AVTextCopyProc copyProc, void* clientData)

Gets the text from the specified text selection, converts it to the specified format, and passes it to a user-supplied procedure.

Parameters

doc — 

IN/OUT The document from which the text is obtained.

 
pageNum — 

IN/OUT The page number in doc from which the text is obtained. The first page in a document is page 0.

 
pdText — 

IN/OUT The text selection whose text is obtained. Pass NULL to get all the text on the page.

 
format — 

IN/OUT The format in which the text is desired. The following are allowed values (these strings must be converted to ASAtom objects using ASAtomFromString()):

Allowed value

Description

All

(Mac OS/Windows) Calls copyProc once with each available format.

Text

(Mac OS/Windows) Calls copyProc twice. The first time, it passes the text in the specified selection. The text is passed using the same platform encoding as when it is put onto the clipboard (format = Text). The second time, it passes a Unicode version of the text (format = UCSText).

Style

(Mac only) Calls copyProc twice. The first time, it passes the Text representation. The second time, it passes a StyleInfo record.

RTF

(Mac OS/Windows) Calls copyProc twice. The first time, it passes the text in Rich Text Format. The second time, it passes a Unicode version of the text. Upon using or manipulating the text, you should check the format in copyProc.

 
copyProc — 

IN/OUT A user-supplied callback to which the text is passed.

 
clientData — 

IN/OUT A pointer to user-supplied data to pass to copyProc each time it is called.

See Also

Exceptions

pdErrOpNotPermitted

Since

PI_ACROVIEW_VERSION >= 0x00020001

File: AVProcs.h
Line: 3290
AVDocGetPageView() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVPageView AVDocGetPageView(AVDoc doc)

Gets the AVPageView for the specified document.

Parameters

doc — 

The document whose AVPageView is obtained.

Returns

The document's AVPageView.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 909
AVDocGetPDDoc() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

PDDoc AVDocGetPDDoc(AVDoc avDoc)

Gets the PDDoc to associate with the specified AVDoc.

Parameters

avDoc — 

IN/OUT The document whose PDDoc is obtained.

Returns

The PDDoc associated with avDoc.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 899
AVDocGetSelection() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void* AVDocGetSelection(AVDoc doc)

Gets the current selection for the specified document.

Parameters

doc — 

The document whose selection is obtained.

Returns

The current selection, or NULL if there is no selection. See Selection Types for a list of the data types returned for the built-in selection types. A NULL return value from this method is not sufficient to determine whether there is no selection; use AVDocGetSelectionType() instead.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1062
AVDocGetSelectionServerByType() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDocSelectionServer AVDocGetSelectionServerByType(ASAtom type)

Gets the selection server that handles the specified selection type.

Parameters

type — 

IN/OUT The ASAtom corresponding to the type for which the selection server was registered. The string for the type can be converted to an ASAtom using ASAtomFromString().

Returns

The selection server that handles the specified type. It returns NULL if no such selection server is registered.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 6485
AVDocGetSelectionType() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASAtom AVDocGetSelectionType(AVDoc doc)

Gets the current selection's type for the specified document.

Parameters

doc — 

The document whose selection type is obtained.

Returns

The ASAtom corresponding to the current selection type. Returns ASAtomNull if there is no selection. The ASAtom returned can be converted to a string using ASAtomGetString(). See Selection Types for a list of the built-in selection types.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1044
AVDocGetServerType() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDocServerType AVDocGetServerType(AVDoc doc)

Gets the server type for the specified document.

Parameters

doc — 

The document whose server type is obtained.

Returns

The server type value.

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 9485
AVDocGetSplitterPosition() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASInt16 AVDocGetSplitterPosition(AVDoc doc)

Gets the splitter position. The splitter is the vertical division between the bookmark/thumbnail pane and the document pane. The default splitter location is saved in the Acrobat viewer's preferences file, and can be read and set using AVAppGetPreference() and AVAppSetPreference().

Parameters

doc — 

IN/OUT The document whose splitter position is obtained.

Returns

The width of the bookmark/thumbnail pane, measured in pixels. Returns 0 if the bookmark/thumbnail pane is not currently displayed.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 965
AVDocGetTopUndo() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVUndo AVDocGetTopUndo(AVDoc doc, const char* desiredType)

Returns the most recent AVUndo record in the document's undo list, if it of the desired type.

Parameters

doc — 

The document.

 
desiredType — 

The type of the desired undo record.

Returns

The undo record object, or NULL if the undo list is empty or if the type of the most recent undo record does not match desiredType.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 8710
AVDocGetTopUndoAndRedo() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocGetTopUndoAndRedo(AVDoc doc, AVUndo* undo, AVUndo* redo, const char* desiredType)

Returns the most recent undo and redo records in the document's undo list, if they are of the desired type.

Parameters

doc — 

The document.

 
undo — 

(Filled by the method) A pointer to the latest undo, or NULL if the undo list is empty or if the type of the most recent undo record does not match desiredType.

 
redo — 

(Filled by the method) A pointer to the latest redo, or NULL if the redo list is empty or if the type of the most recent redo record does not match desiredType.

 
desiredType — 

The type of the desired undo record.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 9315
AVDocGetViewDef() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocGetViewDef(AVDoc doc, AVDocViewDef viewDef)

Fills out the given AVDocViewDef structure with the information needed to restore this document's state at a later date. You must set the use fields as desired.

Parameters

doc — 

The document whose state is recorded.

 
viewDef — 

A pointer to the structure that stores the state.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 6457
AVDocGetViewDefEx() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocGetViewDefEx(AVDoc doc, ASCab viewDef)

Fills out the given view definition with the information needed to restore this document's state at a later date. If you pass an empty ASCab, the method fills it with all of the view information. Otherwise, it fills only those fields that are present in the ASCab.

The ASCab can contain the same fields defined for AVDocViewDef, plus an additional field, ocgStates, which is an ASCab containing a set of optional content states.

Parameters

doc — 

The document whose state is recorded.

 
viewDef — 

A pointer to the ASCab that stores the state.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 8800
AVDocGetViewMode() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

PDPageMode AVDocGetViewMode(AVDoc doc)

Gets the current view mode.

Parameters

doc — 

IN/OUT The document whose view mode is obtained.

Returns

The current view mode.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 934
AVDocIsDead() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocIsDead(AVDoc avDoc)

Determines whether a given document is dead. When the connection to a document is severed (for example, when its HTTP connection is broken) the document becomes dead for an interval before it is closed. During that interval, the document may be visible and open, but no operations should be performed on the document.

Parameters

avDoc — 

The document being investigated.

Returns

true if the given document is dead, false otherwise.

Since

PI_ACROVIEW_VERSION >= 0x00050000

File: AVProcs.h
Line: 5582
AVDocIsExternal() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocIsExternal(AVDoc doc)

Determines whether a given document is displayed in an application's external window (such as in a web browser's window).

Parameters

doc — 

The document being tested.

Returns

true if the given document is displayed in an application's external window, false otherwise.

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 3728
AVDocIsInProtectedView() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocIsInProtectedView(AVDoc avDoc)

Checks whether a given document is opened in Protected View or not. Protected View provides an additional level of security. When Protected View in enabled, PDFs are displayed in a restricted environment called a sandbox. This isolation of the PDFs reduces the risk of security breaches in areas outside the sandbox. For more information please refer to the Application Security Guide at www.adobe.com/go/acroappsecurity

Parameters

avDoc — 

IN The document

Returns

TRUE if document is opened in Protected View otherwise returns FALSE

Since

PI_ACROVIEW_VERSION >= 0x000B0000

File: AVProcs.h
Line: 10115
AVDocIsReadOnly() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocIsReadOnly(AVDoc doc)

Determines whether an AVDoc is read-only.

Parameters

doc — 

IN/OUT The AVDoc whose read-only state is checked.

Returns

true if the document is read-only, false otherwise.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 4131
AVDocIsSlow() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocIsSlow(AVDoc doc)

Determines whether a given document is on a slow file system (such as a web browser).

Parameters

doc — 

The document being investigated.

Returns

true if the given document is on a slow file system; false otherwise.

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 9453
AVDocOpenFromASFileWithParams() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromASFileWithParams(ASFile file, const ASText tempTitle, AVDocOpenParams params)

Opens and displays a document from a file, using the specified parameters to control the window's size, location, and visibility.

You can replace this method with your own version, using HFTReplaceEntry().

If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow.

Parameters

file — 

The ASFile to open.

 
tempTitle — 

If tempTitle != NULL, the path name is a temporary file and tempTitle is used as the window's title.

 
params — 

The parameters used when opening the file. It can be NULL.

Returns

The document that was opened.

See Also

Notifications

AVDocWillOpenFromFile
AVDocDidOpen
AVAppFrontDocDidChange
AVDocDidActivate
AVDocDidDeactivate
AVDocWillPerformAction (broadcast if the document has a valid open action)
AVDocDidPerformAction (broadcast if the document has a valid open action)

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 6404
AVDocOpenFromASFileWithParamString() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromASFileWithParamString(ASFile file, const ASText tempTitle, AVDocOpenParams p, const char* s)

Opens and displays a document from an ASFile, using the specified parameters to control the window's size, location, and visibility, and passing a URL open action string to control how the file is opened. For more information, see Parameters for Opening PDF Files.

If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().

Parameters

file — 

The ASFile to open.

 
tempTitle — 

An optional window title for the document.

 
p — 

Open parameters for the document.

 
s — 

A string containing the URL open action. For example, Help=contents&nameddest=distiller_mydest would open the PDF in the help window, with the contents panel showing on the left and the page referenced by the named destination distiller_mydest showing on the right.

Returns

An AVDoc object for file.

See Also

Notifications

AVDocWillOpenFromFile
AVDocDidOpen
AVAppFrontDocDidChange
AVDocDidActivate
AVDocDidDeactivate
AVDocWillPerformAction (broadcast if the document has a valid open action)
AVDocDidPerformAction (broadcast if the document has a valid open action)

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 7922
AVDocOpenFromFile() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromFile(ASPathName pathName, ASFileSys fileSys, const ASText tempTitle)

Opens and displays a document from a file. This is equivalent to AVDocOpenFromASFileWithParams(pathName, fileSys, tempTitle, NULL). If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().

Parameters

pathName — 

The file to open.

 
fileSys — 

The file system on which pathName resides. You can obtain the default file system with ASGetDefaultFileSys().

 
tempTitle — 

If tempTitle != NULL, pathName is a temporary file, and tempTitle is used as the window's title.

Returns

The document that was opened. It returns NULL if the viewer failed to open the document.

See Also

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 8316
AVDocOpenFromFileWithParams() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromFileWithParams(ASPathName pathName, ASFileSys fileSys, const ASText tempTitle, AVDocOpenParams params)

Opens and displays a document from a file, using the specified parameters to control the window's size, location, and visibility.

You can replace this method with your own version, using HFTReplaceEntry().

If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().

Parameters

pathName — 

The file to open.

 
fileSys — 

The file system on which pathName resides. You can obtain the default file system with ASGetDefaultFileSys().

 
tempTitle — 

If tempTitle != NULL, pathName is a temporary file and tempTitle is used as the window's title.

 
params — 

The parameters used when opening the file. It can be NULL.

Returns

The document that was opened.

See Also

Notifications

AVDocWillOpenFromFile
AVDocDidOpen
AVAppFrontDocDidChange
AVDocDidActivate
AVDocDidDeactivate
AVDocWillPerformAction (broadcast if the document has a valid open action)
AVDocDidPerformAction (broadcast if the document has a valid open action)

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 6340
AVDocOpenFromFileWithParamString() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromFileWithParamString(ASPathName pathName, ASFileSys fileSys, const ASText tempTitle, AVDocOpenParams p, const char* s)

Opens and displays a document from a file, using the specified parameters to control the window's size, location, and visibility, and passing a URL open action string to control how the file is opened. For more information, see the document Parameters for Opening PDF Files.

If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().

Parameters

pathName — 

The file to open.

 
fileSys — 

The file system on which pathName resides. You can obtain the default file system with ASGetDefaultFileSys.

 
tempTitle — 

If tempTitle != NULL, pathName is a temporary file and tempTitle is used as the window's title.

 
p — 

Parameters used when opening the file. It can be NULL.

 
s — 

A string containing the URL open action. For example, Help=contents&nameddest=distiller_mydest would open the PDF in the help window, with the contents panel showing on the left and the page referenced by the named destination distiller_mydest showing on the right.

Returns

The document that was opened.

See Also

Notifications

AVDocWillOpenFromFile
AVDocDidOpen
AVAppFrontDocDidChange
AVDocDidActivate
AVDocDidDeactivate
AVDocWillPerformAction (broadcast if the document has a valid open action)
AVDocDidPerformAction (broadcast if the document has a valid open action)

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 7854
AVDocOpenFromPDDoc() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromPDDoc(PDDoc doc, const ASText tempTitle)

Opens and returns an AVDoc view of pdDoc. This method is equivalent to AVDocOpenFromPDDocWithParams(pdDoc, tempTitle, NULL). If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().

Parameters

doc — 

The document to open.

 
tempTitle — 

If tempTitle != NULL, pathname is a temporary file and tempTitle is used as the window's title.

Returns

NULL if failure occurs.

See Also

Exceptions

genErrGeneral is raised if doc is NULL or has 0 pages.
pdErrBadAction is raised if the document's open action is recursive.
avErrCantOpenMoreThanTenDocs is raised if the maximum number of documents is already open.
genErrNoMemory is raised if there is insufficient memory to open the document.

Notifications

AVAppFrontDocDidChange
AVDocDidActivate
AVDocDidDeactivate
AVDocWillPerformAction (broadcast if the document has a valid open action)
AVDocDidPerformAction (broadcast if the document has a valid open action)

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 8351
AVDocOpenFromPDDocWithParams() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromPDDocWithParams(PDDoc pdDoc, const ASText tempTitle, AVDocOpenParams params)

Opens and displays a document from a PDDoc, using the specified parameters to control the window's size, location, and visibility.

If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().

Parameters

pdDoc — 

The document to open and display.

 
tempTitle — 

If tempTitle != NULL, the path name is a temporary file and tempTitle is used as the window's title.

 
params — 

The parameters used when opening the file. It can be NULL.

Returns

The document that was opened.

See Also

Notifications

AVAppFrontDocDidChange
AVDocDidActivate
AVDocDidDeactivate
AVDocWillPerformAction (broadcast if the document has a valid open action)
AVDocDidPerformAction (broadcast if the document has a valid open action)

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 6369
AVDocOpenFromPDDocWithParamString() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

AVDoc AVDocOpenFromPDDocWithParamString(PDDoc pdDoc, const ASText tempTitle, AVDocOpenParams p, const char* s)

Opens and displays a document from a PDDoc, using the specified parameters to control the window's size, location, and visibility, and passing a URL open action string to control how the file is opened. For more information, see the document Parameters for Opening PDF Files.

If you want to display a page from a PDF file as a bitmap, use PDPageDrawContentsToWindow().

Parameters

pdDoc — 

The document to open and display.

 
tempTitle — 

If tempTitle != NULL, pathname is a temporary file and tempTitle is used as the window's title.

 
p — 

Parameters used when opening the file. It can be NULL.

 
s — 

A string containing the URL open action. For example, Help=contents&nameddest=distiller_mydest would open the PDF in the help window, with the contents panel showing on the left and the page referenced by the named destination distiller_mydest showing on the right.

Returns

The document that was opened.

See Also

Notifications

AVAppFrontDocDidChange
AVDocDidActivate
AVDocDidDeactivate
AVDocWillPerformAction (broadcast if the document has a valid open action)
AVDocDidPerformAction (broadcast if the document has a valid open action)

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 7889
AVDocPerformAction() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocPerformAction(AVDoc doc, PDAction action)

Performs an action.

Parameters

doc — 

The document containing the action to perform.

 
action — 

The action to perform.

See Also

Exceptions

pdErrBadAction

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1269
AVDocPerformActionEx() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocPerformActionEx(AVDoc doc, PDAction action, AVActionContext data)

Same as AVDocPerformAction(), but provides context for the execution of the action.

Parameters

doc — 

IN/OUT The document containing the action to perform.

 
action — 

IN/OUT The action to perform.

 
data — 

IN/OUT The context for the execution of the action.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00050000

File: AVProcs.h
Line: 5849
AVDocPermRequest() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocPermRequest(AVDoc doc, PDPermReqObj obj, PDPermReqOpr opr)

An exact way to ask if an operation is permitted. This routine should be used to query all user interface-level permissions (for example, to determine whether a tool button or menu item is enabled or whether a tool can act upon a given document). This routine should be used instead of some combination of AVDocIsReadOnly(), AVDocIsExternal(), and PDDocPermRequest(). AVDocPermRequest() calls PDDocPermRequest() internally in the process of determining whether to grant the request.

Parameters

doc — 

The document opened in Acrobat.

 
obj — 

The description of the target object of a permissions request.

 
opr — 

The description of the target operation of a permissions request.

Returns

true if the operation is permitted, false otherwise.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00050000

File: AVProcs.h
Line: 6078
AVDocPopupContentsWillChange() 
Product availability: All
Platform availability: All

Syntax

void AVDocPopupContentsWillChange(AVDoc doc, PDAnnot annot, void* clientData)

The contents of a popup note have change but have not yet been set in the PDAnnot, thus the change is intermediate. The contents will be changed when input focus is lost by the popup note.

Parameters

doc — 

The AVDoc in which the annotation lives.

 
annot — 

The PDAnnot representing the popup (possibly the parent of the popup).

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .


File: PIPokes.h
Line: 2613
AVDocPrintDialogWasCancelled() 
Product availability: All
Platform availability: All

Syntax

void AVDocPrintDialogWasCancelled(AVDoc doc, void* clientData)

This notification will be broadcast when the user cancels the print dialog. It serves as the alternate to AVDocDidPrint() . The AVDocDidPrint() notification is not sent when the print dialog is cancelled.

Parameters

doc — 

The AVDoc for which the print dialog was invoked.

 
clientData

See Also

Notifications


File: PIPokes.h
Line: 2677
AVDocPrintPages() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocPrintPages(AVDoc doc, AVPageIndex firstPage, AVPageIndex lastPage, ASInt32 psLevel, ASBool binaryOK, ASBool shrinkToFit)

Prints without displaying any user dialog boxes. The current printer, page settings, and job settings are used. Printing is complete when this method returns.

You can replace this method with your own version, using HFTReplaceEntry().

Parameters

doc — 

The document from which pages are printed.

 
firstPage — 

The first page in doc to print.

 
lastPage — 

The last page in doc to print.

 
psLevel — 

Applies to PostScript printing. It must be either 1 or 2. If 1, Level 1 PostScript code is generated. If 2, Level 2 PostScript code is generated.

 
binaryOK — 

Applies to PostScript printing. If true, the PostScript code may contain binary data. If false, all binary data is encoded into an ASCII format.

 
shrinkToFit — 

If true, the page is shrunk (if necessary) to fit into the imageable area of a page in the printer. If false, pages are printed at actual size and may appear clipped on the printed page.

See Also

Exceptions

genErrBadParm is raised if an invalid parameter is provided. It can raise any of the CosErrExpected exceptions, such as ErrSysCosSyntax or cosErrExpectedNumber. In general, this method can raise any exception that can occur during the parsing of a page and its resources, such as pdErrUnknownProcsets or pdErrUnableToExtractFontErr.

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1026
AVDocPrintPagesWithParams() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocPrintPagesWithParams(AVDoc doc, AVDocPrintParams params)

Prints a document with a full range of options. Printing is complete when this method returns. It performs embedded printing; that is, it allows a PDF page to print within a bounding rectangle on a page. It allows interactive printing to the specified printer (Windows, Mac OS, and UNIX).

You can replace this method with your own version, using HFTReplaceEntry().

Parameters

doc — 

The AVDoc from which to print pages.

 
params — 

A structure containing printing parameters. See AVDocPrintParams. With Adobe Reader, you cannot use the emitToFile flag. For Adobe Reader, use the emitToPrinter, interactive, or embedded flags. In Acrobat 6.0 Standard, the printer mark drawing flags (marksFlags) in the parameters structure are ignored.

See Also

Exceptions

genErrBadParm is raised if an invalid parameter is provided. It can raise any of the CosErrExpected exceptions, such as ErrSysCosSyntax or cosErrExpectedNumber. In general, this method can raise any exception that can occur during the parsing of a page and its resources, such as pdErrUnknownProcsets or pdErrUnableToExtractFontErr.

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 6442
AVDocPrintSeparations() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocPrintSeparations(AVDocPrintSepsParams params)

Prints document color separations using the supplied parameters. Printing is complete when this method returns.

For Adobe Reader and Acrobat Standard, this method does nothing.

Parameters

params — 

A structure containing print separation parameters. This structure includes the document object.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 8779
AVDocRegisterSelectionServer() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocRegisterSelectionServer(AVDocSelectionServer server)

Registers a new selection server with the Acrobat viewer. Selection servers allow the selection of items other than those that can be selected in the as-shipped Acrobat viewer. For example, a selection server could allow a user to select a sampled image.

This method can be used to replace an existing selection server that handles the same selection type.

Parameters

server — 

IN/OUT A structure containing the selection server's callback functions. This structure must not be freed after calling AVDocRegisterSelectionServer().

Returns

This always returns true.

See Also

Exceptions

genErrBadParm is raised if server is NULL, if the size field in the AVDocSelectionServerRec is incorrect, or if the selection server's AVDocSelectionGetTypeProc() is NULL.

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 6511
AVDocSaveOptimized() 
Product availability: Acrobat
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSaveOptimized(AVDoc avDoc, const PDFOptParamsRec* pdfOptParams)

This method invokes the PDF Optimizer tool on a specified AVDoc. An optimized document is created using the settings specified in the PDFOptParamsRec structure. The optimized document is saved to the disk at the location specified in the parameter's structure. If the operation is successful, the active document is closed and the optimized document is opened for viewing. If the operation fails, the active document remains open.

The AVDoc passed to the proc should not be dirty. PDF Optimizer is unavailable in external windows like those of a web browser, so the AVDoc should not be of a document open in one such window. The document should not be of a version greater than the default PDF version of the Acrobat application. If the optimization succeeds, the document associated with the AVDoc is closed and the optimized document is opened in Acrobat.

Parameters

avDoc — 

The document that is to be optimized. It should be a valid AVDoc. It cannot be NULL.

 
pdfOptParams — 

A pointer to a structure that specifies the operations to be performed on the document.

See Also

Exceptions

genErrBadParm is raised if any option in the pdfOptParams structure does not conform to the specified rules.
fileErrDiskFull is raised if there is not enough disk space.
pdErrOpNotPermitted is raised if the caller does not have permissions to modify the PDF document or if the document is read-only.

Since

PI_ACROVIEW_VERSION >= 0x00080000

File: AVProcs.h
Line: 9691
AVDocSelectionEnumPageRanges() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSelectionEnumPageRanges(AVDoc doc, AVSelectionPageRangeEnumProc enumProc, void* clientData)

Enumerates the pages on which there is a selection by calling the current selection server's AVDocSelectionEnumPageRangesProc() callback.

This method allows you to determine which pages are currently involved in a selection, regardless of the selection type. This enables you to discover whether a given point is in a selection.

Pages are enumerated in ascending order, and consecutive pages are grouped into a single page range.

Parameters

doc — 

IN/OUT The AVDoc from which to enumerate page ranges.

 
enumProc — 

IN/OUT A user-supplied function that is called for each page on which there is a selection.

 
clientData — 

IN/OUT A pointer to user-supplied data to pass to enumProc each time it is called.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 4443
AVDocSendAuxData() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocSendAuxData(AVDoc avDoc, ASAtom auxDataType, void* auxData, AVTBufferSize auxDataLen)

Sends auxiliary data to an AVDoc. If an AVAuxDataHandler exists for the data type, the handler is called with avDoc, auxDataType, and auxData. The definition of the auxiliary data is dependent on the AVAuxDataHandler.

For any value of auxDataType, the auxData parameter must be predefined so that a user of this method knows what type of data to send. It is expected that the implementor of an AVAuxDataHandler provides this definition.

Parameters

avDoc — 

IN/OUT The target document.

 
auxDataType — 

IN/OUT The type of data being sent.

 
auxData — 

IN/OUT A pointer to the data.

 
auxDataLen — 

IN/OUT The length of the data.

Returns

true if auxData was accepted by a handler, false otherwise.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 3458
AVDocSetActiveTool() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetActiveTool(AVDoc doc, AVTool tool, ASBool persistent)

Sets the active tool for the AVDoc.

Parameters

doc — 

The document whose active tool is set, or NULL to set the active tool for the application.

 
tool — 

The new active tool.

 
persistent — 

When true, the tool stays active after it is used. It is passed to the tool's Activate callback.

See Also

Exceptions

genErrNoMemory

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 9401
AVDocSetClientName() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetClientName(AVDoc avDoc, char* clientName)

Sets the AVDoc client (container application) name. This method can be used by clients that open documents in the viewer via DDE or Apple events. Most clients will not open documents in this way, however, making this method unnecessary for most clients.

Parameters

avDoc — 

The document whose client names is set.

 
clientName — 

The buffer from which the client name is read. It may contain up to 255 characters, and must be NULL-terminated.

See Also

Exceptions

genErrNoMemory

Since

PI_ACROVIEW_VERSION >= 0x00020001

File: AVProcs.h
Line: 3244
AVDocSetDead() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetDead(AVDoc doc, ASBool dead)

Indicates that the file stream for this document is terminated, although the AVDoc is still open. No more data can be read from this AVDoc.

AVDocs that are marked as dead may start returning NULL at any time between the initial call to AVDocSetDead() and the time that the AVDoc is actually closed. Callers of AVDocGetAVWindow() and other AVDoc property methods must check for a NULL return value.

Parameters

doc — 

IN/OUT The document to set as dead.

 
dead — 

IN/OUT true if the document's file stream is terminated, false otherwise.

See Also

Notifications

AVDocWantsToDie (if dead is true)

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 3515
AVDocSetReadOnly() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetReadOnly(AVDoc doc, ASBool readOnly)

Sets the read-only state of an AVDoc.

Parameters

doc — 

IN/OUT The AVDoc to set to read-only.

 
readOnly — 

IN/OUT true if the given document is set to read- only, false if it is set to read-write.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00040000

File: AVProcs.h
Line: 4120
AVDocSetSelection() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

ASBool AVDocSetSelection(AVDoc doc, ASAtom type, void* data, ASBool highlight)

Sets the document's current selection to the specified selection by calling the appropriate selection server's AVDocSelectionGettingSelectionProc() callback. It clears the previous selection, if any, by calling the previous selection server's AVDocSelectionLosingSelectionProc() callback.

This raises only those exceptions raised by the previous selection server's AVDocSelectionGettingSelectionProc(), and those raised by the new selection server's AVDocSelectionGettingSelectionProc().

The following selection types can be specified when calling this method. The Details column specifies what should be used for the data parameter:

Selection Type

Description

Data Type

Details

Text

Text in the document

PDTextSelect

Use PDDocCreateTextSelect() to create the selection.

Bitmap

Graphics

AVGrafSelect

Use AVGrafSelectCreate() to create the selection.

Annotation

Annotation (text annotation, link, and so on)

To get information about a selected annotation, use AVPageViewGetFocusAnnot().

Allocate memory using ASmalloc(sizeof(PDAnnot)). Copy the desired PDAnnot into the allocated memory and pass a pointer to it. The annotation selection server assumes responsibility for freeing the memory.

Thumbnail

Thumbnail image

Pass the page number (the first page in a document is page 0).

Parameters

doc — 

The AVDoc in which the selection is set.

 
type — 

The selection type. It can be either a built-in type or one supported by a selection server added by a client. It can be converted to an ASAtom using ASAtomFromString(). See Selection Types for a list of the built-in selection types.

 
data — 

A data structure representing the selection. Its type depends on what is passed in type. See Selection Types for a list of the data types for the built-in selection types.

 
highlight — 

Clients should pass true, which tells the Acrobat viewer to highlight the selection because it has not already been highlighted. This only marks the highlighted regions of the display as invalid, but does not immediately redraw the screen. Use AVPageViewDrawNow() to force an immediate redraw if you wish.

Returns

true if the selection was set successfully, false otherwise. This method can fail for reasons including:

  • There is no selection server for type.

  • There was an attempt to set the selection during link creation.

See Also

Notifications

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1121
AVDocSetSplitterPosition() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetSplitterPosition(AVDoc doc, ASInt16 newPosition)

Sets the splitter position. The splitter is the vertical division between the bookmark/thumbnail pane and the document pane. The default splitter location is saved in the Acrobat viewer's preferences file, and can be read and set using AVAppGetPreference() and AVAppSetPreference().

Parameters

doc — 

The document whose splitter position is set.

 
newPosition — 

The new splitter position. This value specifies the width of the bookmark/thumbnail pane in pixels.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 981
AVDocSetViewDef() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetViewDef(AVDoc doc, AVDocViewDef viewDef)

Sets the document's state to match the information in viewDef.

Parameters

doc — 

The document whose state is updated.

 
viewDef — 

A pointer to the structure that stores the state.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020002

File: AVProcs.h
Line: 6472
AVDocSetViewDefEx() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetViewDefEx(AVDoc doc, ASCab viewDef)

Sets the document's state to match the information in viewDef.

Parameters

doc — 

The document whose state is updated.

 
viewDef — 

A pointer to the ASCab that stores the state.

See Also

AVDocGetViewDefEx
AVDocSetViewDefNOTE: Supersedes AVDocGetViewDef() in Acrobat 6.0.

Since

PI_ACROVIEW_VERSION >= 0x00060000

File: AVProcs.h
Line: 8813
AVDocSetViewMode() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocSetViewMode(AVDoc doc, PDPageMode newMode)

Sets the current view mode.

This method does nothing if the current view mode is full- screen, PDFullScreen. In this case, call AVAppEndFullScreen() first.

Parameters

doc — 

IN/OUT The document whose view mode is set.

 
newMode — 

IN/OUT The view mode to set.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 948
AVDocShowSelection() 
Product availability: Acrobat, Reader
Platform availability: Macintosh, Windows, UNIX

Syntax

void AVDocShowSelection(AVDoc doc)

Displays the current selection by calling the selection server's AVDocSelectionShowSelectionProc() callback. It does nothing if the document has no selection, or the current selection's server has no AVDocSelectionShowSelectionProc() callback.

It only raises those exceptions raised by the selection server's AVDocSelectionShowSelectionProc() callback.

Parameters

doc — 

IN/OUT The document whose selection is shown.

See Also

Since

PI_ACROVIEW_VERSION >= 0x00020000

File: AVProcs.h
Line: 1252
AVDocWantsToDie() 
Product availability: All
Platform availability: All

Syntax

void AVDocWantsToDie(AVDoc doc, void* clientData)

An AVDoc object's file stream has been terminated by The AVDocSetDead() method.

Parameters

doc — 

The AVDoc whose file stream has been terminated.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

Notifications


File: PIPokes.h
Line: 1228
AVDocWillClearSelection() 
Product availability: All
Platform availability: All

Syntax

void AVDocWillClearSelection(AVDoc doc, ASAtom selType, void* selData, void* clientData)

A document's selection is about to be cleared.

Parameters

doc — 

The document whose selection will be cleared.

 
selType — 

The ASAtom corresponding to the current selection type.

 
selData — 

A pointer to the current selection data. The format and contents of selData depend on selType.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 216
AVDocWillClose() 
Product availability: All
Platform availability: All

Syntax

void AVDocWillClose(AVDoc doc, void* clientData)

An AVDoc will be closed. Neither this notification nor AVDocDidClose() are broadcast if the user selects Cancel when prompted to save a modified document as it is closed.

Parameters

doc — 

The document that will be closed.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

Notifications


File: PIPokes.h
Line: 181
AVDocWillOpenFromFile() 
Product availability: All
Platform availability: All

Syntax

void AVDocWillOpenFromFile(ASPathName fileName, ASFileSys fileSys, void* clientData)

An AVDoc will be opened from a file.

Parameters

fileName — 

The ASPathName for the file that will be opened.

 
fileSys — 

The file system responsible for the file to open.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 97
AVDocWillOpenFromPDDoc() 
Product availability: All
Platform availability: All

Syntax

void AVDocWillOpenFromPDDoc(PDDoc pdDoc, void* clientData)

An AVDoc will be opened from a PDF file.

Parameters

pdDoc — 

The PDDoc for the file that will be opened.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1166
AVDocWillPerformAction() 
Product availability: All
Platform availability: All

Syntax

void AVDocWillPerformAction(AVDoc doc, PDAction action, void* clientData)

An action is about to be performed.

The following methods broadcast this notification if the document has an open action:

Parameters

doc — 

The document containing the action that will be performed.

 
action — 

The action that will be performed.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 265
AVDocWillPrint() 
Product availability: All
Platform availability: All

Syntax

void AVDocWillPrint(AVDoc doc, void* clientData)

This notification is broadcast before a document is printed, before any marks are made on the first page.

Parameters

doc — 

IN/OUT The document that is about to be printed.

 
clientData — 

IN/OUT A pointer to a block of user-supplied data that was passed in by the calling application when this notification was registered for using AVAppRegisterNotification() .

See Also

Notifications


File: PIPokes.h
Line: 1325
AVDocWillRefreshUI() 
Product availability: All
Platform availability: All

Syntax

void AVDocWillRefreshUI(AVDoc doc, void* clientData)

The UI is doing a full refresh (rebuild and relayout) as done in AVUIEnvironment::RefreshUI, so notify any AVDoc with components that will be affected by a the UI refresh. Currently (as of 8/24/12) this type of refresh is only done for updates related to Touch and Accesibility preferences.

Parameters

doc — 

The document that will be affected.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also

AVUIEnvironment::RefreshUI

File: PIPokes.h
Line: 2761
AVDocWindowWasAdded() 
Product availability: All
Platform availability: All

Syntax

void AVDocWindowWasAdded(AVDoc doc, AVWindow window, void* clientData)

A new window was created for a document. This will be called for all windows created for a document, including the initial window. It will arrive before AVDocDidOpen() .

Parameters

doc — 

The document.

 
window — 

The new AVWindow.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also


File: PIPokes.h
Line: 2555
AVDocWindowWasRemoved() 
Product availability: All
Platform availability: All

Syntax

void AVDocWindowWasRemoved(AVDoc doc, AVWindow window, void* clientData)

A window was removed from a document. This is called after the association between the window and document has been severed but before the window is destroyed.

Parameters

doc — 

The document.

 
window — 

The AVWindow being removed.

 
clientData — 

A pointer to a block of user-supplied data that was passed when the client registered for this notification using AVAppRegisterNotification() .

See Also


File: PIPokes.h
Line: 2570