GRAPHEME_IS_TITLECASE(3)

πŸ“¦ version 3.0.0, in nixos 26.05, nixpkgs unstable

πŸ’– GRAPHEME_IS_TITLECASE(3) πŸ’–

okay so bestie, this is a page from the Library Functions Manual and it's lowkey one of the cutest little checks in the whole grapheme library. let's get into it πŸŽ€


✨ NAME ✨

grapheme_is_titlecase β€” check if codepoint array is titlecase πŸ‘‘

🌸 SYNOPSIS 🌸

#include <grapheme.h>

size_t
grapheme_is_titlecase(const uint_least32_t *str, size_t len,
    size_t *caselen);

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so grapheme_is_titlecase() is literally the vibe check πŸ’… β€” it checks if the codepoint array str is titlecase, and then it writes the length of the matching titlecase-sequence to the integer pointed to by caselen, unless caselen is set to NULL (in which case she simply doesn't bother, respect 🫢).

and like, here's the tea on len β˜• β€” if len is set to SIZE_MAX (and yes, stdint.h is already included by grapheme.h, so you don't gotta do anything extra, slay), then the codepoint array src is interpreted to be NUL-terminated and processing stops when a NUL-byte is encountered. periodt. πŸ”₯

also, for UTF-8-encoded input data you can use grapheme_is_titlecase_utf8(3) instead β€” she's right there, use her 🌈

⭐ RETURN VALUES ⭐

grapheme_is_titlecase() returns true if the codepoint array str is titlecase, otherwise false. that's it, that's the whole thing πŸ’€

πŸ’œ SEE ALSO πŸ’œ

πŸ‘‘ STANDARDS πŸ‘‘

grapheme_is_titlecase() is compliant with the Unicode 17.0.0 specification. no cap, certified iconic πŸŽ€

🧚 AUTHORS 🧚

Laslo Hunhold <dev@frign.de> β€” thank you for your service king 🫑


ngl this one is short and sweet, which is honestly its main character energy 🌸 go off, titlecase check.

and that's the whole page bestie!! brought to you with love by suckless.org, dated 2022-10-06 β€” catch you on the next manpage, mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from