diff options
author | Karel Zak | 2014-04-03 16:09:57 +0200 |
---|---|---|
committer | Karel Zak | 2014-04-03 16:09:57 +0200 |
commit | 0925a9dd6cd65feb8cb2d4d66551363f4af161e9 (patch) | |
tree | 9981e45aee1274f959a9b32f3cbdffabc8a45d8c /libsmartcols/src/libsmartcols.h.in | |
parent | fdisk: print table header as bold (diff) | |
download | kernel-qcow2-util-linux-0925a9dd6cd65feb8cb2d4d66551363f4af161e9.tar.gz kernel-qcow2-util-linux-0925a9dd6cd65feb8cb2d4d66551363f4af161e9.tar.xz kernel-qcow2-util-linux-0925a9dd6cd65feb8cb2d4d66551363f4af161e9.zip |
libsmartcols: clean up flags usage
* rename flags functions to scols_table_enable_*
* rename *_no_foo() functions to _nofoo()
* output formats are mutually exclusive, so don't use flags there
* don't assume symbols in scols_new_table(), use scols_table_set_symbols()
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'libsmartcols/src/libsmartcols.h.in')
-rw-r--r-- | libsmartcols/src/libsmartcols.h.in | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/libsmartcols/src/libsmartcols.h.in b/libsmartcols/src/libsmartcols.h.in index b77b11e37..98d3e4c28 100644 --- a/libsmartcols/src/libsmartcols.h.in +++ b/libsmartcols/src/libsmartcols.h.in @@ -109,7 +109,7 @@ extern int scols_column_is_tree(struct libscols_column *cl); extern int scols_column_is_trunc(struct libscols_column *cl); extern int scols_column_is_right(struct libscols_column *cl); extern int scols_column_is_strict_width(struct libscols_column *cl); -extern int scols_column_is_no_extremes(struct libscols_column *cl); +extern int scols_column_is_noextremes(struct libscols_column *cl); extern int scols_column_set_flags(struct libscols_column *cl, int flags); extern int scols_column_get_flags(struct libscols_column *cl); @@ -149,24 +149,23 @@ extern struct libscols_line *scols_copy_line(struct libscols_line *ln); extern int scols_table_colors_wanted(struct libscols_table *tb); extern int scols_table_is_raw(struct libscols_table *tb); extern int scols_table_is_ascii(struct libscols_table *tb); -extern int scols_table_is_no_headings(struct libscols_table *tb); +extern int scols_table_is_noheadings(struct libscols_table *tb); extern int scols_table_is_empty(struct libscols_table *tb); extern int scols_table_is_export(struct libscols_table *tb); -extern int scols_table_is_max(struct libscols_table *tb); +extern int scols_table_is_maxout(struct libscols_table *tb); extern int scols_table_is_tree(struct libscols_table *tb); extern int scols_table_enable_colors(struct libscols_table *tb, int enable); -extern int scols_table_set_raw(struct libscols_table *tb, int enable); -extern int scols_table_set_ascii(struct libscols_table *tb, int enable); -extern int scols_table_set_no_headings(struct libscols_table *tb, int enable); -extern int scols_table_set_export(struct libscols_table *tb, int enable); -extern int scols_table_set_max(struct libscols_table *tb, int enable); -extern int scols_table_set_tree(struct libscols_table *tb, int enable); - -extern struct libscols_table *scols_new_table(struct libscols_symbols *syms); +extern int scols_table_enable_raw(struct libscols_table *tb, int enable); +extern int scols_table_enable_ascii(struct libscols_table *tb, int enable); +extern int scols_table_enable_noheadings(struct libscols_table *tb, int enable); +extern int scols_table_enable_export(struct libscols_table *tb, int enable); +extern int scols_table_enable_maxout(struct libscols_table *tb, int enable); + +extern struct libscols_table *scols_new_table(void); extern void scols_ref_table(struct libscols_table *tb); extern void scols_unref_table(struct libscols_table *tb); -extern int scols_table_add_column(struct libscols_table *tb, struct libscols_column *cl, int flags); +extern int scols_table_add_column(struct libscols_table *tb, struct libscols_column *cl); extern int scols_table_remove_column(struct libscols_table *tb, struct libscols_column *cl); extern int scols_table_remove_columns(struct libscols_table *tb); extern struct libscols_column *scols_table_new_column(struct libscols_table *tb, const char *name, double whint, int flags); |