NeoMutt  2022-04-29-247-gc6aae8
Teaching an old dog new tricks
DOXYGEN
Message Window

The Message Window is a one-line interactive window at the bottom of the screen.

It's used for asking the user questions, displaying messages and for a progress bar.

Behaviour

The Message Window has two modes of behaviour: passive, active.

Passive

Most of the time, the Message Window will be passively displaying messages to the user (or empty). This is characterised by the Window focus being somewhere else. In this mode, the Message Window is responsible for drawing itself.

See also
mutt_message(), mutt_error()

Active

The Message Window can be hijacked by other code to be used for user interaction, commonly for simple questions, "Are you sure? [Y/n]". In this active state the Window will have focus and it's the responsibility of the hijacker to perform the drawing.

See also
mutt_yesorno(), Progress Bar

Windows

Name Type Constructor
Message Window WT_MESSAGE msgwin_new()

Parent

Children

  • None

Data

The Message Window caches the formatted string.

Events

Once constructed, it is controlled by the following events:

Event Type Handler
NT_WINDOW msgwin_window_observer()
MuttWindow::recalc() msgwin_recalc()
MuttWindow::repaint() msgwin_repaint()

Functions

Function Description Links
msgwin_clear_text() Clear the text in the Message Window
msgwin_get_text() Get the text from the Message Window
msgwin_get_width() Get the width of the Message Window
msgwin_get_window() Get the Message Window pointer
msgwin_new() Create the Message Window
msgwin_recalc() Recalculate the display of the Message Window MuttWindow::recalc(), window_recalc
msgwin_repaint() Redraw the Message Window MuttWindow::repaint(), window_repaint
msgwin_set_height() Resize the Message Window
msgwin_set_text() Set the text for the Message Window
msgwin_wdata_free() Free the private data attached to the Message Window MuttWindow::wdata_free(), window_wdata_free
msgwin_wdata_new() Create new private data for the Message Window
msgwin_window_observer() Notification that a Window has changed observer_t, observer_api