XMSETFONTUNITS(3)
π NAME π
okay so hi bestie!! π«Ά this page is all about XmSetFontUnits, and it lives in the (library call) section of the manual. What is it? Literally just a function that sets the font unit value for a display. That's her whole job. Simple. Iconic. Lowkey obsolete (we'll get there, and yes I'm already π about it).
π SYNOPSIS π
#include <Xm/Xm.h>
void XmSetFontUnits(
Display * display,
int h_value,
int v_value);
β¨ DESCRIPTION β¨
XmSetFontUnits is an external function you call to initialize font unit values. Why would you even want that? Because your app might want to specify resolution-independent data based on a global font size β that's the whole dream, the vision, the aesthetic. π¦
π«Ά THE VIBE CHECK THAT ACTUALLY MATTERS: this function must be called before any widgets with resolution-independent data are created. Before. Not during, not after, not "oops I'll just squeeze it in." It's giving "first line or it doesn't count," fr fr.
Want the full lore on resolution independence? Go read the XmNunitType resource description in the reference pages for XmGadget, XmManager, and XmPrimitive. π
Also important: this function sets the font units for all screens on the display. Every. Single. One. No picking favourites here. π
π NOTE, and bestie, I need you to sit down for this one:XmSetFontUnitsis obsolete and exists purely for compatibility with previous releases. Instead of using this function, provide initial values or callXtSetValuesfor theXmScreenresourcesXmNhorizontalFontUnitandXmNverticalFontUnit. She's a legacy queen, but she is still legacy. No cap.
The arguments, one at a time, because we don't skip:
displayβ Defines the display for which this font unit value is to be applied. π₯οΈh_valueβ Specifies the value to be used for horizontal units in the conversion calculations.h_valueβ Specifies the value to be used for vertical units in the conversion calculations. π
and yes, the page really does label that third one h_value too. It's the vertical one going by the description. I'm just the messenger. π
π RELATED π
The girls that came before and the girls that come after, all linked up and thriving:
and that's the whole page, bestie!! π we read it top to bottom, and down at the very bottom where the footer lives it just says XmSetFontUnits(library call) all over again β no version number, no date, just her name one more time for the road. slay, honestly. β¨πΈπ¦
π¦ where this page comes from
- alpine 3.24: motif-doc 2.5.2-r0 Β· LGPL-2.1-or-later
- arch rolling: openmotif 2.3.8-4 Β· LGPL-2.1-or-later
- centos-stream 9: motif-devel 2.3.4-32.el9 Β· LGPLv2+
- centos-stream 9: motif-devel 2.3.4-32.el9 Β· LGPLv2+
- epel 10: motif-devel 2.3.8-2.el10_2 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-1.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-1.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-2.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-2.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 44: motif-devel 2.3.8-3.fc44 Β· LicenseRef-Callaway-LGPLv2+
- fedora 44: motif-devel 2.3.8-3.fc44 Β· LicenseRef-Callaway-LGPLv2+
- nixos 26.05: motif 2.3.8
- nixpkgs unstable: motif 2.3.8
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms