TtfFontMetrics.MeasureString
MeasureString(string, double)
测量字符串并返回字符串宽度。
public override double MeasureString(string unicode, double fontSize)
| 参数 | 类型 | 描述 |
|---|---|---|
| unicode | String | Unicode 字符串。 |
| fontSize | Double | 字体大小。 |
返回值
字符串宽度。
另见
- class TtfFontMetrics
- namespace Aspose.Font.Ttf
- assembly Aspose.Font
MeasureString(uint[], double)
测量以字符代码数组表示的文本并返回字符串宽度。
public double MeasureString(uint[] charCodes, double fontSize)
| 参数 | 类型 | 描述 |
|---|---|---|
| charCodes | UInt32[] | 文本字符串表示为字符代码数组。 |
| fontSize | Double | 字体大小。 |
返回值
字符串宽度。
另见
- class TtfFontMetrics
- namespace Aspose.Font.Ttf
- assembly Aspose.Font