SetFormFieldBackgroundColorSep

表单字段、颜色

描述

设置指定表单字段的背景颜色。类似于 SetFormFieldBorderColor 函数,但使用通过 AddSeparationColor 函数添加的分色颜色的色调。PDF 规范不支持表单字段使用分色颜色空间,因此结果可能并非始终有效,尤其是在随后于 Acrobat 中编辑表单字段时。此功能专为需要将表单字段扁平化的情形添加

语法

Delphi

Function TPDFlib.SetFormFieldBackgroundColorSep(Index: Integer; Const ColorName: WideString; Tint: Double): Integer;

ActiveX

Function PDFlib::SetFormFieldBackgroundColorSep(Index As Long, ColorName As String, Tint As Double) As Long

DLL

int DLSetFormFieldBackgroundColorSep(int InstanceID, int Index, const wchar_t * ColorName, double Tint);

参数

Index表单字段的索引
ColorName通过 AddSeparationColor 函数使用的分色颜色名称
Tint要使用的颜色量。0 表示无颜色(白色),1 表示最大颜色量

返回值

0找不到表单字段,或找不到分离色名称
1已成功设置指定表单字段的背景颜色