151 if (ev_w->
win != win_msg)
Color and attribute parsing.
ColorId
List of all colored objects.
@ MT_COLOR_NORMAL
Plain text.
#define mutt_debug(LEVEL,...)
static int msgwin_window_observer(struct NotifyCallback *nc)
Notification that a Window has changed - Implements observer_t -.
static int msgwin_recalc(struct MuttWindow *win)
Recalculate the display of the Message Window - Implements MuttWindow::recalc() -.
static int msgwin_repaint(struct MuttWindow *win)
Redraw the Message Window - Implements MuttWindow::repaint() -.
static void msgwin_wdata_free(struct MuttWindow *win, void **ptr)
Free the private data attached to the Message Window - Implements MuttWindow::wdata_free() -.
@ LL_DEBUG5
Log at debug level 5.
@ LL_NOTIFY
Log of notifications.
void * mutt_mem_calloc(size_t nmemb, size_t size)
Allocate zeroed memory on the heap.
void msgwin_set_text(enum ColorId cid, const char *text)
Set the text for the Message Window.
void msgwin_set_height(short height)
Resize the Message Window.
const char * msgwin_get_text(void)
Get the text from the Message Window.
static struct MuttWindow * MessageWindow
Message Window for messages, warnings, errors etc.
static struct MsgWinPrivateData * msgwin_wdata_new(void)
Create new private data for the Message Window.
size_t msgwin_get_width(void)
Get the width of the Message Window.
struct MuttWindow * msgwin_get_window(void)
Get the Message Window pointer.
struct MuttWindow * msgwin_new(void)
Create the Message Window.
void msgwin_clear_text(void)
Clear the text in the Message Window.
Convenience wrapper for the library headers.
bool notify_observer_remove(struct Notify *notify, const observer_t callback, const void *global_data)
Remove an observer from an object.
bool notify_observer_add(struct Notify *notify, enum NotifyType type, observer_t callback, void *global_data)
Add an observer to an object.
char * mutt_str_replace(char **p, const char *s)
Replace one string with another.
struct AttrColor * mutt_curses_set_normal_backed_color_by_id(enum ColorId cid)
Set the colour and attributes by the colour id.
struct AttrColor * mutt_curses_set_color_by_id(enum ColorId cid)
Set the colour and attributes by the colour id.
Define wrapper functions around Curses.
void mutt_window_reflow(struct MuttWindow *win)
Resize a Window and its children.
bool window_is_focused(const struct MuttWindow *win)
Does the given Window have the focus?
struct MuttWindow * mutt_window_new(enum WindowType type, enum MuttWindowOrientation orient, enum MuttWindowSize size, int cols, int rows)
Create a new Window.
int mutt_window_move(struct MuttWindow *win, int col, int row)
Move the cursor in a Window.
int mutt_window_addstr(struct MuttWindow *win, const char *str)
Write a string to a Window.
void mutt_window_clrtoeol(struct MuttWindow *win)
Clear to the end of the line.
#define WA_RECALC
Recalculate the contents of the Window.
@ WT_MESSAGE
Window for messages/errors and command entry.
@ MUTT_WIN_ORIENT_VERTICAL
Window uses all available vertical space.
@ NT_WINDOW_STATE
Window state has changed, e.g. WN_VISIBLE.
@ NT_WINDOW_DELETE
Window is about to be deleted.
#define WA_REPAINT
Redraw the contents of the Window.
#define MUTT_WIN_SIZE_UNLIMITED
Use as much space as possible.
@ MUTT_WIN_SIZE_FIXED
Window has a fixed size.
@ NT_WINDOW
MuttWindow has changed, NotifyWindow, EventWindow.
An Event that happened to a Window.
struct MuttWindow * win
Window that changed.
Private data for the Message Window.
char * text
Cached display string.
enum ColorId cid
Colour for the text, e.g. MT_COLOR_MESSAGE.
int(* repaint)(struct MuttWindow *win)
struct WindowState state
Current state of the Window.
void * wdata
Private data.
struct Notify * notify
Notifications: NotifyWindow, EventWindow.
short req_rows
Number of rows required.
int(* recalc)(struct MuttWindow *win)
void(* wdata_free)(struct MuttWindow *win, void **ptr)
struct MuttWindow * parent
Parent Window.
WindowActionFlags actions
Actions to be performed, e.g. WA_RECALC.
Data passed to a notification function.
void * event_data
Data from notify_send()
enum NotifyType event_type
Send: Event type, e.g. NT_ACCOUNT.
int event_subtype
Send: Event subtype, e.g. NT_ACCOUNT_ADD.
void * global_data
Data from notify_observer_add()
short cols
Number of columns, can be MUTT_WIN_SIZE_UNLIMITED.