NeoMutt  2020-11-20
Teaching an old dog new tricks
DOXYGEN
Menu Struct Reference

GUI selectable list of items. More...

#include "mutt_menu.h"

+ Collaboration diagram for Menu:

Public Member Functions

 ARRAY_HEAD (, char *) dialog
 Dialog lines themselves. More...
 

Data Fields

const char * title
 Title of this menu. More...
 
void * mdata
 Extra data for the current menu. More...
 
int current
 Current entry. More...
 
int max
 Number of entries in the menu. More...
 
MuttRedrawFlags redraw
 When to redraw the screen. More...
 
enum MenuType type
 Menu definition for keymap entries. More...
 
int pagelen
 Number of entries per screen. More...
 
bool tagprefix: 1
 
bool is_mailbox_list: 1
 
struct MuttWindowwin_index
 
struct MuttWindowwin_ibar
 
char * prompt
 Prompt for user, similar to mutt_multi_choice. More...
 
char * keys
 Keys used in the prompt. More...
 
int top
 Entry that is the top of the current page. More...
 
int oldcurrent
 For driver use only. More...
 
int search_dir
 Direction of search. More...
 
int tagged
 Number of tagged entries. More...
 
bool custom_search: 1
 The menu implements its own non-Menusearch()-compatible search, trickle OP_SEARCH*. More...
 
void(* make_entry )(char *buf, size_t buflen, struct Menu *menu, int line)
 Format a item for a menu. More...
 
int(* search )(struct Menu *menu, regex_t *rx, int line)
 Search a menu for a item matching a regex. More...
 
int(* tag )(struct Menu *menu, int sel, int act)
 Tag some menu items. More...
 
int(* color )(int line)
 Calculate the colour for a line of the menu. More...
 
void(* custom_redraw )(struct Menu *menu)
 Redraw the menu. More...
 
void * redraw_data
 

Detailed Description

GUI selectable list of items.

Definition at line 52 of file mutt_menu.h.

Member Function Documentation

◆ ARRAY_HEAD()

Menu::ARRAY_HEAD ( char *  )

Dialog lines themselves.

Field Documentation

◆ title

const char* Menu::title

Title of this menu.

Definition at line 54 of file mutt_menu.h.

◆ mdata

void* Menu::mdata

Extra data for the current menu.

Definition at line 55 of file mutt_menu.h.

◆ current

int Menu::current

Current entry.

Definition at line 56 of file mutt_menu.h.

◆ max

int Menu::max

Number of entries in the menu.

Definition at line 57 of file mutt_menu.h.

◆ redraw

MuttRedrawFlags Menu::redraw

When to redraw the screen.

Definition at line 58 of file mutt_menu.h.

◆ type

enum MenuType Menu::type

Menu definition for keymap entries.

Definition at line 59 of file mutt_menu.h.

◆ pagelen

int Menu::pagelen

Number of entries per screen.

Definition at line 60 of file mutt_menu.h.

◆ tagprefix

bool Menu::tagprefix

Definition at line 61 of file mutt_menu.h.

◆ is_mailbox_list

bool Menu::is_mailbox_list

Definition at line 62 of file mutt_menu.h.

◆ win_index

struct MuttWindow* Menu::win_index

Definition at line 63 of file mutt_menu.h.

◆ win_ibar

struct MuttWindow* Menu::win_ibar

Definition at line 64 of file mutt_menu.h.

◆ prompt

char* Menu::prompt

Prompt for user, similar to mutt_multi_choice.

Definition at line 71 of file mutt_menu.h.

◆ keys

char* Menu::keys

Keys used in the prompt.

Definition at line 72 of file mutt_menu.h.

◆ top

int Menu::top

Entry that is the top of the current page.

Definition at line 75 of file mutt_menu.h.

◆ oldcurrent

int Menu::oldcurrent

For driver use only.

Definition at line 76 of file mutt_menu.h.

◆ search_dir

int Menu::search_dir

Direction of search.

Definition at line 77 of file mutt_menu.h.

◆ tagged

int Menu::tagged

Number of tagged entries.

Definition at line 78 of file mutt_menu.h.

◆ custom_search

bool Menu::custom_search

The menu implements its own non-Menusearch()-compatible search, trickle OP_SEARCH*.

Definition at line 79 of file mutt_menu.h.

◆ make_entry

void(* Menu::make_entry) (char *buf, size_t buflen, struct Menu *menu, int line)

Format a item for a menu.

Parameters
[out]bufBuffer in which to save string
[in]buflenBuffer length
[in]menuMenu containing items
[in]lineMenu line number

Definition at line 88 of file mutt_menu.h.

◆ search

int(* Menu::search) (struct Menu *menu, regex_t *rx, int line)

Search a menu for a item matching a regex.

Parameters
menuMenu to search
rxRegex to match
lineMenu entry to match
Return values
0Success
>0Error, e.g. REG_NOMATCH

Definition at line 98 of file mutt_menu.h.

◆ tag

int(* Menu::tag) (struct Menu *menu, int sel, int act)

Tag some menu items.

Parameters
menuMenu to tag
selCurrent selection
actAction: 0 untag, 1 tag, -1 toggle
Return values
numNet change in number of tagged attachments

Definition at line 107 of file mutt_menu.h.

◆ color

int(* Menu::color) (int line)

Calculate the colour for a line of the menu.

Parameters
lineMenu line number
Return values
>0Colour pair in an integer
0No colour

Definition at line 115 of file mutt_menu.h.

◆ custom_redraw

void(* Menu::custom_redraw) (struct Menu *menu)

Redraw the menu.

Parameters
menuMenu to redraw

Definition at line 121 of file mutt_menu.h.

◆ redraw_data

void* Menu::redraw_data

Definition at line 123 of file mutt_menu.h.


The documentation for this struct was generated from the following file: