Symbols

Symbols — can be used to overwrite default output chars (for ascii art)

Functions

Types and Values

Description

An API to access and modify data and information per symbol/symbol group.

Functions

scols_copy_symbols ()

struct libscols_symbols *
scols_copy_symbols (const struct libscols_symbols *sy);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

Returns

a newly allocated copy of the sy symbol group or NULL in case of an error.


scols_new_symbols ()

struct libscols_symbols *
scols_new_symbols (void);

Returns

a pointer to a newly allocated struct libscols_symbols instance.


scols_ref_symbols ()

void
scols_ref_symbols (struct libscols_symbols *sy);

Increases the refcount of sy .

Parameters

sy

a pointer to a struct libscols_symbols instance

 

scols_symbols_set_branch ()

int
scols_symbols_set_branch (struct libscols_symbols *sy,
                          const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent the branch part of a tree output

 

Returns

0, a negative value in case of an error.


scols_symbols_set_right ()

int
scols_symbols_set_right (struct libscols_symbols *sy,
                         const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent the right part of a tree output

 

Returns

0, a negative value in case of an error.


scols_symbols_set_vertical ()

int
scols_symbols_set_vertical (struct libscols_symbols *sy,
                            const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent the vertical part of a tree output

 

Returns

0, a negative value in case of an error.


scols_symbols_set_title_padding ()

int
scols_symbols_set_title_padding (struct libscols_symbols *sy,
                                 const char *str);

The current implementation uses only the first byte from the padding string. A multibyte chars are not supported yet.

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent the symbols which fill title output

 

Returns

0, a negative value in case of an error.

Since: 2.28


scols_symbols_set_cell_padding ()

int
scols_symbols_set_cell_padding (struct libscols_symbols *sy,
                                const char *str);

The padding char has to take up just one cell on the terminal.

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent the symbols which fill cells

 

Returns

0, a negative value in case of an error.

Since: 2.29


scols_symbols_set_group_vertical ()

int
scols_symbols_set_group_vertical (struct libscols_symbols *sy,
                                  const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent the vertival line

 

Returns

0, a negative value in case of an error.

Since: 2.34


scols_symbols_set_group_horizontal ()

int
scols_symbols_set_group_horizontal (struct libscols_symbols *sy,
                                    const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent the horizontal line

 

Returns

0, a negative value in case of an error.

Since: 2.34


scols_symbols_set_group_first_member ()

int
scols_symbols_set_group_first_member (struct libscols_symbols *sy,
                                      const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent first member

 

Returns

0, a negative value in case of an error.

Since: 2.34


scols_symbols_set_group_last_member ()

int
scols_symbols_set_group_last_member (struct libscols_symbols *sy,
                                     const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent last member

 

Returns

0, a negative value in case of an error.

Since: 2.34


scols_symbols_set_group_middle_member ()

int
scols_symbols_set_group_middle_member (struct libscols_symbols *sy,
                                       const char *str);

scols_symbols_set_group_last_child ()

int
scols_symbols_set_group_last_child (struct libscols_symbols *sy,
                                    const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent last child

 

Returns

0, a negative value in case of an error.

Since: 2.34


scols_symbols_set_group_middle_child ()

int
scols_symbols_set_group_middle_child (struct libscols_symbols *sy,
                                      const char *str);

Parameters

sy

a pointer to a struct libscols_symbols instance

 

str

a string which will represent last child

 

Returns

0, a negative value in case of an error.

Since: 2.34


scols_unref_symbols ()

void
scols_unref_symbols (struct libscols_symbols *sy);

Decreases the refcount of sy .

Parameters

sy

a pointer to a struct libscols_symbols instance

 

Types and Values

struct libscols_symbols

struct libscols_symbols;

Symbol groups for printing tree hierarchies