Topics
All
MacOS
(Only)
Windows
(Only)
Linux
(Only, Not)
iOS
(Only, Not)
Components
Crossplatform Mac & Win
Server
Client
Old
Deprecated
Guides
Examples
Videos
New in version:
12.1
12.2
12.3
12.4
12.5
13.0
13.1
13.2
13.3
13.4
Statistic
FMM
Blog
DynaPDF.SetFontWeight
Changes the font weight.
Component |
Version |
macOS |
Windows |
Linux |
Server |
iOS SDK |
DynaPDF
|
4.4 |
✅ Yes |
✅ Yes |
✅ Yes |
✅ Yes |
✅ Yes |
MBS( "DynaPDF.SetFontWeight"; PDF; Weight )
More
MBS(
"DynaPDF.SetFontWeight"; /* Changes the font weight. */
$PDF; /* The PDF reference returned from
DynaPDF.New. */
$Weight) /* The new weight value.e.g. 100 */
Less
Parameters
Parameter |
Description |
Example |
PDF |
The PDF reference returned from DynaPDF.New. |
$pdf |
Weight |
The new weight value. |
100 |
Result
Returns OK or error.
Description
Changes the font weight.
The font weight specifies the thickness or boldness of a font. Not all fonts are available in a bold style; such a font style can then be emulated only. The property FontWeight specifies the weight that should be emulated. The visual weight of a font depends on the base weight in that the font was defined. For example, the glyphs of an ultra-light font look also light if an extra-bold weight will be emulated.
However, a bold font will never be emulated if the font is already available in a bold style. To disable the emulation of bold fonts set the property to 100 or 0.
Font weights:
- 100 - 300 // Ultra-light, Light
- 400 - 500 // Standard
- 600 - 1000 // Bold, Extrabold
See also SetFontWeight function in DynaPDF manual.
See also
This function checks for a license.
Created 21st October 2014, last changed 25th February 2021
DynaPDF.SetFontSelMode
-
DynaPDF.SetGStateFlags