Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
util.c File Reference
#include <stdarg.h>
#include "dialog.h"

Go to the source code of this file.

Macros

#define DLG_COLOR(dialog, f, b, h)
 

Functions

void attr_clear (WINDOW *win, int height, int width, chtype attr)
 
void dialog_clear (void)
 
int init_dialog (const char *backtitle)
 
void set_dialog_backtitle (const char *backtitle)
 
void end_dialog (int x, int y)
 
void print_title (WINDOW *dialog, const char *title, int width)
 
void print_autowrap (WINDOW *win, const char *prompt, int width, int y, int x)
 
void print_button (WINDOW *win, const char *label, int y, int x, int selected)
 
void draw_box (WINDOW *win, int y, int x, int height, int width, chtype box, chtype border)
 
void draw_shadow (WINDOW *win, int y, int x, int height, int width)
 
int first_alpha (const char *string, const char *exempt)
 
int on_key_esc (WINDOW *win)
 
int on_key_resize (void)
 
void item_reset (void)
 
void item_make (const char *fmt,...)
 
void item_add_str (const char *fmt,...)
 
void item_set_tag (char tag)
 
void item_set_data (void *ptr)
 
void item_set_selected (int val)
 
int item_activate_selected (void)
 
voiditem_data (void)
 
char item_tag (void)
 
int item_count (void)
 
void item_set (int n)
 
int item_n (void)
 
const charitem_str (void)
 
int item_is_selected (void)
 
int item_is_tag (char tag)
 

Variables

int saved_x
 
int saved_y
 
struct dialog_info dlg
 
struct dialog_listitem_cur
 
struct dialog_list item_nil
 
struct dialog_listitem_head
 

Macro Definition Documentation

#define DLG_COLOR (   dialog,
  f,
  b,
  h 
)
Value:
do { \
dlg.dialog.fg = (f); \
dlg.dialog.bg = (b); \
dlg.dialog.hl = (h); \
} while (0)

Definition at line 64 of file util.c.

Function Documentation

void attr_clear ( WINDOW win,
int  height,
int  width,
chtype  attr 
)

Definition at line 242 of file util.c.

void dialog_clear ( void  )

Definition at line 255 of file util.c.

void draw_box ( WINDOW win,
int  y,
int  x,
int  height,
int  width,
chtype  box,
chtype  border 
)

Definition at line 428 of file util.c.

void draw_shadow ( WINDOW win,
int  y,
int  x,
int  height,
int  width 
)

Definition at line 462 of file util.c.

void end_dialog ( int  x,
int  y 
)

Definition at line 308 of file util.c.

int first_alpha ( const char string,
const char exempt 
)

Definition at line 483 of file util.c.

int init_dialog ( const char backtitle)

Definition at line 274 of file util.c.

int item_activate_selected ( void  )

Definition at line 602 of file util.c.

void item_add_str ( const char fmt,
  ... 
)

Definition at line 574 of file util.c.

int item_count ( void  )

Definition at line 620 of file util.c.

void* item_data ( void  )

Definition at line 610 of file util.c.

int item_is_selected ( void  )

Definition at line 656 of file util.c.

int item_is_tag ( char  tag)

Definition at line 661 of file util.c.

void item_make ( const char fmt,
  ... 
)

Definition at line 557 of file util.c.

int item_n ( void  )

Definition at line 638 of file util.c.

void item_reset ( void  )

Definition at line 545 of file util.c.

void item_set ( int  n)

Definition at line 630 of file util.c.

void item_set_data ( void ptr)

Definition at line 592 of file util.c.

void item_set_selected ( int  val)

Definition at line 597 of file util.c.

void item_set_tag ( char  tag)

Definition at line 588 of file util.c.

const char* item_str ( void  )

Definition at line 651 of file util.c.

char item_tag ( void  )

Definition at line 615 of file util.c.

int on_key_esc ( WINDOW win)

Definition at line 511 of file util.c.

int on_key_resize ( void  )

Definition at line 535 of file util.c.

void print_autowrap ( WINDOW win,
const char prompt,
int  width,
int  y,
int  x 
)

Definition at line 336 of file util.c.

void print_button ( WINDOW win,
const char label,
int  y,
int  x,
int  selected 
)

Definition at line 398 of file util.c.

void print_title ( WINDOW dialog,
const char title,
int  width 
)

Definition at line 319 of file util.c.

void set_dialog_backtitle ( const char backtitle)

Definition at line 300 of file util.c.

Variable Documentation

Definition at line 29 of file util.c.

struct dialog_list* item_cur

Definition at line 541 of file util.c.

Definition at line 543 of file util.c.

struct dialog_list item_nil

Definition at line 542 of file util.c.

int saved_x

Definition at line 27 of file util.c.

int saved_y

Definition at line 27 of file util.c.