THPDFPage.WideTextOutBox Method
宣告
function WideTextOutBox(X, Y, LineSpacing, BoxWidth, BoxHeight: Integer; Text: WideString; Align: THPDFJustificationType): Integer;
單元
THPDFPage.WideTextOutBoxHPDFDoc
參數
| 名稱 | 說明 |
|---|---|
X, Y | 文字框左上角座標(使用者空間單位) |
LineSpacing | 行間距(使用者空間單位) |
BoxWidth | 文字框寬度(使用者空間單位) |
BoxHeight | 文字框高度(使用者空間單位) |
Text | 要输出的 Unicode 文字 |
Align | 对齐方式(jtLeft、jtCenter、jtRight、jtJustified) |
// 在 200×300 的文本框内左对齐输出中文段落
var
Placed: Integer;
begin
Placed := HPDF.CurrentPage.WideTextOutBox(
30, 700, 16, 200, 300,
WideString('这是一段中文测试文字,将在文本框内自动换行并正确处理 CJK 字符间距。'),
jtLeft);
end; | WideTextOutBox 所使用的輸入 |