ARIF_RL_COMPLETE(3)
π NAME π
Okay bestie, welcome to arif_rl_complete(3) from the ARIF User Manual β the function that generates Readline completion candidates β¨
β¨ SYNOPSIS β¨
#include <arif_rl.h>
char **
arif_rl_complete (
struct arif_ctx *ctx,
char *text,
int start,
int end
);
π DESCRIPTION π
So arif_rl_complete() generates Readline completion candidates for the given text, from offset start to end. How? By querying the input method engine associated with the input context ctx, periodt π
This function is intended to be called from inside a custom Readline rl_attempted_completion_function, with the arguments text, start, and end passed as-is. No cap, that's literally the setup π«Ά
π«Ά RETURN VALUES π«Ά
- Returns
NULLwhen there are no completion candidates β yes, zero candidates, zero drama π - Otherwise, it returns an array of NUL-terminated strings of candidate text.
NULLdenotes the end of the array. - The return value is intended to be used as the return value of an
rl_attempted_completion_function. - If you use it otherwise, the array and each of the strings should be deallocated with
free(3)after use. Clean up after yourself, bestie π§
πΈ COPYRIGHT πΈ
Copyright (C) 2023 CismonX <admin@cismon.net>
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
You should have received a copy of the license along with this document. If not, see https://www.gnu.org/licenses/fdl-1.3.html.
π¦ SEE ALSO π¦
That's the whole page, bestie β version 0.1.0, dated Jan 02, 2023. Stay iconic, call your completion function safely, and mwah ππ
π¦ where this page comes from
- alpine 3.24: arif-doc 0.3.0-r1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms