Change the Menu's position/selection. More...
#include "config.h"
#include <stdbool.h>
#include <stddef.h>
#include "mutt/lib.h"
#include "config/lib.h"
#include "gui/lib.h"
#include "lib.h"
Go to the source code of this file.
Functions | |
MenuRedrawFlags | menu_set_and_notify (struct Menu *menu, int top, int index) |
Set the Menu selection/view and notify others. | |
static int | menu_drag_view (struct Menu *menu, int top, int index) |
Move the view around the selection. | |
static int | calc_fit_selection_to_view (struct Menu *menu, int top, int index) |
Move the selection into the view. | |
static int | calc_move_view (struct Menu *menu, int relative) |
Move the view. | |
MenuRedrawFlags | menu_move_selection (struct Menu *menu, int index) |
Move the selection, keeping within between [0, menu->max]. | |
MenuRedrawFlags | menu_move_view_relative (struct Menu *menu, int relative) |
Move the view relatively. | |
void | menu_adjust (struct Menu *menu) |
Reapply the config to the Menu. | |
MenuRedrawFlags | menu_top_page (struct Menu *menu) |
Move the focus to the top of the page. | |
MenuRedrawFlags | menu_middle_page (struct Menu *menu) |
Move the focus to the centre of the page. | |
MenuRedrawFlags | menu_bottom_page (struct Menu *menu) |
Move the focus to the bottom of the page. | |
MenuRedrawFlags | menu_prev_entry (struct Menu *menu) |
Move the focus to the previous item in the menu. | |
MenuRedrawFlags | menu_next_entry (struct Menu *menu) |
Move the focus to the next item in the menu. | |
MenuRedrawFlags | menu_first_entry (struct Menu *menu) |
Move the focus to the first entry in the menu. | |
MenuRedrawFlags | menu_last_entry (struct Menu *menu) |
Move the focus to the last entry in the menu. | |
MenuRedrawFlags | menu_current_top (struct Menu *menu) |
Move the current selection to the top of the window. | |
MenuRedrawFlags | menu_current_middle (struct Menu *menu) |
Move the current selection to the centre of the window. | |
MenuRedrawFlags | menu_current_bottom (struct Menu *menu) |
Move the current selection to the bottom of the window. | |
MenuRedrawFlags | menu_half_up (struct Menu *menu) |
Move the focus up half a page in the menu. | |
MenuRedrawFlags | menu_half_down (struct Menu *menu) |
Move the focus down half a page in the menu. | |
MenuRedrawFlags | menu_prev_line (struct Menu *menu) |
Move the view up one line, keeping the selection the same. | |
MenuRedrawFlags | menu_next_line (struct Menu *menu) |
Move the view down one line, keeping the selection the same. | |
MenuRedrawFlags | menu_prev_page (struct Menu *menu) |
Move the focus to the previous page in the menu. | |
MenuRedrawFlags | menu_next_page (struct Menu *menu) |
Move the focus to the next page in the menu. | |
Change the Menu's position/selection.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file move.c.
MenuRedrawFlags menu_set_and_notify | ( | struct Menu * | menu, |
int | top, | ||
int | index | ||
) |
Set the Menu selection/view and notify others.
menu | Menu |
top | Index of item at the top of the view |
index | Selected item |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 66 of file move.c.
|
static |
Move the view around the selection.
menu | Menu |
top | Index of item at the top of the view |
index | Current selection |
num | Top line |
Definition at line 111 of file move.c.
|
static |
Move the selection into the view.
menu | Menu |
top | First entry visible in the view |
index | Current selection |
num | Index |
Definition at line 164 of file move.c.
|
static |
Move the view.
menu | Menu |
relative | Relative number of lines to move |
num | Top line |
0 | Error |
Definition at line 194 of file move.c.
MenuRedrawFlags menu_move_selection | ( | struct Menu * | menu, |
int | index | ||
) |
Move the selection, keeping within between [0, menu->max].
menu | Menu |
index | New selection |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 236 of file move.c.
MenuRedrawFlags menu_move_view_relative | ( | struct Menu * | menu, |
int | relative | ||
) |
Move the view relatively.
menu | Menu |
relative | Relative number of lines to move |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 254 of file move.c.
void menu_adjust | ( | struct Menu * | menu | ) |
Reapply the config to the Menu.
menu | Menu |
Definition at line 319 of file move.c.
MenuRedrawFlags menu_top_page | ( | struct Menu * | menu | ) |
Move the focus to the top of the page.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 333 of file move.c.
MenuRedrawFlags menu_middle_page | ( | struct Menu * | menu | ) |
Move the focus to the centre of the page.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 343 of file move.c.
MenuRedrawFlags menu_bottom_page | ( | struct Menu * | menu | ) |
Move the focus to the bottom of the page.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 363 of file move.c.
MenuRedrawFlags menu_prev_entry | ( | struct Menu * | menu | ) |
Move the focus to the previous item in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 382 of file move.c.
MenuRedrawFlags menu_next_entry | ( | struct Menu * | menu | ) |
Move the focus to the next item in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 396 of file move.c.
MenuRedrawFlags menu_first_entry | ( | struct Menu * | menu | ) |
Move the focus to the first entry in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 410 of file move.c.
MenuRedrawFlags menu_last_entry | ( | struct Menu * | menu | ) |
Move the focus to the last entry in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 426 of file move.c.
MenuRedrawFlags menu_current_top | ( | struct Menu * | menu | ) |
Move the current selection to the top of the window.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 443 of file move.c.
MenuRedrawFlags menu_current_middle | ( | struct Menu * | menu | ) |
Move the current selection to the centre of the window.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 464 of file move.c.
MenuRedrawFlags menu_current_bottom | ( | struct Menu * | menu | ) |
Move the current selection to the bottom of the window.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 484 of file move.c.
MenuRedrawFlags menu_half_up | ( | struct Menu * | menu | ) |
Move the focus up half a page in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 506 of file move.c.
MenuRedrawFlags menu_half_down | ( | struct Menu * | menu | ) |
Move the focus down half a page in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 516 of file move.c.
MenuRedrawFlags menu_prev_line | ( | struct Menu * | menu | ) |
Move the view up one line, keeping the selection the same.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 526 of file move.c.
MenuRedrawFlags menu_next_line | ( | struct Menu * | menu | ) |
Move the view down one line, keeping the selection the same.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 539 of file move.c.
MenuRedrawFlags menu_prev_page | ( | struct Menu * | menu | ) |
Move the focus to the previous page in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 552 of file move.c.
MenuRedrawFlags menu_next_page | ( | struct Menu * | menu | ) |
Move the focus to the next page in the menu.
menu | Current Menu |
enum | MenuRedrawFlags, e.g. MENU_REDRAW_CURRENT |
Definition at line 562 of file move.c.