OCCT-Light 0.1
C ABI and C++ veneer for multi-language CAD workflows
Loading...
Searching...
No Matches
occtl_text_info Struct Reference

#include <occtl_text.h>

Collaboration diagram for occtl_text_info:

Public Attributes

uint32_t struct_version
 
const void * p_next
 
occtl_axis2_placement_t placement
 
const char * utf8_text
 
const char * font_family
 
const char * font_path
 
occtl_text_font_aspect_t font_aspect
 
double height
 
occtl_text_halign_t horizontal_align
 
occtl_text_valign_t vertical_align
 

Detailed Description

Info for occtl_text_measure, occtl_text_make_faces, and occtl_text_make_wires.

Lays out utf8_text on the XY plane of placement (Z up, X along the writing direction) at the given glyph height. Lines are separated by newline characters and aligned according to horizontal_align / vertical_align. Exactly one of font_family / font_path must be non-NULL; font_path wins when both are set.

Member Data Documentation

◆ font_aspect

occtl_text_font_aspect_t occtl_text_info::font_aspect

Style aspect; defaults to REGULAR.

◆ font_family

const char* occtl_text_info::font_family

Borrows it. Family name (e.g. "Arial"). NULL when font_path is used.

◆ font_path

const char* occtl_text_info::font_path

Borrows it. Absolute path to a .ttf/.otf file. NULL to look up by family.

◆ height

double occtl_text_info::height

Glyph cap height in model units; strictly positive.

◆ horizontal_align

occtl_text_halign_t occtl_text_info::horizontal_align

Horizontal alignment; defaults to LEFT.

◆ p_next

const void* occtl_text_info::p_next

Reserved for extensions; must be NULL.

◆ placement

occtl_axis2_placement_t occtl_text_info::placement

Baseline frame; defaults to XOY.

◆ struct_version

uint32_t occtl_text_info::struct_version

Must be OCCTL_TEXT_INFO_VERSION_1.

◆ utf8_text

const char* occtl_text_info::utf8_text

Borrows it. Required, non-empty UTF-8 string.

◆ vertical_align

occtl_text_valign_t occtl_text_info::vertical_align

Vertical alignment; defaults to BASELINE.


The documentation for this struct was generated from the following file: