xref: /freebsd/lib/libdpv/dialogrc.h (revision 9d9cc24662d95b56a87e2d92d57899224cec42df)
1041394f3SDevin Teske /*-
2*9d9cc246SDevin Teske  * Copyright (c) 2013-2015 Devin Teske <dteske@FreeBSD.org>
3041394f3SDevin Teske  * All rights reserved.
4041394f3SDevin Teske  *
5041394f3SDevin Teske  * Redistribution and use in source and binary forms, with or without
6041394f3SDevin Teske  * modification, are permitted provided that the following conditions
7041394f3SDevin Teske  * are met:
8041394f3SDevin Teske  * 1. Redistributions of source code must retain the above copyright
9041394f3SDevin Teske  *    notice, this list of conditions and the following disclaimer.
10041394f3SDevin Teske  * 2. Redistributions in binary form must reproduce the above copyright
11041394f3SDevin Teske  *    notice, this list of conditions and the following disclaimer in the
12041394f3SDevin Teske  *    documentation and/or other materials provided with the distribution.
13041394f3SDevin Teske  *
14041394f3SDevin Teske  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15041394f3SDevin Teske  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16041394f3SDevin Teske  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17041394f3SDevin Teske  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18041394f3SDevin Teske  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19041394f3SDevin Teske  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20041394f3SDevin Teske  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21041394f3SDevin Teske  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22041394f3SDevin Teske  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23041394f3SDevin Teske  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24041394f3SDevin Teske  * SUCH DAMAGE.
25041394f3SDevin Teske  *
26041394f3SDevin Teske  * $FreeBSD$
27041394f3SDevin Teske  */
28041394f3SDevin Teske 
29041394f3SDevin Teske #ifndef _DIALOGRC_H_
30041394f3SDevin Teske #define _DIALOGRC_H_
31041394f3SDevin Teske 
32041394f3SDevin Teske #include <sys/types.h>
33041394f3SDevin Teske 
34041394f3SDevin Teske #include <figpar.h>
35041394f3SDevin Teske 
36041394f3SDevin Teske /* dialog(3) dlg_color_table[] attributes */
37041394f3SDevin Teske #define GAUGE_ATTR	33	/* entry used for gauge_color */
38041394f3SDevin Teske 
39041394f3SDevin Teske /* dialog(1) characteristics */
40041394f3SDevin Teske #define DIALOGRC	".dialogrc"
41041394f3SDevin Teske #define ENV_DIALOGRC	"DIALOGRC"
42041394f3SDevin Teske #define ENV_HOME	"HOME"
43041394f3SDevin Teske 
44041394f3SDevin Teske /* dialog(1) `.dialogrc' characteristics */
45041394f3SDevin Teske extern uint8_t use_colors;
46041394f3SDevin Teske extern uint8_t use_shadow;
47041394f3SDevin Teske extern char gauge_color[];
48041394f3SDevin Teske extern char separator[];
49041394f3SDevin Teske 
50041394f3SDevin Teske __BEGIN_DECLS
51041394f3SDevin Teske void			 dialogrc_free(void);
52041394f3SDevin Teske int			 parse_dialogrc(void);
53*9d9cc246SDevin Teske struct figpar_config	*dialogrc_config_option(const char *_directive);
54041394f3SDevin Teske __END_DECLS
55041394f3SDevin Teske 
56041394f3SDevin Teske #endif /* !_DIALOGRC_H_ */
57