PTScreen
@interface PTScreen : PTAnnot
A screen annotation (PDF 1.5) specifies a region of a page upon which media clips may be played. It also serves as an object from which actions can be triggered.
-
Creates a Screen annotation and initializes it using given Cos/SDF object.
Note
The constructor does not copy any data, but is instead the logical equivalent of a type cast.Parameters
dThe Cos/SDF object to initialze the annotation with.
-
Undocumented
Declaration
Objective-C
- (instancetype)init;Swift
init!() -
Creates a new Screen annotation in the specified document.
Declaration
Parameters
docA document to which the annotation is added.
posA rectangle specifying the annotation’s bounds in default user space units.
Return Value
A newly created blank Screen annotation.
-
Returns the title of the annotation.
Declaration
Objective-C
- (NSString *)GetTitle;Swift
func getTitle() -> String!Return Value
A string representing the title of the annotation.
-
Sets the title of the Annotation. (Optional)
Declaration
Objective-C
- (void)SetTitle:(NSString *)title;Swift
func setTitle(_ title: String!)Parameters
titleA string representing the title of the annotation.
-
Sets the action of the Screen annotation (Optional; PDF 1.1 )
Note
The action is an action that shall be performed when the annotation is activated.Declaration
Objective-C
- (void)SetAction:(PTAction *)action;Swift
func setAction(_ action: PTAction!)Parameters
actionAn action object representing the action of the annotation.
-
Returns the number indicating border color space of the annotation.
Declaration
Objective-C
- (int)GetBorderColorCompNum;Swift
func getBorderColorCompNum() -> Int32Return Value
An integer indicating a color space value from the ColorSpace::Type enum. That is, 1 corresponding to “e_device_gray”, 3 corresponding to “e_device_rgb”, and 4 corresponding to “e_device_cmyk”. 0 means this annotation had no color assigned.
-
Returns the border color of the annotation.
Note
The color can be in different color spaces: Gray, RGB, or CMYK. Call “GetBorderColorCompNum” to access the color space information corresponding to the border color.Return Value
A color object that denotes the color of the Screen border.
-
Sets the border color of the annotation. (Optional)
Declaration
Objective-C
- (void)SetBorderColor:(PTColorPt *)col numcomp:(int)numcomp;Swift
func setBorderColor(_ col: PTColorPt!, numcomp: Int32)Parameters
colA color object that denotes the color of the screen border.
numcompAn integer which value indicates the color space used for the parameter c.
-
Returns the number indicating background color space of the annotation.
Declaration
Objective-C
- (int)GetBackgroundColorCompNum;Swift
func getBackgroundColorCompNum() -> Int32Return Value
An integer indicating a color space value from the ColorSpace::Type enum. That is, 1 corresponding to “e_device_gray”, 3 corresponding to “e_device_rgb”, and 4 corresponding to “e_device_cmyk” if color space is applicable, 0 means no background color was assigned.
-
Returns the background color of the annotation.
Note
The color can be in different color spaces: Gray, RGB, or CMYK. Call “GetBackgroundColorCompNum” to access the color space information corresponding to the border color.Declaration
Objective-C
- (PTColorPt *)GetBackgroundColor;Swift
func getBackgroundColor() -> PTColorPt!Return Value
A color object that denotes the color of the Screen background.
-
Sets the background color of the annotation. (Optional)
Declaration
Objective-C
- (void)SetBackgroundColor:(PTColorPt *)col numcomp:(int)numcomp;Swift
func setBackgroundColor(_ col: PTColorPt!, numcomp: Int32)Parameters
colA color point that denotes the color of the screen background.
numcompAn integer which value indicates the color space used for the parameter c.
-
Returns static caption text of the annotation.
Note
The static caption is the annotation’s normal caption, which shall be displayed when it is not interacting with the user.Declaration
Objective-C
- (NSString *)GetStaticCaptionText;Swift
func getStaticCaptionText() -> String!Return Value
A string containing the static caption text of the annotation.
-
Sets static caption text of the annotation. (Optional; button fields only)
Note
The static caption is the annotation’s normal caption, which shall be displayed when it is not interacting with the user.Declaration
Objective-C
- (void)SetStaticCaptionText:(NSString *)contents;Swift
func setStaticCaptionText(_ contents: String!)Parameters
contentsA string containing the static caption text of the annotation.
-
Returns the rollover caption text of the annotation.
Note
The rollover caption shall be displayed when the user rolls the cursor into its active area without pressing the mouse button.Declaration
Objective-C
- (NSString *)GetRolloverCaptionText;Swift
func getRolloverCaptionText() -> String!Return Value
A string containing the rollover caption text of the annotation.
-
Sets the roll over caption text of the annotation. (Optional; button fields only)
Note
The rollover caption shall be displayed when the user rolls the cursor into its active area without pressing the mouse button.Declaration
Objective-C
- (void)SetRolloverCaptionText:(NSString *)contents;Swift
func setRolloverCaptionText(_ contents: String!)Parameters
contentsA string containing the roll over caption text of the annotation.
-
Returns the button down caption text of the annotation.
Note
The button down caption shall be displayed when the mouse button is pressed within its active area.Declaration
Objective-C
- (NSString *)GetMouseDownCaptionText;Swift
func getMouseDownCaptionText() -> String!Return Value
A string containing the button down text of the annotation.
-
Sets the button down caption text of the annotation. (Optional; button fields only)
Note
The button down caption shall be displayed when the mouse button is pressed within its active area.Declaration
Objective-C
- (void)SetMouseDownCaptionText:(NSString *)contents;Swift
func setMouseDownCaptionText(_ contents: String!)Parameters
contentsA string containing the button down text of the annotation.
-
Returns the static icon associated with the annotation.
Note
The static icon object is a form XObject defining the annotation’s normal icon, which shall be displayed when it is not interacting with the user.Return Value
An SDF object that represents the static icon associated with the annotation.
-
Sets the static icon associated with the annotation. (Optional; button fields only)
Note
The static icon object is a form XObject defining the annotation’s normal icon, which shall be displayed when it is not interacting with the user.Declaration
Objective-C
- (void)SetStaticIcon:(PTObj *)icon;Swift
func setStaticIcon(_ icon: PTObj!)Parameters
iconAn SDF object that represents the static icon associated with the annotation.
-
Returns the rollover icon associated with the annotation.
Note
The rollover icon object is a form XObject defining the annotation’s rollover icon, which shall be displayed when the user rolls the cursor into its active area without pressing the mouse button.Return Value
An SDF object that represents the rollover icon associated with the annotation.
-
Sets the rollover icon associated with the annotation. (Optional; button fields only)
Note
The rollover icon object is a form XObject defining the annotation’s rollover icon, which shall be displayed when the user rolls the cursor into its active area without pressing the mouse button.Declaration
Objective-C
- (void)SetRolloverIcon:(PTObj *)icon;Swift
func setRolloverIcon(_ icon: PTObj!)Parameters
iconAn SDF object that represents the rollover icon associated with the annotation.
-
Returns the Mouse Down icon associated with the annotation.
Note
The Mouse Down icon object is a form XObject defining the annotation’s alternate (down) icon, which shall be displayed when the mouse button is pressed within its active area.Return Value
An SDF object that represents the Mouse Down icon associated with the annotation.
-
Sets the Mouse Down icon associated with the annotation. (Optional; button fields only)
Note
The Mouse Down icon object is a form XObject defining the annotation’s alternate (down) icon, which shall be displayed when the mouse button is pressed within its active area.Declaration
Objective-C
- (void)SetMouseDownIcon:(PTObj *)icon;Swift
func setMouseDownIcon(_ icon: PTObj!)Parameters
iconAn SDF object that represents the Mouse Down icon associated with the annotation.
-
Returns the Icon and caption relationship of the annotation.
See
IconCaptionRelationDeclaration
Objective-C
- (PTScreenIconCaptionRelation)GetIconCaptionRelation;Swift
func getIconCaptionRelation() -> PTScreenIconCaptionRelationReturn Value
A value of the “IconCaptionRelation” enum type. Default value: e_NoIcon.
-
Sets the Icon and caption relationship of the annotation. (Optional; pushbutton fields only)
See
IconCaptionRelationDeclaration
Objective-C
- (void)SetIconCaptionRelation:(PTScreenIconCaptionRelation)icr;Swift
func setIconCaptionRelation(_ icr: PTScreenIconCaptionRelation)Parameters
icrA value of the “IconCaptionRelation” enum type. Default value: e_NoIcon.
-
Returns the condition under which the icon should be scaled.
See
ScaleConditionDeclaration
Objective-C
- (PTScreenScaleCondition)GetScaleCondition;Swift
func getScaleCondition() -> PTScreenScaleConditionReturn Value
A value of the “ScaleCondition” enum type. Default value: e_Always.
-
Sets the condition under which the icon should be scaled. (Optional)
Declaration
Objective-C
- (void)SetScaleCondition:(PTScreenScaleCondition)sc;Swift
func setScaleCondition(_ sc: PTScreenScaleCondition)Parameters
scA value of the “ScaleCondition” enum type. Default value: e_Always.
-
Returns the Scale Type of the annotation.
See
ScaleTypeDeclaration
Objective-C
- (PTScreenScaleType)GetScaleType;Swift
func getScaleType() -> PTScreenScaleTypeReturn Value
A value of the “ScaleType” enum which represents the Scale Type of the annotation. Default value: P.
-
Sets the Scale Type of the annotation. (Optional)
See
ScaleTypeDeclaration
Objective-C
- (void)SetScaleType:(PTScreenScaleType)st;Swift
func setScaleType(_ st: PTScreenScaleType)Parameters
stAn entry of the “ScaleType” enum which represents the Scale Type of the annotation. Default value: P.
-
Returns the horizontal leftover space of the icon within the annotation.
Note
the horizontal leftover is a number that shall be between 0.0 and 1.0 indicating the fraction of leftover space to allocate at the left. A value of 0.0 shall position the icon at the left of the annotation rectangle. A value of 0.5 shall center it in the horizontal direction within the rectangle. This entry shall be used only if the icon is scaled proportionally. Default value: 0.5.Declaration
Objective-C
- (double)GetHIconLeftOver;Swift
func getHIconLeftOver() -> DoubleReturn Value
A number indicating the horizontal leftover space of the icon within the annotation.
-
Sets the horizontal leftover space of the icon within the annotation. (Optional)
Note
the horizontal leftover space is a number that shall be between 0.0 and 1.0 indicating the fraction of leftover space to allocate at the left. A value of 0.0 shall position the icon at the left of the annotation rectangle. A value of 0.5 shall center it in the horizontal direction within the rectangle. This entry shall be used only if the icon is scaled proportionally. Default value: 0.5.Declaration
Objective-C
- (void)SetHIconLeftOver:(double)hl;Swift
func setHIconLeftOver(_ hl: Double)Parameters
hlA number indicating the horizontal leftover space of the icon within the annotation.
-
Returns the vertical leftover space of the icon within the annotation.
Note
the vertical leftover space is a number that shall be between 0.0 and 1.0 indicating the fraction of leftover space to allocate at the bottom of the icon. A value of 0.0 shall position the icon at the bottom of the annotation rectangle. A value of 0.5 shall center it in the vertical direction within the rectangle. This entry shall be used only if the icon is scaled proportionally. Default value: 0.5.Declaration
Objective-C
- (double)GetVIconLeftOver;Swift
func getVIconLeftOver() -> DoubleReturn Value
a number indicating the vertical leftover space of the icon within the annotation.
-
Sets the vertical leftover space of the icon within the annotation. (Optional)
Note
the vertical leftover space is a number that shall be between 0.0 and 1.0 indicating the fraction of leftover space to allocate at the bottom of the icon. A value of 0.0 shall position the icon at the bottom of the annotation rectangle. A value of 0.5 shall center it in the vertical direction within the rectangle. This entry shall be used only if the icon is scaled proportionally. Default value: 0.5.Declaration
Objective-C
- (void)SetVIconLeftOver:(double)vl;Swift
func setVIconLeftOver(_ vl: Double)Parameters
vlA number indicating the vertical leftover space of the icon within the annotation.
-
Returns the “fit full” flag.
Note
the fit full flag, if true, indicates that the button appearance shall be scaled to fit fully within the bounds of the annotation without taking into consideration the line width of the border. Default value: false.Declaration
Objective-C
- (BOOL)GetFitFull;Swift
func getFitFull() -> BoolReturn Value
A boolean value indicating the “fit full” flag value.
-
Sets the “fit full” flag. (Optional)
Note
the fit full flag, if true, indicates that the button appearance shall be scaled to fit fully within the bounds of the annotation without taking into consideration the line width of the border. Default value: false.Declaration
Objective-C
- (void)SetFitFull:(BOOL)ff;Swift
func setFitFull(_ ff: Bool)Parameters
ffA boolean value indicating the “fit full” flag value.
PTScreen Class Reference