diff options
author | sabetts <sabetts> | 2006-03-15 05:43:38 +0000 |
---|---|---|
committer | sabetts <sabetts> | 2006-03-15 05:43:38 +0000 |
commit | 9c9e71d4e681112668240c6c0c9715b8f77ed673 (patch) | |
tree | 0d818469f129c7f7aecf933c93599f77df00e651 /src/format.h | |
parent | 0d47aa583ef5ce0178de264f46fcb028c8592e53 (diff) | |
download | ratpoison-9c9e71d4e681112668240c6c0c9715b8f77ed673.zip |
(init_user_commands): add optional argument to "info"
(cmd_info): handle optional argument
* src/format.c: new file
* src/format.h: new file
* Makefile.am (ratpoison_SOURCES): add format.c and format.h
* src/actions.c (set_infofmt): new function
(wingravity_to_string): char * instead of static char * because needed in format.c
(cmd_info): use format_string
* src/actions.h (wingravity_to_string): add prototype
* src/data.h (info_fmt): new variable
* src/main.c (init_defaults): set a value for defaults.info_fmt
* src/ratpoison.h: include format.h
* src/windows.c (get_window_list): use format_string
(isdigit): remove function as the formatting is now done in format.c
(concat_width): likewise
(format_window_name): likewise
Diffstat (limited to 'src/format.h')
-rw-r--r-- | src/format.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/format.h b/src/format.h new file mode 100644 index 0000000..83b6acb --- /dev/null +++ b/src/format.h @@ -0,0 +1,27 @@ +/* Prototypes for format functions. + * Copyright (C) 2006 Antti Nykänen <aon@iki.fi> + * + * This file is part of ratpoison. + * + * ratpoison is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * ratpoison is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this software; see the file COPYING. If not, write to + * the Free Software Foundation, Inc., 59 Temple Place, Suite 330, + * Boston, MA 02111-1307 USA + */ + +#ifndef _RATPOISON_FORMAT_H +#define _RATPOISON_FORMAT_H 1 + +void format_string(char *fmt, rp_window_elem *win_elem, struct sbuf *buffer); + +#endif /* _RATPOISON_FORMAT_H */ |