PdfPageStamp
概述
PdfPageStamp 是 Aspose.PDF FOSS 中用于 .NET 的类。继承自:Aspose.Pdf.Stamps.Stamp。
将一个 PDF 页面内容盖印到另一页上。
此类提供 6 个方法,用于在 .NET 程序中处理 PdfPageStamp 对象。可用的方法包括:ApplyTo、PdfPageStamp、Put、setStampId。在安装了 Aspose.PDF FOSS for .NET 包后,所有公共成员对任何 .NET 应用程序均可访问。属性:Background、BottomMargin、Height、HorizontalAlignment、IsBackground、LeftMargin,以及其他 14 项。
属性
| 名称 | 类型 | 访问 | 描述 |
|---|---|---|---|
Width | double | 读写 | 印章的宽度(单位:点)。 |
Height | double | 读写 | 印章的高度(单位:点)。 |
PdfPage | Page | 读写 | 被盖章的源页面。 |
StampId | int | 读写 | 在应用印章时作为 %StampId 内容流注释嵌入的可选标识符,以便 PdfContentEditor.GetStamps / DeleteStampById 稍后能够找到它。 |
ZoomX | double | 读写 | 对印章应用的水平缩放因子(1.0 = 原始尺寸)。 |
ZoomY | double | 读写 | 在印章上应用的垂直缩放系数(1.0 = 原始尺寸)。 |
XIndent | double | 读写 | 页面上的 X 位置。 |
YIndent | double | 读写 | 页面上的 Y 位置。 |
Rotate | Rotation | 读写 | 旋转 (0, 90, 180, 270)。 |
RotateAngle | double | 读写 | 任意旋转角度(以度为单位)。 |
Opacity | double | 读写 | 不透明度 (0.0 = 透明, 1.0 = 不透明)。 |
IsBackground | bool | 读写 | 印章是否绘制在页面内容之下。 |
Background | bool | 读写 | 是 IsBackground 的别名。 |
TopMargin | double | 读写 | 顶部边距偏移(以点为单位)。 |
BottomMargin | double | 读写 | 底部边距偏移(以点为单位)。 |
LeftMargin | double | 读写 | 左侧边距偏移(以点为单位)。 |
RightMargin | double | 读写 | 右边距偏移(单位为点)。 |
HorizontalAlignment | HorizontalAlignment | 读写 | 水平对齐。 |
VerticalAlignment | VerticalAlignment | 读写 | 垂直对齐。 |
OutlineWidth | double | 读写 | 印章字形/图形轮廓的笔画宽度,单位为点。 |
方法
| 签名 | 描述 |
|---|---|
PdfPageStamp(pdfPage: Page) | 从另一个文档的页面创建一个 PdfPageStamp。 |
Put(page: Page) | 与公共表面匹配的 ApplyTo 别名。 |
PdfPageStamp(fileName: string, pageIndex: int) | 从 fileName 的 PDF 中第 pageIndex 页(基于 1 的索引)创建一个 PdfPageStamp。 |
PdfPageStamp(stream: Stream, pageIndex: int) | 从流中读取的 PDF 中第 pageIndex(从 1 开始)的页面创建一个 PdfPageStamp。 |
ApplyTo(page: Page) | 将此印章应用于页面。 |
setStampId(id: int) | 设置 StampId。 |