source: tags/arb-6.0/ARB_GDE/GDE_menu.h

Last change on this file was 11886, checked in by westram, 10 years ago
  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.3 KB
Line 
1// =============================================================== //
2//                                                                 //
3//   File      : GDE_menu.h                                        //
4//   Purpose   :                                                   //
5//                                                                 //
6// =============================================================== //
7
8#ifndef GDE_MENU_H
9#define GDE_MENU_H
10
11#ifndef GDE_HXX
12#include "gde.hxx"
13#endif
14#ifndef GDE_DEF_H
15#include "GDE_def.h"
16#endif
17
18struct GargChoice {
19    char *label;                // name for display in dialog box
20    char *method;               // value (if null, return choice number)
21};
22
23struct GmenuItemArg {
24    int         type;           // TEXT, SLIDER, CHOOSER, etc.
25    int         ivalue;
26    double      min;            // minimum range value
27    double      max;            // maximum range value
28    double      fvalue;         // default numeric value(or choice)
29    int         numchoices;     // number of choices
30    char       *textvalue;      // default text value
31    int         textwidth;      // text width used for input field
32    char       *label;          // description of arg function
33    char       *symbol;         // internal symbol table mapping
34    GargChoice *choice;         // choices
35    // ARB BEGIN
36    AW_active     active_mask;  // expert/novice
37};
38
39enum TypeInfo {
40    BASIC_TYPEINFO    = 0, // has to be zero (default value; initialized with calloc)
41    DETAILED_TYPEINFO = 1,
42    UNKNOWN_TYPEINFO  = 2,
43};
44
45struct GfileFormat {
46    int       save;             // how should file be saved
47    int       format;           // what format is each field
48    char     *symbol;           // internal symbol table mapping
49    char     *name;             // file name
50    TypeInfo  typeinfo;
51};
52
53class AW_window;
54
55struct GmenuItem {
56    int           numargs;        // number of agruments to cmnd
57    int           numoutputs;     // number of outputs from cmnd
58    int           numinputs;      // number of input files to cmnd
59    char         *label;          // item name
60    char         *method;         // commandline produced
61    GfileFormat  *input;          // input definitions
62    GfileFormat  *output;         // output definitions
63    GmenuItemArg *arg;            // argument definitions
64    char          meta;           // Meta character for function
65    char          seqtype;        // A -> amino, N -> nucleotide, '-' -> no sequence, otherwise both
66    char         *help;           // associated helpfile ("agde_*.hlp")
67    // ARB BEGIN
68    struct Gmenu *parent_menu;
69    AW_window    *aws;            // opened window
70    AW_active     active_mask;    // expert/novice
71};
72
73struct Gmenu {
74    int        numitems;        // number of items in menu
75    char      *label;           // menu heading
76    GmenuItem *item;            // menu items
77    // ARB BEGIN
78    char       meta;            // Meta character for menu
79    AW_active  active_mask;     // expert/novice
80};
81
82typedef unsigned char uchar;
83
84extern struct gde_database_access {
85    GDE_get_sequences_cb  get_sequences;
86    gde_window_type       window_type;
87    AW_CL                 client_data;
88    GBDATA               *gb_main;
89} db_access;
90
91
92#else
93#error GDE_menu.h included twice
94#endif // GDE_MENU_H
Note: See TracBrowser for help on using the repository browser.