Text metrics API #88

Merged
MartinFouilleul merged 1 commits from text_metrics into main 2023-09-10 17:29:32 +00:00
Collaborator

Replace confusing oc_text_bounding_box() with oc_font_text_metrics(), which returns:

  • the logical metrics of text
  • the ink bounding box of text
  • the advance vector

Also make oc_font_get_metrics() return scaled metrics, and add oc_font_get_metrics_unscaled() for the less common case where we need the unscaled metrics.

Replace confusing `oc_text_bounding_box()` with `oc_font_text_metrics()`, which returns: - the logical metrics of text - the ink bounding box of text - the advance vector Also make `oc_font_get_metrics()` return scaled metrics, and add `oc_font_get_metrics_unscaled()` for the less common case where we need the unscaled metrics.
MartinFouilleul added 1 commit 2023-09-10 17:29:23 +00:00
MartinFouilleul merged commit 5cdded57b3 into main 2023-09-10 17:29:32 +00:00
MartinFouilleul deleted branch text_metrics 2023-09-10 17:29:32 +00:00
Sign in to join this conversation.
No reviewers
No Label
macOS
windows
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: hmn/orca#88
No description provided.