SetOpenActionDestinationFull

文件屬性

描述

此函式可為所選文件設定起始頁面與各種尺寸/位置值

語法

Delphi

Function TPDFlib.SetOpenActionDestinationFull(OpenPage, Zoom, DestType: Integer; Left, Top, Right, Bottom: Double): Integer;

ActiveX

Function PDFlib::SetOpenActionDestinationFull(OpenPage As Long, Zoom As Long, DestType As Long, Left As Double, Top As Double, Right As Double, Bottom As Double) As Long

DLL

int DLSetOpenActionDestinationFull(int InstanceID, int OpenPage, int Zoom, int DestType, double Left, double Top, double Right, double Bottom);

參數

OpenPage文件開啟時要跳到的頁碼
Zoom文件開啟時使用的縮放百分比,有效值為 0 到 6400。只在 DestType = 1 時使用,其他 DestType 應設為 0
DestType1 = "XYZ" - 目標頁面定位到 Left 與 Top 參數指定的點,Zoom 參數指定縮放百分比。 2 = "Fit" - 縮放整頁以符合視窗。其他參數都不會使用,應設為零。 3 = "FitH" - 縮放頁面讓整個頁寬可見。頁面高度可能高於或低於視窗高度。頁面垂直定位在 Top 參數指定的位置。 4 = "FitV" - 縮放頁面讓整個頁高可見。頁面寬度可能大於或小於視窗寬度。頁面水平定位在 Left 參數指定的位置。 5 = "FitR" - 縮放頁面讓頁面上某個矩形可見。Left、Top、Right 與 Bottom 參數定義頁面上的矩形區域。 6 = "FitB" - 縮放頁面讓其邊界框可見。 7 = "FitBH" - 頁面垂直定位在 Top 參數指定的位置,並縮放讓邊界框的整個頁寬可見。 8 = "FitBV" - 頁面水平定位在 Left 參數指定的位置,並縮放到剛好讓邊界框的整個頁高納入視窗。 DestType = 1、4、5 與 8 使用的水平位置
Left
TopDestType = 1、3、5 與 7 使用的垂直位置 矩形右緣的水平位置。DestType = 5 時使用
Right
Bottom矩形底邊的水平位置。DestType = 5 時使用

傳回值

0無法設定開啟動作目的地。這通常表示 Zoom 或 DestType 參數超出範圍。
1開啟動作目的地設定成功。