mtext_get_prop_keys(3m17n)
π NAME π
mtext_get_prop_keys β bestie, this is the one that tells you which text properties are chilling at a specific spot in your M-text π
β¨ SYNOPSIS β¨
int mtext_get_prop_keys (MText * mt, int pos, MSymbol ** keys)
π DESCRIPTION π
okay so picture this: you got an M-text, you got a position, and you wanna know which text property keys are living at that exact spot. That's literally what this does π«Ά
The mtext_get_prop_keys() function creates an array whose elements are the keys of text properties found at position pos in M-text mt, and sets *keys to the address of the created array.
β οΈ okay this part is IMPORTANT bestie, do not skip: the user is responsible to free the memory allocated for the array. Like, that array is yours now. You made it, you clean it up. No cap. π§Ήβ¨
πΈ RETURN VALUE πΈ
If the operation was successful, mtext_get_prop_keys() returns the length of the key list. Iconic. Slay. That's your count right there π―
Otherwise it returns -1 and assigns an error code to the external variable merror_code. π Not the vibe, but at least it tells you why.
π ERRORS π
MERROR_RANGEβ yeah, that's the one, the range said no π
π SEE ALSO π
Your little prop-having, prop-getting, prop-pushing, prop-popping friend group, fr fr:
mtext_get_prop()mtext_put_prop()mtext_put_prop_values()mtext_get_prop_values()mtext_push_prop()mtext_pop_prop()
π COPYRIGHT π
Copyright (C) 2001 Information-technology Promotion Agency (IPA)
Copyright (C) 2001-2011 National Institute of Advanced Industrial Science and Technology (AIST)
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License <http://www.gnu.org/licenses/fdl.html>.
and that's the whole page, bestie π this was Version 1.8.4, dated Mon Sep 25 2023, from the m17n library β go get those property keys, you absolute main character πβ¨
π¦ where this page comes from
- debian trixie: m17n-docs 1.8.4-1
- ubuntu noble: m17n-docs 1.8.4-1
- ubuntu questing: m17n-docs 1.8.4-1
- ubuntu resolute: m17n-docs 1.8.4-1build1
- ubuntu stonking: m17n-docs 1.8.4-1build1
- Copyright (C) 2001 Information-technology Promotion Agency (IPA)
- Copyright (C) 2001-2011 National Institute of Advanced Industrial Science and Technology (AIST)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms