w3m

Unnamed repository; edit this file to name it for gitweb.
git clone https://logand.com/git/w3m.git/
Log | Files | Refs | README

menu.h (850B)


      1 /* $Id$ */
      2 /*
      3  * w3m menu.h
      4  */
      5 
      6 #ifndef MENU_H
      7 #define MENU_H
      8 
      9 #define MENU_END    0
     10 #define MENU_NOP    1
     11 #define MENU_VALUE  2
     12 #define MENU_FUNC   4
     13 #define MENU_POPUP  8
     14 
     15 #define MENU_NOTHING -1
     16 #define MENU_CANCEL  -2
     17 #define MENU_CLOSE   -3
     18 
     19 typedef struct _MenuItem {
     20     int type;
     21     char *label;
     22     int *variable;
     23     int value;
     24     void (*func) ();
     25     struct _Menu *popup;
     26     char *keys;
     27     char *data;
     28 } MenuItem;
     29 
     30 typedef struct _Menu {
     31     struct _Menu *parent;
     32     int cursorX;
     33     int cursorY;
     34     int x;
     35     int y;
     36     int width;
     37     int height;
     38     int nitem;
     39     MenuItem *item;
     40     int initial;
     41     int select;
     42     int offset;
     43     int active;
     44     int (*keymap[128]) (char c);
     45     int keyselect[128];
     46 } Menu;
     47 
     48 typedef struct _MenuList {
     49     char *id;
     50     Menu *menu;
     51     MenuItem *item;
     52 } MenuList;
     53 
     54 #endif				/* not MENU_H */