Overview
The operation allows to set properties of the given annotations.
Parameters
Name
|
Type
|
Description
|
Input
|
Array
|
Array of IUnknown -based objects containing the IPXC_Annotation objects which will have their properties modified. Note that all of the annotations must belong to one document.
|
Output
|
Array
|
Not yet implemented.
|
Options
|
Dictionary
|
Dictionary with options of the operation.
|
Sample
02 | private void SetAnnotationsProperties(PDFXEdit.IPXV_Document Doc, PDFXEdit.IPXV_Inst Inst) |
04 | PDFXEdit.IPXS_Inst pSInt = (PDFXEdit.IPXS_Inst)Inst.GetExtension( "PXS" ); |
05 | uint nWidgetAtom = pSInt.StrToAtom( "Widget" ); |
06 | int nID = Inst.Str2ID( "op.annots.setProps" , false ); |
07 | PDFXEdit.IOperation Op = Inst.CreateOp(nID); |
08 | PDFXEdit.ICabNode input = Op.Params.Root[ "Input" ]; |
10 | PDFXEdit.IPXC_Page page = Doc.CoreDoc.Pages[0]; |
11 | uint nPageCount = page.GetAnnotsCount(); |
12 | for ( uint i = 0; i < nPageCount; i++) |
14 | PDFXEdit.IPXC_Annotation annot = page.GetAnnot(i); |
15 | if (annot.Type == nWidgetAtom) |
17 | if ((annot.Field != null ) && (annot.Field.Type == PDFXEdit.PXC_FormFieldType.FFT_Text)) |
18 | input.Add().v = annot; |
23 | PDFXEdit.ICabNode options = Op.Params.Root[ "Options" ]; |
24 | options[ "ContentRotation" ].v = 90; |
25 | options[ "MaskEx" ].v = 0x00000400; |
29 | private void SetLineWidthProfile(PDFXEdit.IPXV_Document Doc, PDFXEdit.IPXV_Inst Inst) |
31 | PDFXEdit.IPXS_Inst pSInt = (PDFXEdit.IPXS_Inst)Inst.GetExtension( "PXS" ); |
32 | int nID = Inst.Str2ID( "op.annots.setProps" , false ); |
33 | PDFXEdit.IOperation Op = Inst.CreateOp(nID); |
34 | PDFXEdit.ICabNode input = Op.Params.Root[ "Input" ]; |
36 | PDFXEdit.IPXC_Page page = Doc.CoreDoc.Pages[0]; |
37 | uint nPageCount = page.GetAnnotsCount(); |
38 | for ( uint i = 0; i < nPageCount; i++) |
40 | PDFXEdit.IPXC_Annotation annot = page.GetAnnot(i); |
41 | input.Add().v = annot; |
45 | PDFXEdit.ICabNode options = Op.Params.Root[ "Options" ]; |
46 | options[ "LineWidthProfile" ].v = Inst.Str2ID( "pencil.varProfile.5" ); |
47 | options[ "MaskEx" ].v = 0x00008000; |