• Kevin J. McCarthy's avatar
    Add window structures to use for screen layout. · 79728dfe
    Kevin J. McCarthy authored
    This is a series of 11 patches, centralizing Mutt screen drawing
    inside windows (mutt_window_t structures).
    Currently, the screen drawing and cursor positioning logic is
    distributed all over the code, resulting in many files having the same
    logic of where the help, status, message windows are.  Additionally,
    the code directly uses move and mvadd*/mvprint* functions, which means
    if the layouts are changed, the row/column computation logic needs to
    be changed all over the place.
    The patch creates a (very simple) mutt_window_t structure and
    functions for moving, addch/str/printw, along with clearing the line.
    The windows keep track of where they are on the screen, allowing the
    Mutt code to simply position elements relative to the window.
    During curses initalization, and when the window is resized, the
    window sizes and positions and recomputed.  Also, a new option flags,
    R_REFLOW is added for options that need to force a reflow when they are changed.
    Thanks to Richard Russon for pointing out the slang compilation issue.
resize.c 2.06 KB