FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
table.c File Reference
+ Include dependency graph for table.c:

Go to the source code of this file.

Functions

u8format_text_cell (table_t *t, u8 *s, table_cell_t *c, table_text_attr_t *def, int size)
 
u8format_table (u8 *s, va_list *args)
 
void table_format_title (table_t *t, char *fmt,...)
 
static table_cell_ttable_get_cell (table_t *t, int c, int r)
 
void table_format_cell (table_t *t, int c, int r, char *fmt,...)
 
void table_set_cell_align (table_t *t, int c, int r, table_text_attr_align_t a)
 
void table_set_cell_fg_color (table_t *t, int c, int r, table_text_attr_color_t v)
 
void table_set_cell_bg_color (table_t *t, int c, int r, table_text_attr_color_t v)
 
void table_free (table_t *t)
 
void table_add_header_col (table_t *t, int n_strings,...)
 
void table_add_header_row (table_t *t, int n_strings,...)
 

Variables

static table_text_attr_t default_title
 
static table_text_attr_t default_body
 
static table_text_attr_t default_header_col
 
static table_text_attr_t default_header_row
 

Function Documentation

◆ format_table()

u8* format_table ( u8 s,
va_list *  args 
)

Definition at line 121 of file table.c.

+ Here is the call graph for this function:

◆ format_text_cell()

u8* format_text_cell ( table_t t,
u8 s,
table_cell_t c,
table_text_attr_t def,
int  size 
)

Definition at line 50 of file table.c.

+ Here is the caller graph for this function:

◆ table_add_header_col()

void table_add_header_col ( table_t t,
int  n_strings,
  ... 
)

Definition at line 236 of file table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ table_add_header_row()

void table_add_header_row ( table_t t,
int  n_strings,
  ... 
)

Definition at line 258 of file table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ table_format_cell()

void table_format_cell ( table_t t,
int  c,
int  r,
char *  fmt,
  ... 
)

Definition at line 181 of file table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ table_format_title()

void table_format_title ( table_t t,
char *  fmt,
  ... 
)

Definition at line 158 of file table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ table_free()

void table_free ( table_t t)

Definition at line 221 of file table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ table_get_cell()

static table_cell_t* table_get_cell ( table_t t,
int  c,
int  r 
)
static

Definition at line 168 of file table.c.

+ Here is the caller graph for this function:

◆ table_set_cell_align()

void table_set_cell_align ( table_t t,
int  c,
int  r,
table_text_attr_align_t  a 
)

Definition at line 198 of file table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ table_set_cell_bg_color()

void table_set_cell_bg_color ( table_t t,
int  c,
int  r,
table_text_attr_color_t  v 
)

Definition at line 213 of file table.c.

+ Here is the call graph for this function:

◆ table_set_cell_fg_color()

void table_set_cell_fg_color ( table_t t,
int  c,
int  r,
table_text_attr_color_t  v 
)

Definition at line 205 of file table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ default_body

table_text_attr_t default_body
static
Initial value:
= {
.align = TTAA_RIGHT,
}

Definition at line 33 of file table.c.

◆ default_header_col

table_text_attr_t default_header_col
static
Initial value:
= {
.fg_color = TTAC_YELLOW,
.align = TTAA_CENTER,
}

Definition at line 37 of file table.c.

◆ default_header_row

table_text_attr_t default_header_row
static
Initial value:
= {
.fg_color = TTAC_GREEN,
.align = TTAA_LEFT,
}

Definition at line 43 of file table.c.

◆ default_title

table_text_attr_t default_title
static
Initial value:
= {
.fg_color = TTAC_YELLOW,
.align = TTAA_CENTER,
}

Definition at line 27 of file table.c.

TTAA_RIGHT
@ TTAA_RIGHT
Definition: table.h:55
TTAA_LEFT
@ TTAA_LEFT
Definition: table.h:54
TTAF_FG_COLOR_SET
@ TTAF_FG_COLOR_SET
Definition: table.h:33
TTAC_GREEN
@ TTAC_GREEN
Definition: table.h:43
TTAC_YELLOW
@ TTAC_YELLOW
Definition: table.h:44
TTAF_BOLD
@ TTAF_BOLD
Definition: table.h:30
TTAA_CENTER
@ TTAA_CENTER
Definition: table.h:56