main.h (260e9a87725c090ba5835b1f9f0b62fa2f96036f) | main.h (371584c2eae4cf827fd406ba26c14f021adaaa70) |
---|---|
1/* $Id: main.h,v 1.20 2014/12/31 16:52:40 schwarze Exp $ */ | 1/* $Id: main.h,v 1.25 2016/07/08 22:29:05 schwarze Exp $ */ |
2/* 3 * Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> | 2/* 3 * Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> |
4 * Copyright (c) 2014 Ingo Schwarze <schwarze@openbsd.org> | 4 * Copyright (c) 2014, 2015 Ingo Schwarze <schwarze@openbsd.org> |
5 * 6 * Permission to use, copy, modify, and distribute this software for any 7 * purpose with or without fee is hereby granted, provided that the above 8 * copyright notice and this permission notice appear in all copies. 9 * | 5 * 6 * Permission to use, copy, modify, and distribute this software for any 7 * purpose with or without fee is hereby granted, provided that the above 8 * copyright notice and this permission notice appear in all copies. 9 * |
10 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | 10 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHORS DISCLAIM ALL WARRANTIES |
11 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | 11 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF |
12 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | 12 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR |
13 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 14 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 15 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 16 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 17 */ 18 19#define UNCONST(a) ((void *)(uintptr_t)(const void *)(a)) 20 | 13 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 14 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 15 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 16 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 17 */ 18 19#define UNCONST(a) ((void *)(uintptr_t)(const void *)(a)) 20 |
21__BEGIN_DECLS | 21struct roff_man; 22struct manoutput; |
22 | 23 |
23struct mchars; 24struct mdoc; 25struct man; 26 | |
27/* 28 * Definitions for main.c-visible output device functions, e.g., -Thtml 29 * and -Tascii. Note that ascii_alloc() is named as such in 30 * anticipation of latin1_alloc() and so on, all of which map into the 31 * terminal output routines with different character settings. 32 */ 33 | 24/* 25 * Definitions for main.c-visible output device functions, e.g., -Thtml 26 * and -Tascii. Note that ascii_alloc() is named as such in 27 * anticipation of latin1_alloc() and so on, all of which map into the 28 * terminal output routines with different character settings. 29 */ 30 |
34void *html_alloc(const struct mchars *, char *); 35void html_mdoc(void *, const struct mdoc *); 36void html_man(void *, const struct man *); | 31void *html_alloc(const struct manoutput *); 32void html_mdoc(void *, const struct roff_man *); 33void html_man(void *, const struct roff_man *); |
37void html_free(void *); 38 | 34void html_free(void *); 35 |
39void tree_mdoc(void *, const struct mdoc *); 40void tree_man(void *, const struct man *); | 36void tree_mdoc(void *, const struct roff_man *); 37void tree_man(void *, const struct roff_man *); |
41 | 38 |
42void man_mdoc(void *, const struct mdoc *); 43void man_man(void *, const struct man *); | 39void man_mdoc(void *, const struct roff_man *); 40void man_man(void *, const struct roff_man *); |
44 | 41 |
45void *locale_alloc(const struct mchars *, char *); 46void *utf8_alloc(const struct mchars *, char *); 47void *ascii_alloc(const struct mchars *, char *); | 42void *locale_alloc(const struct manoutput *); 43void *utf8_alloc(const struct manoutput *); 44void *ascii_alloc(const struct manoutput *); |
48void ascii_free(void *); | 45void ascii_free(void *); |
49void ascii_sepline(void *); | |
50 | 46 |
51void *pdf_alloc(const struct mchars *, char *); 52void *ps_alloc(const struct mchars *, char *); | 47void *pdf_alloc(const struct manoutput *); 48void *ps_alloc(const struct manoutput *); |
53void pspdf_free(void *); 54 | 49void pspdf_free(void *); 50 |
55void terminal_mdoc(void *, const struct mdoc *); 56void terminal_man(void *, const struct man *); 57 58__END_DECLS | 51void terminal_mdoc(void *, const struct roff_man *); 52void terminal_man(void *, const struct roff_man *); 53void terminal_sepline(void *); |