ConvertTextToPathsA
内容流编辑、字体
说明
ConvertTextToPaths 的 ANSI 变体
字符串参数按 ANSI 文本接受,其余行为与宽字符串入口点完全相同
语法
Delphi
Function TPDFlib.ConvertTextToPaths(Const PageRange: WideString= ''; Options: Integer= PDF_TEXT_PATH_DEFAULT): Integer;
ActiveX
Function PDFlib::ConvertTextToPaths(PageRange As String, Options As Long) As Long
DLL
int DLConvertTextToPaths(int InstanceID, const wchar_t *PageRange, int Options);
int DLConvertTextToPathsA(int InstanceID, const char *PageRange, int Options);
返回值
| 1 or greater | 已转换的显示文本指令数 |
|---|---|
| 0 | 未找到符合条件的文本,范围或选项无效,或者转换失败,请检查 LastErrorCode 以区分错误 |
错误代码
| 506 | 源字体无法提供受支持的矢量字形程序 |
|---|---|
| 507 | 文本裁剪渲染模式需要无法由独立字形 Form 表示的裁剪路径 |
| 508 | 文本程序、字体状态或递归 Form 资源作用域格式错误或存在歧义 |
示例
Converted := PDF.ConvertTextToPaths('1-3,5', PDF_TEXT_PATH_DEFAULT);
If (Converted= 0)and (PDF.LastErrorCode<> 0) Then
raise Exception.Create(PDF.LastError);