This function sets the positioning mode in the Typesetter. The positioning mode tells the Typesetter whether to place glyphs at fractional pixel positions or snap their output X and/or Y coordinates to the closest whole pixel positions before the glyphs are actually rasterized by the Rasterizer.
When D-Type Engine is initialized, the positioning mode is already set in the Typesetter to the recommended default value (DV_POSITIONING_ENGINE_DEFAULT_A).
This function can be used in conjunction with dtTypesetterSetHinting. For further details and illustrations, see Appendix — Positioning And Hinting.
When the glyph positioning mode is set to fractional (in either direction), you can use the dtTypesetterSetSubpixels function to set the number of possible subpixel positions, and consequently, control the utilization/efficiency of the bitmap cache.
Parameter | Description |
---|---|
engine |
Handle of the previously created Standard Engine instance. |
positioning |
Sets one of the positioning modes. The positioning mode tells the Typesetter how to position glyphs. At present, the following values are supported: positioning = 0 (DV_POSITIONING_ENGINE_DEFAULT_A) — Engine Default A (same as 8) positioning = 1 (DV_POSITIONING_ENGINE_DEFAULT_B) — Engine Default B (same as 9) positioning = 2 (DV_POSITIONING_USER_DEFAULT_A) — User Default A (same as 4) positioning = 3 (DV_POSITIONING_USER_DEFAULT_B) — User Default B (same as 5) positioning = 4 (DV_POSITIONING_FRACX_FRACY) — Frac X, Frac Y positioning = 5 (DV_POSITIONING_FRACX_INTY) — Frac X, Int Y positioning = 6 (DV_POSITIONING_INTX_FRACY) — Int X, Frac Y positioning = 7 (DV_POSITIONING_INTX_INTY) — Int X, Int Y positioning = 8 (DV_POSITIONING_AUTO_A) — Auto A positioning = 9 (DV_POSITIONING_AUTO_B) — Auto B |
flag |
Specifies action with respect to the Typesetter's bitmap cache. Currently supported values are:
|
If successful, the return value is 1. Otherwise, the function returns 0.