xref: /vim-8.2.3635/src/proto.h (revision ba3ff539)
1 /* vi:set ts=8 sts=4 sw=4 noet:
2  *
3  * VIM - Vi IMproved	by Bram Moolenaar
4  *
5  * Do ":help uganda"  in Vim to read copying and usage conditions.
6  * Do ":help credits" in Vim to see a list of people who contributed.
7  */
8 
9 /*
10  * proto.h: include the (automatically generated) function prototypes
11  */
12 
13 /*
14  * Don't include these while generating prototypes.  Prevents problems when
15  * files are missing.
16  */
17 #if !defined(PROTO) && !defined(NOPROTO)
18 
19 /*
20  * Machine-dependent routines.
21  */
22 /* avoid errors in function prototypes */
23 # if !defined(FEAT_X11) && !defined(FEAT_GUI_GTK)
24 #  define Display int
25 #  define Widget int
26 # endif
27 # ifndef FEAT_GUI_GTK
28 #  define GdkEvent int
29 #  define GdkEventKey int
30 # endif
31 # ifndef FEAT_X11
32 #  define XImage int
33 # endif
34 
35 # ifdef AMIGA
36 #  include "os_amiga.pro"
37 # endif
38 # if defined(UNIX) || defined(VMS)
39 #  include "os_unix.pro"
40 # endif
41 # ifdef WIN3264
42 #  include "os_win32.pro"
43 #  include "os_mswin.pro"
44 #  include "winclip.pro"
45 #  if (defined(__GNUC__) && !defined(__MINGW32__)) \
46 	|| (defined(__BORLANDC__) && __BORLANDC__ < 0x502)
47 extern int _stricoll(char *a, char *b);
48 #  endif
49 # endif
50 # ifdef VMS
51 #  include "os_vms.pro"
52 # endif
53 # ifdef __BEOS__
54 #  include "os_beos.pro"
55 # endif
56 # ifdef __QNX__
57 #  include "os_qnx.pro"
58 # endif
59 
60 # ifdef FEAT_CRYPT
61 #  include "blowfish.pro"
62 #  include "crypt.pro"
63 #  include "crypt_zip.pro"
64 # endif
65 # include "buffer.pro"
66 # include "charset.pro"
67 # ifdef FEAT_CSCOPE
68 #  include "if_cscope.pro"
69 # endif
70 # include "dict.pro"
71 # include "diff.pro"
72 # include "digraph.pro"
73 # include "edit.pro"
74 # include "eval.pro"
75 # include "evalfunc.pro"
76 # include "ex_cmds.pro"
77 # include "ex_cmds2.pro"
78 # include "ex_docmd.pro"
79 # include "ex_eval.pro"
80 # include "ex_getln.pro"
81 # include "fileio.pro"
82 # include "fold.pro"
83 # include "getchar.pro"
84 # ifdef FEAT_HANGULIN
85 #  include "hangulin.pro"
86 # endif
87 # include "hardcopy.pro"
88 # include "hashtab.pro"
89 # include "json.pro"
90 # include "list.pro"
91 # include "main.pro"
92 # include "mark.pro"
93 # include "memfile.pro"
94 # include "memline.pro"
95 # ifdef FEAT_MENU
96 #  include "menu.pro"
97 # endif
98 # ifdef FEAT_FKMAP
99 #  include "farsi.pro"
100 # endif
101 # ifdef FEAT_ARABIC
102 #  include "arabic.pro"
103 # endif
104 
105 /* These prototypes cannot be produced automatically. */
106 int
107 #  ifdef __BORLANDC__
108 _RTLENTRYF
109 #  endif
110 smsg(char_u *, ...);
111 
112 int
113 #  ifdef __BORLANDC__
114 _RTLENTRYF
115 #  endif
116 smsg_attr(int, char_u *, ...);
117 
118 int
119 #  ifdef __BORLANDC__
120 _RTLENTRYF
121 #  endif
122 smsg_attr_keep(int, char_u *, ...);
123 
124 int
125 #  ifdef __BORLANDC__
126 _RTLENTRYF
127 #  endif
128 vim_snprintf_add(char *, size_t, char *, ...)
129 #ifdef USE_PRINTF_FORMAT_ATTRIBUTE
130     __attribute__((format(printf, 3, 4)))
131 #endif
132     ;
133 
134 int
135 #  ifdef __BORLANDC__
136 _RTLENTRYF
137 #  endif
138 vim_snprintf(char *, size_t, char *, ...)
139 #ifdef USE_PRINTF_FORMAT_ATTRIBUTE
140     __attribute__((format(printf, 3, 4)))
141 #endif
142     ;
143 
144 int vim_vsnprintf(char *str, size_t str_m, char *fmt, va_list ap);
145 int vim_vsnprintf_typval(char *str, size_t str_m, char *fmt, va_list ap, typval_T *tvs);
146 
147 # include "message.pro"
148 # include "misc1.pro"
149 # include "misc2.pro"
150 #ifndef HAVE_STRPBRK	    /* not generated automatically from misc2.c */
151 char_u *vim_strpbrk(char_u *s, char_u *charset);
152 #endif
153 #ifndef HAVE_QSORT
154 /* Use our own qsort(), don't define the prototype when not used. */
155 void qsort(void *base, size_t elm_count, size_t elm_size, int (*cmp)(const void *, const void *));
156 #endif
157 # include "move.pro"
158 # if defined(FEAT_MBYTE) || defined(FEAT_XIM) || defined(FEAT_KEYMAP) \
159 	|| defined(FEAT_POSTSCRIPT)
160 #  include "mbyte.pro"
161 # endif
162 # include "normal.pro"
163 # include "ops.pro"
164 # include "option.pro"
165 # include "popupmnu.pro"
166 # ifdef FEAT_QUICKFIX
167 #  include "quickfix.pro"
168 # endif
169 # include "regexp.pro"
170 # include "screen.pro"
171 # if defined(FEAT_CRYPT) || defined(FEAT_PERSISTENT_UNDO)
172 #  include "sha256.pro"
173 # endif
174 # include "search.pro"
175 # include "spell.pro"
176 # include "spellfile.pro"
177 # include "syntax.pro"
178 # include "tag.pro"
179 # include "term.pro"
180 # ifdef FEAT_TERMINAL
181 #  include "terminal.pro"
182 # endif
183 # if defined(HAVE_TGETENT) && (defined(AMIGA) || defined(VMS))
184 #  include "termlib.pro"
185 # endif
186 # include "ui.pro"
187 # include "undo.pro"
188 # include "userfunc.pro"
189 # include "version.pro"
190 # include "window.pro"
191 
192 # ifdef FEAT_LUA
193 #  include "if_lua.pro"
194 # endif
195 
196 # ifdef FEAT_MZSCHEME
197 #  include "if_mzsch.pro"
198 # endif
199 
200 # ifdef FEAT_PYTHON
201 #  include "if_python.pro"
202 # endif
203 
204 # ifdef FEAT_PYTHON3
205 #  include "if_python3.pro"
206 # endif
207 
208 # ifdef FEAT_TCL
209 #  include "if_tcl.pro"
210 # endif
211 
212 # ifdef FEAT_RUBY
213 #  include "if_ruby.pro"
214 # endif
215 
216 /* Ugly solution for "BalloonEval" not being defined while it's used in some
217  * .pro files. */
218 # ifdef FEAT_BEVAL
219 #  include "beval.pro"
220 # else
221 #  define BalloonEval int
222 # endif
223 
224 # ifdef FEAT_NETBEANS_INTG
225 #  include "netbeans.pro"
226 # endif
227 # ifdef FEAT_JOB_CHANNEL
228 #  include "channel.pro"
229 
230 /* Not generated automatically, to add extra attribute. */
231 void ch_log(channel_T *ch, const char *fmt, ...)
232 #ifdef USE_PRINTF_FORMAT_ATTRIBUTE
233     __attribute__((format(printf, 2, 3)))
234 #endif
235     ;
236 
237 # endif
238 
239 # if defined(FEAT_GUI) || defined(FEAT_JOB_CHANNEL)
240 #  if defined(UNIX) || defined(MACOS_X)
241 #   include "pty.pro"
242 #  endif
243 # endif
244 
245 # ifdef FEAT_GUI
246 #  include "gui.pro"
247 #  if !defined(HAVE_SETENV) && !defined(HAVE_PUTENV) && !defined(VMS)
248 extern int putenv(const char *string);			/* in misc2.c */
249 #   ifdef USE_VIMPTY_GETENV
250 extern char_u *vimpty_getenv(const char_u *string);	/* in misc2.c */
251 #   endif
252 #  endif
253 #  ifdef FEAT_GUI_W32
254 #   include "gui_w32.pro"
255 #  endif
256 #  ifdef FEAT_GUI_GTK
257 #   include "gui_gtk.pro"
258 #   include "gui_gtk_x11.pro"
259 #  endif
260 #  ifdef FEAT_GUI_MOTIF
261 #   include "gui_motif.pro"
262 #   include "gui_xmdlg.pro"
263 #  endif
264 #  ifdef FEAT_GUI_ATHENA
265 #   include "gui_athena.pro"
266 #   ifdef FEAT_BROWSE
267 extern char *vim_SelFile(Widget toplevel, char *prompt, char *init_path, int (*show_entry)(), int x, int y, guicolor_T fg, guicolor_T bg, guicolor_T scroll_fg, guicolor_T scroll_bg);
268 #   endif
269 #  endif
270 #  ifdef FEAT_GUI_MAC
271 #   include "gui_mac.pro"
272 #  endif
273 #  ifdef FEAT_GUI_X11
274 #   include "gui_x11.pro"
275 #  endif
276 #  ifdef FEAT_GUI_PHOTON
277 #   include "gui_photon.pro"
278 #  endif
279 #  ifdef FEAT_SUN_WORKSHOP
280 #   include "workshop.pro"
281 #  endif
282 # endif	/* FEAT_GUI */
283 
284 # ifdef FEAT_OLE
285 #  include "if_ole.pro"
286 # endif
287 # if defined(FEAT_CLIENTSERVER) && defined(FEAT_X11)
288 #  include "if_xcmdsrv.pro"
289 # endif
290 
291 /*
292  * The perl include files pollute the namespace, therefore proto.h must be
293  * included before the perl include files.  But then CV is not defined, which
294  * is used in if_perl.pro.  To get around this, the perl prototype files are
295  * not included here for the perl files.  Use a dummy define for CV for the
296  * other files.
297  */
298 #if defined(FEAT_PERL) && !defined(IN_PERL_FILE)
299 # define CV void
300 # ifdef __BORLANDC__
301   #pragma option -pc
302 # endif
303 # include "if_perl.pro"
304 # ifdef __BORLANDC__
305   #pragma option -p.
306 # endif
307 # include "if_perlsfio.pro"
308 #endif
309 
310 #ifdef MACOS_CONVERT
311 # include "os_mac_conv.pro"
312 #endif
313 #if defined(MACOS_X_DARWIN) && defined(FEAT_CLIPBOARD) && !defined(FEAT_GUI)
314 /* functions in os_macosx.m */
315 void clip_mch_lose_selection(VimClipboard *cbd);
316 int clip_mch_own_selection(VimClipboard *cbd);
317 void clip_mch_request_selection(VimClipboard *cbd);
318 void clip_mch_set_selection(VimClipboard *cbd);
319 #endif
320 
321 #ifdef __BORLANDC__
322 # define _PROTO_H
323 #endif
324 #endif /* !PROTO && !NOPROTO */
325