1 /*--------------------------------*-H-*---------------------------------*
2  * File:    protos.h
3  *----------------------------------------------------------------------*
4  *
5  * All portions of code are copyright by their respective author/s.
6  * Copyright (c) 1997-2001   Geoff Wing <gcw@pobox.com>
7  * Copyright (c) 2004        Sergey Popov <p_sergey@jungo.com>
8  * Copyright (c) 2004        Jingmin Zhou <jimmyzhou@users.sourceforge.net>
9  *
10  * This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program; if not, write to the Free Software
22  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23  *----------------------------------------------------------------------*/
24 
25 #ifndef __PROTOS_H__
26 #define __PROTOS_H__
27 
28 
29 /* Begin prototypes of command.c */
30 void		 rxvt_cmd_write                   __PROTO((rxvt_t* r, int page, const unsigned char* str, unsigned int count));
31 FILE*            rxvt_popen_printer               __PROTO((rxvt_t *r, const char *pipeName));
32 int              rxvt_pclose_printer              __PROTO((FILE *stream));
33 void             rxvt_xterm_seq                   __PROTO((rxvt_t* r, int page, int op, const char* str, unsigned char resp __attribute__((unused))));
34 void             rxvt_tt_printf                   __PROTO((rxvt_t* r, int page, const char* fmt,...));
35 void             rxvt_tt_write                    __PROTO((rxvt_t* r, int page, const unsigned char* d, int len));
36 void             rxvt_pointer_unblank             __PROTO((rxvt_t* r, int page));
37 void             rxvt_resize_on_subwin            __PROTO((rxvt_t* r, resize_reason_t reason));
38 void           	 rxvt_resize_on_font           	  __PROTO((rxvt_t* r, char* fontname));
39 /* End prototypes of command.c */
40 
41 
42 /* Begin prototypes of encoding.c */
43 #ifdef MULTICHAR_SET
44 void             rxvt_decode_euc2jis              __PROTO((unsigned char* str, int len));
45 void             rxvt_decode_sjis2jis             __PROTO((unsigned char* str, int len));
46 void             rxvt_decode_gb180302jis          __PROTO((unsigned char* str, int len));
47 void             rxvt_set_multichar_encoding      __PROTO((rxvt_t* r, const char* str));
48 #endif
49 void             rxvt_decode_dummy                __PROTO((unsigned char* str, int len));
50 void             rxvt_set_default_locale          __PROTO((rxvt_t *r));
51 char*            rxvt_get_encoding_from_locale    __PROTO((rxvt_t *r));
52 void             rxvt_set_default_font_x11        __PROTO((rxvt_t *r));
53 char*            rxvt_fallback_mfont_x11          __PROTO((rxvt_t *r));
54 #ifdef XFT_SUPPORT
55 void             rxvt_set_default_font_xft        __PROTO((rxvt_t *r));
56 char*            rxvt_fallback_mfont_xft          __PROTO((rxvt_t *r));
57 #endif
58 char*            rxvt_encoding_name               __PROTO((rxvt_t *r));
59 /* End prototypes of defaultfont.c */
60 
61 
62 /* Begin prototypes of grkelot.c */
63 #ifdef GREEK_SUPPORT
64 void             greek_init                       __PROTO((void));
65 void             greek_end                        __PROTO((void));
66 void             greek_reset                      __PROTO((void));
67 void             greek_setmode                    __PROTO((int greek_mode));
68 int              greek_getmode                    __PROTO((void));
69 int              greek_xlat                       __PROTO((char* s, int num_chars));
70 #endif
71 /* End prototypes of grkelot.c */
72 
73 /* Begin prototypes of macros.c */
74 int		 rxvt_parse_macros		  __PROTO((rxvt_t*, const char *, const char *, macro_priority_t priority));
75 void		 rxvt_cleanup_macros		  __PROTO((rxvt_t*));
76 Bool		 rxvt_set_action		  __PROTO((action_t*, char*));
77 int		 rxvt_process_macros		  __PROTO((rxvt_t*, KeySym, XKeyEvent*));
78 int		 rxvt_dispatch_action		  __PROTO((rxvt_t*, action_t*, XEvent *ev));
79 
80 void		 rxvt_toggle_verybold		  __PROTO((rxvt_t*));
81 void		 rxvt_toggle_subwin		  __PROTO((rxvt_t*, const unsigned char *));
82 /* End prototypes of macros.c */
83 
84 /* Begin prototypes of init.c */
85 int              rxvt_init_vars                   __PROTO((rxvt_t* r));
86 void             rxvt_init_secondary              __PROTO((rxvt_t* r));
87 void		 rxvt_set_jumpscroll		  __PROTO((rxvt_t* r));
88 const char    ** rxvt_init_resources              __PROTO((rxvt_t* r, int argc, const char* const *argv));
89 #ifdef XFT_SUPPORT
90 void		 rxvt_fade_color                  __PROTO((rxvt_t* r, const XColor *xcol, unsigned long *pix_return, XftColor *xft_return));
91 #else
92 void	         rxvt_fade_color                  __PROTO((rxvt_t* r, const XColor *xcol, unsigned long *pix_return, void *xft_return));
93 #endif
94 int		 rxvt_set_fgbg_colors		  __PROTO((rxvt_t* r, int page));
95 int		 rxvt_set_vt_colors		  __PROTO((rxvt_t* r, int page));
96 void		 rxvt_copy_color                  __PROTO((rxvt_t*, int, int));
97 void		 rxvt_set_color                   __PROTO((rxvt_t*, int, const XColor*));
98 void             rxvt_init_env                    __PROTO((rxvt_t *r));
99 void             rxvt_init_xlocale                __PROTO((rxvt_t *r));
100 void		 rxvt_init_fifo	                  __PROTO((rxvt_t *r));
101 void             rxvt_init_command                __PROTO((rxvt_t* r));
102 CARD32           rxvt_get_desktop                 __PROTO((rxvt_t* r));
103 void             rxvt_create_show_windows         __PROTO((rxvt_t* r, int argc, const char* const *argv));
104 void             rxvt_destroy_termwin             __PROTO((rxvt_t* r, int page));
105 void             rxvt_create_termwin              __PROTO((rxvt_t* r, int page, int profile,  const char TAINTED * title));
106 const char*	 getProfileOption		  __PROTO(( rxvt_t *r, int profile, int resource ));
107 Status		 ewmh_message			  __PROTO(( Display *, Window, Window, Atom, long, long, long, long, long));
108 int		 rxvt_async_exec		  __PROTO((rxvt_t*, const char *));
109 int              rxvt_run_command                 __PROTO((rxvt_t* r, int page, const char** argv));
110 void             clean_sigmasks_and_fds           __PROTO((rxvt_t* r, int page));
111 termenv_t        rxvt_get_termenv                 __PROTO((const char* str));
112 char**		 rxvt_string_to_argv    	  __PROTO((const char*, int*));
113 /* End prototypes of init.c */
114 
115 
116 /* Begin prototypes of logging.c */
117 #ifdef UTMP_SUPPORT
118 void             rxvt_makeutent                   __PROTO((rxvt_t* r, int page, const char* pty, const char* hostname));
119 void             rxvt_cleanutent                  __PROTO((rxvt_t* r, int page));
120 #endif
121 /* End prototypes of logging.c */
122 
123 
124 /* Begin prototypes of rxvtmem.c */
125 #ifdef OUR_MALLOC
126 void             rxvt_mem_init                    __PROTO((void));
127 void             rxvt_mem_exit                    __PROTO((void));
128 #endif /* OUR_MALLOC */
129 void*            rxvt_malloc                      __PROTO((size_t size));
130 void*            rxvt_calloc                      __PROTO((size_t number, size_t size));
131 void*            rxvt_realloc                     __PROTO((void *ptr, size_t size));
132 void             rxvt_free                        __PROTO((void *ptr));
133 /* End prototypes of rxvtmem.c */
134 
135 
136 /* Begin prototypes of main.c */
137 void             rxvt_privileges                  __PROTO((int mode));
138 RETSIGTYPE       rxvt_Child_signal                __PROTO((int sig __attribute__((unused))));
139 RETSIGTYPE       rxvt_Exit_signal                 __PROTO((int sig));
140 void		 rxvt_exit_request                __PROTO((rxvt_t*));
141 void             rxvt_clean_exit                  __PROTO((rxvt_t* r));
142 void		 rxvt_close_all_tabs		  __PROTO((rxvt_t* r));
143 void             rxvt_privileged_utmp             __PROTO((rxvt_t* r, int page, char action));
144 void             rxvt_privileged_ttydev           __PROTO((rxvt_t* r, int page, char action));
145 void             rxvt_tt_winsize                  __PROTO((int fd, unsigned short col, unsigned short row, pid_t pid));
146 void             rxvt_init_font_x11               __PROTO((rxvt_t *r));
147 int              rxvt_change_font_x11             __PROTO((rxvt_t* r, const char* fontname));
148 #ifdef XFT_SUPPORT
149 int              rxvt_init_font_xft               __PROTO((rxvt_t *r));
150 int              rxvt_change_font_xft             __PROTO((rxvt_t* r, const char* fontname));
151 #endif
152 void             rxvt_set_win_title               __PROTO((rxvt_t* r, Window win, const char* str));
153 void             rxvt_set_term_title              __PROTO((rxvt_t* r, const unsigned char* str));
154 void             rxvt_set_icon_name               __PROTO((rxvt_t* r, const unsigned char* str));
155 void             rxvt_set_window_color            __PROTO((rxvt_t* r, int page, int idx, const char* color));
156 void             rxvt_recolour_cursor             __PROTO((rxvt_t *r));
157 #ifdef XFT_SUPPORT
158 int              rxvt_alloc_xft_color             __PROTO((rxvt_t *r, const XColor *xcol, XftColor* xftcolor));
159 #endif
160 int              rxvt_parse_alloc_color           __PROTO((rxvt_t* r, XColor *screen_in_out, const char* colour));
161 int              rxvt_alloc_color                 __PROTO((rxvt_t* r, XColor *screen_in_out, const char* colour));
162 void             rxvt_set_widthheight             __PROTO((rxvt_t* r, unsigned int width, unsigned int height));
163 void             rxvt_IM_send_spot                __PROTO((rxvt_t *r));
164 void             rxvt_IM_set_fontset              __PROTO((rxvt_t* r, int idx));
165 void             rxvt_IM_init_callback            __PROTO((Display *unused __attribute__((unused)), XPointer client_data __attribute__((unused)), XPointer call_data __attribute__((unused))));
166 void             rxvt_IM_resize                   __PROTO((rxvt_t *r));
167 rxvt_t         * rxvt_get_r                       __PROTO((void));
168 /* End prototypes of main.c */
169 
170 
171 /* Begin prototypes of menubar.c */
172 #ifdef HAVE_MENUBAR
173 void             rxvt_menubar_resize              __PROTO((rxvt_t*));
174 void             rxvt_menubar_create              __PROTO((rxvt_t*));
175 void             rxvt_menubar_clean_exit          __PROTO((rxvt_t*));
176 int              rxvt_menubar_hide                __PROTO((rxvt_t*));
177 int              rxvt_menubar_show                __PROTO((rxvt_t*));
178 void             rxvt_menubar_expose              __PROTO((rxvt_t*));
179 void             rxvt_menubar_dispatcher          __PROTO((rxvt_t*, unsigned char*));
180 void             rxvt_menubar_control             __PROTO((rxvt_t*, XButtonEvent*));
181 void             rxvt_menubar_load_file           __PROTO((rxvt_t*, const unsigned char*));
182 int              rxvt_is_menubar_win              __PROTO((rxvt_t*, Window));
183 unsigned short   rxvt_menubar_height              __PROTO((rxvt_t*));
184 unsigned short   rxvt_menubar_rheight             __PROTO((rxvt_t*));
185 int              rxvt_menubar_visible             __PROTO((rxvt_t*));
186 void		 rxvt_menu_show			  __PROTO((rxvt_t*));
187 int		 rxvt_menu_select		  __PROTO((rxvt_t*, XButtonEvent*));
188 #endif
189 /* End prototypes of menubar.c */
190 
191 
192 /* Begin prototypes of misc.c */
193 char           * rxvt_r_basename                  __PROTO((const char* str));
194 int              rxvt_str_match                   __PROTO((const char* s1, const char* s2));
195 const char*      rxvt_str_skip_space              __PROTO((const char* str));
196 char*            rxvt_str_trim                    __PROTO((char* str));
197 int              rxvt_str_escaped                 __PROTO((char* str));
198 int		 rxvt_percent_interpolate         __PROTO((rxvt_t*, int, const char *, int, char *, int));
199 char**           rxvt_splitcommastring            __PROTO((const char* cs));
200 char*            rxvt_File_find                   __PROTO((const char* file, const char* ext, const char* path));
201 void             rxvt_draw_shadow                 __PROTO((Display *Xdisplay, Window win, GC gc, unsigned long topShadow, unsigned long botShadow, int x, int y, int w, int h));
202 void             rxvt_draw_triangle               __PROTO((Display *Xdisplay, Window win, GC gc, unsigned long topShadow, unsigned long botShadow, int x, int y, int w, int type));
203 /* End prototypes of misc.c */
204 
205 
206 /* Begin prototypes of netdisp.c */
207 #ifdef NET_DISPLAY
208 char           * rxvt_network_display             __PROTO((const char* display));
209 #endif
210 /* End prototypes of netdisp.c */
211 
212 
213 /* Begin prototypes of ptytty.c */
214 int              rxvt_get_pty                     __PROTO((int *fd_tty, char** ttydev));
215 int              rxvt_get_tty                     __PROTO((const char* ttydev));
216 int              rxvt_control_tty                 __PROTO((int fd_tty, const char* ttydev));
217 /* End prototypes of ptytty.c */
218 
219 
220 /* Begin prototypes of screen.c */
221 void
222 rxvt_draw_string_x11 (rxvt_t* r, Window win, GC gc, Region refreshRegion,
223 	int x, int y, char* str, int len, int (*draw_string)());
224 #ifdef XFT_SUPPORT
225 void
226 rxvt_draw_string_xft (rxvt_t* r, Drawable d, GC gc, Region refreshRegion,
227 	rend_t rend, int pfont,
228 	XftDraw* win, XftColor* fore, int x, int y, char* str, int len,
229 	void (*xftdraw_string)());
230 #endif
231 void             rxvt_init_screen                 __PROTO((rxvt_t* r));
232 void             rxvt_scr_reset                   __PROTO((rxvt_t* r, int page));
233 void             rxvt_scr_release                 __PROTO((rxvt_t* r, int page));
234 void             rxvt_scr_poweron                 __PROTO((rxvt_t* r, int page));
235 void             rxvt_scr_cursor                  __PROTO((rxvt_t* r, int page, int mode));
236 int              rxvt_scr_change_screen           __PROTO((rxvt_t* r, int page, int scrn));
237 void             rxvt_scr_color                   __PROTO((rxvt_t* r, int page, unsigned int color, int fgbg));
238 void             rxvt_scr_rendition               __PROTO((rxvt_t* r, int page, int set, int style));
239 int              rxvt_scroll_text                 __PROTO((rxvt_t* r, int page, int row1, int row2, int count, int spec));
240 void             rxvt_scr_add_lines               __PROTO((rxvt_t* r, int page, const unsigned char* str, int nlines, int len));
241 void             rxvt_scr_backspace               __PROTO((rxvt_t* r, int page));
242 void             rxvt_scr_tab                     __PROTO((rxvt_t* r, int page, int count));
243 void             rxvt_scr_backindex               __PROTO((rxvt_t* r, int page));
244 void             rxvt_scr_forwardindex            __PROTO((rxvt_t* r, int page));
245 void             rxvt_scr_gotorc                  __PROTO((rxvt_t* r, int page, int row, int col, int relative));
246 void             rxvt_scr_index                   __PROTO((rxvt_t* r, int page, enum page_dirn direction));
247 void             rxvt_scr_erase_line              __PROTO((rxvt_t* r, int page, int mode));
248 void             rxvt_scr_erase_screen            __PROTO((rxvt_t* r, int page, int mode));
249 void             rxvt_scr_E                       __PROTO((rxvt_t* r, int page));
250 void             rxvt_scr_insdel_lines            __PROTO((rxvt_t* r, int page, int count, int insdel));
251 void             rxvt_scr_insdel_chars            __PROTO((rxvt_t* r, int page, int count, int insdel));
252 void             rxvt_scr_scroll_region           __PROTO((rxvt_t* r, int page, int top, int bot));
253 void             rxvt_scr_cursor_visible          __PROTO((rxvt_t* r, int page, int mode));
254 void             rxvt_scr_autowrap                __PROTO((rxvt_t* r, int page, int mode));
255 void             rxvt_scr_relative_origin         __PROTO((rxvt_t* r, int page, int mode));
256 void             rxvt_scr_insert_mode             __PROTO((rxvt_t* r, int page, int mode));
257 void             rxvt_scr_set_tab                 __PROTO((rxvt_t* r, int page, int mode));
258 void             rxvt_scr_rvideo_mode             __PROTO((rxvt_t* r, int page, int mode));
259 void             rxvt_scr_report_position         __PROTO((rxvt_t* r, int page));
260 void             rxvt_scr_charset_choose          __PROTO((rxvt_t* r, int page, int set));
261 void             rxvt_scr_charset_set             __PROTO((rxvt_t* r, int page, int set, unsigned int ch));
262 int              rxvt_scr_get_fgcolor             __PROTO((rxvt_t *r));
263 int              rxvt_scr_get_bgcolor             __PROTO((rxvt_t *r));
264 void             rxvt_scr_expose                  __PROTO((rxvt_t* r, int page, int x, int y, int width, int height, Bool refresh));
265 void             rxvt_scr_touch                   __PROTO((rxvt_t* r, int page, Bool refresh));
266 int              rxvt_scr_move_to                 __PROTO((rxvt_t* r, int page, int y, int len));
267 int              rxvt_scr_page                    __PROTO((rxvt_t* r, int page, enum page_dirn direction, int nlines));
268 void             rxvt_scr_bell                    __PROTO((rxvt_t *r, int page));
269 void             rxvt_scr_printscreen             __PROTO((rxvt_t* r, int page, int fullhist, int pretty, int linecont, const char *pipeName));
270 void             rxvt_scr_refresh                 __PROTO((rxvt_t* r, int page, unsigned char refresh_type));
271 void             rxvt_scr_clear                   __PROTO((rxvt_t* r, int page));
272 void             rxvt_scr_dump                    __PROTO((rxvt_t* r, int page, int fd));
273 void             rxvt_selection_check             __PROTO((rxvt_t* r, int page, int check_more));
274 int              rxvt_selection_paste             __PROTO((rxvt_t* r, Window win, Atom prop, Bool delete_prop));
275 void             rxvt_selection_property          __PROTO((rxvt_t* r, Window win, Atom prop));
276 void             rxvt_selection_request           __PROTO((rxvt_t* r, int page, Time tm, int x, int y));
277 void             rxvt_selection_request_by_sel    __PROTO((rxvt_t* r, int page, Time tm, int x, int y, int sel));
278 void             rxvt_process_selectionclear      __PROTO((rxvt_t* r, int page));
279 void             rxvt_selection_make              __PROTO((rxvt_t* r, int page, Time tm));
280 void             rxvt_selection_click             __PROTO((rxvt_t* r, int page, int clicks, int x, int y));
281 void             rxvt_selection_extend            __PROTO((rxvt_t* r, int page, int x, int y, int flag));
282 void             rxvt_selection_rotate            __PROTO((rxvt_t* r, int page, int x, int y));
283 void             rxvt_paste_file                  __PROTO((rxvt_t* r, int page, Time tm, int x, int y, char* filename));
284 void             rxvt_process_selectionrequest    __PROTO((rxvt_t* r, int page, const XSelectionRequestEvent *rq));
285 void             rxvt_pixel_position              __PROTO((rxvt_t* r, int *x, int *y));
286 /* End prototypes of screen.c */
287 
288 
289 /* Begin prototypes of scrollbar-next.c */
290 #ifdef NEXT_SCROLLBAR
291 void             rxvt_scrollbar_init_next         __PROTO((rxvt_t *r));
292 void             rxvt_scrollbar_exit_next         __PROTO((rxvt_t *r));
293 int              rxvt_scrollbar_show_next         __PROTO((rxvt_t* r, int update, int last_top, int last_bot, int scroller_len));
294 #endif
295 /* End prototypes of scrollbar-next.c */
296 
297 
298 /* Begin prototypes of scrollbar-rxvt.c */
299 #ifdef RXVT_SCROLLBAR
300 void             rxvt_scrollbar_init_rxvt         __PROTO((rxvt_t *r));
301 void             rxvt_scrollbar_exit_rxvt         __PROTO((rxvt_t *r));
302 int              rxvt_scrollbar_show_rxvt         __PROTO((rxvt_t* r, int update __attribute__((unused)), int last_top, int last_bot, int scroller_len));
303 #endif
304 /* End prototypes of scrollbar-rxvt.c */
305 
306 
307 /* Begin prototypes of scrollbar-xterm.c */
308 #ifdef XTERM_SCROLLBAR
309 void             rxvt_scrollbar_init_xterm        __PROTO((rxvt_t *r));
310 void             rxvt_scrollbar_exit_xterm        __PROTO((rxvt_t *r));
311 int              rxvt_scrollbar_show_xterm        __PROTO((rxvt_t* r, int update __attribute__((unused)), int last_top, int last_bot, int scroller_len));
312 #endif
313 /* End prototypes of scrollbar-xterm.c */
314 
315 
316 /* Begin prototypes of scrollbar-plain.c */
317 #ifdef PLAIN_SCROLLBAR
318 void             rxvt_scrollbar_init_plain        __PROTO((rxvt_t *r));
319 void             rxvt_scrollbar_exit_plain        __PROTO((rxvt_t *r));
320 int              rxvt_scrollbar_show_plain        __PROTO((rxvt_t* r, int update __attribute__((unused)), int last_top, int last_bot, int scroller_len));
321 #endif
322 /* End prototypes of scrollbar-plain.c */
323 
324 
325 /* Begin prototypes of scrollbar-sgi.c */
326 #ifdef SGI_SCROLLBAR
327 void             rxvt_scrollbar_init_sgi          __PROTO((rxvt_t *r));
328 void             rxvt_scrollbar_exit_sgi          __PROTO((rxvt_t *r));
329 int              rxvt_scrollbar_show_sgi          __PROTO((rxvt_t* r, int update __attribute__((unused)), int last_top, int last_bot, int scroller_len));
330 #endif
331 /* End prototypes of scrollbar-sgi.c */
332 
333 
334 /* Begin prototypes of scrollbar.c */
335 #ifdef HAVE_SCROLLBARS
336 int              rxvt_scrollbar_visible           __PROTO((rxvt_t* r));
337 void             rxvt_scrollbar_init              __PROTO((rxvt_t* r));
338 void             rxvt_scrollbar_create            __PROTO((rxvt_t* r));
339 void             rxvt_scrollbar_clean_exit        __PROTO((rxvt_t* r));
340 void             rxvt_scrollbar_resize            __PROTO((rxvt_t* r));
341 int              rxvt_scrollbar_hide              __PROTO((rxvt_t* r));
342 int              rxvt_scrollbar_show              __PROTO((rxvt_t* r));
343 int              rxvt_scrollbar_update            __PROTO((rxvt_t* r, int update));
344 unsigned short   rxvt_scrollbar_width             __PROTO((rxvt_t* r));
345 unsigned short   rxvt_scrollbar_rwidth            __PROTO((rxvt_t* r));
346 int              rxvt_is_scrollbar_win            __PROTO((rxvt_t* r, Window w));
347 unsigned long	 rxvt_scrollbar_bg		  __PROTO((rxvt_t* r));
348 #endif
349 /* End prototypes of scrollbar.c */
350 
351 
352 /* Begin prototypes of strings.c */
353 #ifdef HAVE_WCHAR_H
354 char*            rxvt_wcstombs                    __PROTO((const wchar_t* str, int len));
355 wchar_t*         rxvt_mbstowcs                    __PROTO((const char* str));
356 char*            rxvt_wcstoutf8                   __PROTO((const wchar_t* str));
357 wchar_t*         rxvt_utf8towcs                   __PROTO((const char* str));
358 #endif	/* HAVE_WCHAR_H */
359 int              ma_strcasecmp                    __PROTO((const char* s1, const char* s2));
360 int              ma_strncasecmp                   __PROTO((const char* s1, const char* s2, size_t n));
361 char*            ma_strcpy                        __PROTO((char* d, const char* s));
362 char*            ma_strncpy                       __PROTO((char* d, const char* s, size_t len));
363 int              ma_strcmp                        __PROTO((const char* s1, const char* s2));
364 int              ma_strncmp                       __PROTO((const char* s1, const char* s2, size_t len));
365 char*            ma_strcat                        __PROTO((char* s1, const char* s2));
366 char*            ma_strncat                       __PROTO((char* s1, const char* s2, size_t len));
367 size_t           ma_strlen                        __PROTO((const char* s));
368 char*            ma_strdup                        __PROTO((const char* s));
369 char UNTAINTED * ma_strndup                       __PROTO((const char TAINTED * s, size_t sz));
370 char*            ma_index                         __PROTO((const char* s, int c));
371 char*            ma_strchr                        __PROTO((const char* s, int c));
372 char*            ma_rindex                        __PROTO((const char* s, int c));
373 char*            ma_strrchr                       __PROTO((const char* s, int c));
374 void*            ma_memcpy                        __PROTO((void *s1, const void *s2, size_t len));
375 void*            ma_memmove                       __PROTO((void *d, const void *s, size_t len));
376 void             ma_bzero                         __PROTO((void *b, size_t len));
377 void*            ma_memset                        __PROTO((void *p, int c1, size_t len));
378 char*		 ma_strcasestr			  __PROTO((const char* phaystack, const char *pneedle));
379 
380 /* End prototypes of strings.c */
381 
382 /* Begin prototypes of transparent.c */
383 int		rxvt_set_opacity	     	 __PROTO((rxvt_t*));
384 void		rxvt_process_reparentnotify   	 __PROTO((rxvt_t*, XEvent*));
385 #ifdef TRANSPARENT
386 void		rxvt_toggle_transparency	 __PROTO((rxvt_t*));
387 void		refreshRootBGVars		 __PROTO((rxvt_t*));
388 int             rxvt_check_our_parents           __PROTO((rxvt_t*));
389 #endif
390 #if defined(TRANSPARENT) || defined(BACKGROUND_IMAGE)
391 void		rxvt_refresh_bg_image		 __PROTO((rxvt_t*, int, Bool));
392 #endif
393 #ifdef TINTING_SUPPORT
394 # if defined(HAVE_LIBXRENDER)
395 void		xrenderShadeParentPixmap     	 __PROTO((rxvt_t*, Pixmap, int, int, unsigned, unsigned, Bool));
396 # else
397 void            rxvt_shade_pixmap                __PROTO((rxvt_t*, Drawable, int, int, unsigned, unsigned));
398 # endif
399 #endif
400 /* End prototypes of transparent.c */
401 
402 /* Begin prototypes of xdefaults.c */
403 void             rxvt_usage                       __PROTO((int type));
404 int              rxvt_save_options                __PROTO((rxvt_t* r, const char* filename));
405 void             rxvt_get_options                 __PROTO((rxvt_t* r, int argc, const char* const *argv));
406 void             rxvt_extract_resources           __PROTO((rxvt_t* r, Display *display __attribute__((unused)), const char* name));
407 /* End prototypes of xdefaults.c */
408 
409 
410 #if defined(BACKGROUND_IMAGE) || defined(TRANSPARENT)
411 /* Begin prototypes of pixmap.c */
412 int              rxvt_scale_pixmap                __PROTO((rxvt_t* r, int page, const char* geom));
413 void             rxvt_resize_pixmap               __PROTO((rxvt_t* r, int page));
414 Pixmap           rxvt_load_bg_pixmap              __PROTO((rxvt_t* r, int page, const char* file));
415 Pixmap           rxvt_load_pixmap                 __PROTO((rxvt_t* r, const char* file, long* pw, long* ph));
416 /* End prototypes of pixmap.c */
417 
418 
419 /* Begin prototypes of jpg.c */
420 #ifdef USE_JPEG
421 long             JpegReadFileToPixmap             __PROTO((Display* display, Window window, GC gc, char* filename, Pixmap* pixmap, long* w, long* h));
422 #endif
423 /* End prototypes of jpg.c */
424 
425 
426 /* Begin prototypes of png.c */
427 #ifdef USE_PNG
428 long             PngReadFileToPixmap             __PROTO((Display* display, Window window, GC gc, char* filename, Pixmap* pixmap, long* w, long* h));
429 #endif
430 /* End prototypes of png.c */
431 #endif /* BACKGROUND_IMAGE || TRANSPARENT */
432 
433 
434 /* Begin prototypes of tabbar.c */
435 void             rxvt_append_page               __PROTO((rxvt_t*, int profile, const char TAINTED *title, const char *command));
436 void             rxvt_kill_page                 __PROTO((rxvt_t*, short));
437 void             rxvt_remove_page               __PROTO((rxvt_t*, short));
438 void             rxvt_activate_page             __PROTO((rxvt_t*, short));
439 void		 rxvt_tabbar_set_visible_tabs   __PROTO((rxvt_t*, Bool));
440 void		 refresh_tabbar_tab		__PROTO((rxvt_t*, int));
441 void             rxvt_tabbar_set_title          __PROTO((rxvt_t*, short, const unsigned char TAINTED *));
442 void             rxvt_tabbar_resize             __PROTO((rxvt_t*));
443 void             rxvt_tabbar_dispatcher         __PROTO((rxvt_t*, XButtonEvent*));
444 void		 rxvt_tabbar_button_release     __PROTO((rxvt_t*, XButtonEvent*));
445 int              rxvt_tabbar_visible            __PROTO((rxvt_t*));
446 void             rxvt_tabbar_expose             __PROTO((rxvt_t*, XEvent*));
447 int              rxvt_tabbar_hide               __PROTO((rxvt_t*));
448 int              rxvt_tabbar_show               __PROTO((rxvt_t*));
449 void             rxvt_tabbar_create             __PROTO((rxvt_t*));
450 void             rxvt_tabbar_clean_exit         __PROTO((rxvt_t*));
451 unsigned short   rxvt_tabbar_height             __PROTO((rxvt_t*));
452 unsigned short   rxvt_tabbar_rheight            __PROTO((rxvt_t*));
453 unsigned int     rxvt_tab_width                 __PROTO((rxvt_t*, const char*));
454 int              rxvt_is_tabbar_win             __PROTO((rxvt_t*, Window));
455 void             rxvt_tabbar_draw_buttons       __PROTO((rxvt_t*));
456 void		 rxvt_adjust_fd_number	        __PROTO((rxvt_t* r));
457 void             rxvt_tabbar_change_color       __PROTO((rxvt_t*, int, const char*));
458 void             rxvt_tabbar_highlight_tab      __PROTO((rxvt_t*, short, Bool));
459 void             rxvt_tabbar_move_tab           __PROTO((rxvt_t*, short));
460 void		 sync_tab_title		        __PROTO((rxvt_t*, int));
461 /* End prototypes of tabbar.c */
462 
463 /* Begin prototypes of session.c */
464 #ifdef HAVE_X11_SM_SMLIB_H
465 void            rxvt_process_ice_msgs          __PROTO((rxvt_t* r));
466 void            rxvt_session_init              __PROTO((rxvt_t* r));
467 void            rxvt_session_exit              __PROTO((rxvt_t* r));
468 #endif	/* HAVE_X11_SM_SMLIB_H */
469 /* End prototypes of session.c */
470 
471 /* Begin prototypes of debug.c */
472 int             rxvt_msg                       __PROTO((uint32_t, uint32_t, const char*, ...));
473 void            rxvt_parse_dbg_arguments       __PROTO((int argc, const char* const*));
474 /* End prototypes of debug.c */
475 
476 #endif  /* __PROTOS_H__ */
477 /*----------------------- end-of-file (H source) -----------------------*/
478