1*cdf8408cSAntonio Huete Jimenez /* $NetBSD: filecomplete.h,v 1.14 2021/09/26 13:45:54 christos Exp $ */ 232fe07f8SJohn Marino 332fe07f8SJohn Marino /*- 432fe07f8SJohn Marino * Copyright (c) 1997 The NetBSD Foundation, Inc. 532fe07f8SJohn Marino * All rights reserved. 632fe07f8SJohn Marino * 732fe07f8SJohn Marino * This code is derived from software contributed to The NetBSD Foundation 832fe07f8SJohn Marino * by Jaromir Dolecek. 932fe07f8SJohn Marino * 1032fe07f8SJohn Marino * Redistribution and use in source and binary forms, with or without 1132fe07f8SJohn Marino * modification, are permitted provided that the following conditions 1232fe07f8SJohn Marino * are met: 1332fe07f8SJohn Marino * 1. Redistributions of source code must retain the above copyright 1432fe07f8SJohn Marino * notice, this list of conditions and the following disclaimer. 1532fe07f8SJohn Marino * 2. Redistributions in binary form must reproduce the above copyright 1632fe07f8SJohn Marino * notice, this list of conditions and the following disclaimer in the 1732fe07f8SJohn Marino * documentation and/or other materials provided with the distribution. 1832fe07f8SJohn Marino * 1932fe07f8SJohn Marino * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS 2032fe07f8SJohn Marino * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 2132fe07f8SJohn Marino * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 2232fe07f8SJohn Marino * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 2332fe07f8SJohn Marino * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 2432fe07f8SJohn Marino * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 2532fe07f8SJohn Marino * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 2632fe07f8SJohn Marino * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 2732fe07f8SJohn Marino * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 2832fe07f8SJohn Marino * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 2932fe07f8SJohn Marino * POSSIBILITY OF SUCH DAMAGE. 3032fe07f8SJohn Marino */ 3132fe07f8SJohn Marino #ifndef _FILECOMPLETE_H_ 3232fe07f8SJohn Marino #define _FILECOMPLETE_H_ 3332fe07f8SJohn Marino 3432fe07f8SJohn Marino int fn_complete(EditLine *, 3532fe07f8SJohn Marino char *(*)(const char *, int), 3632fe07f8SJohn Marino char **(*)(const char *, int, int), 3712db70c8Szrj const wchar_t *, const wchar_t *, const char *(*)(const char *), size_t, 3832fe07f8SJohn Marino int *, int *, int *, int *); 39*cdf8408cSAntonio Huete Jimenez int fn_complete2(EditLine *, 40*cdf8408cSAntonio Huete Jimenez char *(*)(const char *, int), 41*cdf8408cSAntonio Huete Jimenez char **(*)(const char *, int, int), 42*cdf8408cSAntonio Huete Jimenez const wchar_t *, const wchar_t *, const char *(*)(const char *), size_t, 43*cdf8408cSAntonio Huete Jimenez int *, int *, int *, int *, unsigned int); 44*cdf8408cSAntonio Huete Jimenez #define FN_QUOTE_MATCH 1U /* Quote the returned match */ 4532fe07f8SJohn Marino 46ae19eda8Szrj void fn_display_match_list(EditLine *, char **, size_t, size_t, 47ae19eda8Szrj const char *(*)(const char *)); 4832fe07f8SJohn Marino char *fn_tilde_expand(const char *); 4932fe07f8SJohn Marino char *fn_filename_completion_function(const char *, int); 5032fe07f8SJohn Marino 5132fe07f8SJohn Marino #endif 52