|
rofi 2.1.0
|
#include <config.h>#include <errno.h>#include <locale.h>#include <signal.h>#include <stdint.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include <time.h>#include <unistd.h>#include <cairo.h>#include "rofi.h"#include "settings.h"#include "timings.h"#include "display.h"#include "helper-theme.h"#include "helper.h"#include "mode.h"#include "modes/modes.h"#include "view-internal.h"#include "view.h"#include "theme.h"
Go to the source code of this file.
Macros | |
| #define | G_LOG_DOMAIN "View" |
Variables | ||
| struct { | ||
| MenuFlags flags | ||
| guint idle_timeout | ||
| unsigned long long count | ||
| guint repaint_source | ||
| gboolean fullscreen | ||
| int monitor_width | ||
| int monitor_height | ||
| int surface_width | ||
| int surface_height | ||
| int menu_width | ||
| int menu_height | ||
| int menu_x | ||
| int menu_y | ||
| } | WlState | |
| static const int | loc_transtable [9] | |
| static view_proxy | view_ | |
| const view_proxy * | wayland_view_proxy = &view_ | |
| void process_result | ( | RofiViewState * | state | ) |
| state | The Menu Handle |
Check if a finalize function is set, and if sets executes it.
Load in the new mode.
Definition at line 235 of file rofi.c.
References curr_mode, MODE_EXIT, mode_result(), modes, NEXT_DIALOG, num_modes, PREVIOUS_DIALOG, RELOAD_DIALOG, RESET_DIALOG, rofi_view_clear_input(), rofi_view_free(), rofi_view_get_return_value(), rofi_view_get_selected_line(), rofi_view_get_user_input(), rofi_view_remove_active(), rofi_view_switch_mode(), RofiViewState::sw, RofiViewState::text, textbox_cursor_end(), and textbox_text().
Referenced by rofi_view_error_dialog(), and run_mode_index().


|
static |
Definition at line 149 of file view.c.
References config, loc_transtable, RofiViewState::main_window, rofi_theme_get_position(), and WIDGET.
Referenced by window_update_size_normal(), and window_update_size_with_outside_click().


|
static |
Definition at line 154 of file view.c.
References distance_get_pixel(), RofiViewState::main_window, ROFI_ORIENTATION_HORIZONTAL, rofi_theme_get_distance(), and WIDGET.
Referenced by wayland_rofi_view_window_update_size().


|
static |
Definition at line 326 of file view.c.
References box_create(), config, display_set_fullscreen_mode(), helper_validate_font(), input_history_initialize(), ROFI_ORIENTATION_HORIZONTAL, rofi_theme_get_boolean(), rofi_theme_get_string(), textbox_set_pango_context(), TICK_N, wayland_get_dpi_estimation(), WIDGET, widget_free(), and WlState.

|
static |
Definition at line 481 of file view.c.
References display_get_surface_dimensions(), distance_get_pixel(), RofiViewState::main_window, ROFI_ORIENTATION_VERTICAL, rofi_theme_get_distance(), WIDGET, widget_get_desired_height(), RofiViewState::width, and WlState.

|
static |
|
static |
| state | Internal state of the menu. |
Calculate the width of the window and the width of an element.
Definition at line 399 of file view.c.
References DEFAULT_MENU_WIDTH, display_get_surface_dimensions(), distance_get_pixel(), RofiViewState::main_window, ROFI_ORIENTATION_HORIZONTAL, rofi_theme_get_distance(), WIDGET, RofiViewState::width, and WlState.

|
static |
Definition at line 503 of file view.c.
References CacheState, input_history_save(), and WlState.

|
static |
Definition at line 474 of file view.c.
References wayland_rofi_view_repaint(), and WlState.

|
static |
Definition at line 114 of file view.c.
References display_get_surface_dimensions(), and WlState.
Referenced by window_update_size_with_outside_click().


|
static |
|
static |
Definition at line 276 of file view.c.
References RofiViewState::height, and RofiViewState::width.
|
static |
Definition at line 501 of file view.c.
References display_early_cleanup().

|
static |
|
static |
Definition at line 532 of file view.c.
References display_buffer_pool_free(), rofi_view_get_active(), and wayland_rofi_view_update().

|
static |
Definition at line 313 of file view.c.
References RofiViewState::main_window, rofi_view_get_active(), wayland_rofi_view_repaint(), WIDGET, widget_queue_redraw(), and WlState.
Referenced by wayland_rofi_view_update().


|
static |
Definition at line 306 of file view.c.
References wayland_rofi_view_reload_idle(), and WlState.

|
static |
Definition at line 284 of file view.c.
References mode_get_num_entries(), RofiViewState::refilter, RofiViewState::reload, rofi_view_get_active(), rofi_view_maybe_update(), RofiViewState::sw, RofiViewState::tb_total_rows, textbox_text(), and WlState.
Referenced by wayland_rofi_view_reload().


|
static |
Definition at line 129 of file view.c.
References rofi_view_get_active(), rofi_view_maybe_update(), and WlState.
Referenced by wayland_rofi_view_frame_callback(), and wayland_rofi_view_queue_redraw().


|
static |
Definition at line 265 of file view.c.
References RofiViewState::height, wayland_rofi_view_window_update_size(), and RofiViewState::width.

|
static |
|
static |
| state | The handle to the view |
| qr | Indicate if queue_redraw should be called on changes. |
Update the state of the view. This involves filter state.
Definition at line 416 of file view.c.
References config, display_buffer_pool_get_next_buffer(), display_buffer_pool_new(), display_scale(), display_surface_commit(), RofiViewState::height, RofiViewState::main_window, TICK, TICK_N, wayland_rofi_view_queue_redraw(), WIDGET, widget_draw(), widget_need_redraw(), RofiViewState::width, and WlState.
Referenced by wayland_rofi_view_pool_refresh().


|
static |
Definition at line 244 of file view.c.
References config, RofiViewState::height, RofiViewState::main_window, rofi_get_offset_px(), ROFI_ORIENTATION_HORIZONTAL, ROFI_ORIENTATION_VERTICAL, rofi_view_pool_refresh(), WIDGET, widget_resize(), RofiViewState::width, window_update_size_normal(), window_update_size_with_outside_click(), and WlState.
Referenced by wayland_rofi_view_set_size().


|
static |
Definition at line 162 of file view.c.
References display_set_surface_dimensions(), RofiViewState::height, rofi_get_location(), RofiViewState::width, and WlState.
Referenced by wayland_rofi_view_window_update_size().


|
static |
Definition at line 173 of file view.c.
References display_set_surface_dimensions(), RofiViewState::height, rofi_get_location(), wayland_rofi_view_get_current_monitor(), RofiViewState::width, WL_CENTER, WL_EAST, WL_NORTH, WL_NORTH_EAST, WL_NORTH_WEST, WL_SOUTH, WL_SOUTH_EAST, WL_SOUTH_WEST, WL_WEST, and WlState.
Referenced by wayland_rofi_view_window_update_size().


| unsigned long long count |
debug counter for redraws
Definition at line 77 of file view.c.
Referenced by config_parse_cmd_options(), config_parser_form_rasi_format(), helper_token_match_get_pango_attr(), rofi_view_refilter_real(), wayland_buffer_cleanup(), and window_set_atom_prop().
| MenuFlags flags |
Main flags
Definition at line 73 of file view.c.
Referenced by create_pid_file(), textbox_create(), wayland_output_mode(), and x11_disable_decoration().
|
static |
Definition at line 141 of file view.c.
Referenced by rofi_get_location(), and xcb_rofi_view_calculate_window_position().
| int menu_x |
Definition at line 92 of file view.c.
Referenced by update_cursor_rectangle(), and wayland_pointer_send_events().
| int menu_y |
Definition at line 93 of file view.c.
Referenced by update_cursor_rectangle(), and wayland_pointer_send_events().
|
static |
| const view_proxy* wayland_view_proxy = &view_ |
Definition at line 584 of file view.c.
Referenced by wayland_display_view_proxy().
| struct { ... } WlState |
Structure holding some state
Referenced by wayland___create_window(), wayland_rofi_view_calculate_window_height(), wayland_rofi_view_calculate_window_width(), wayland_rofi_view_cleanup(), wayland_rofi_view_frame_callback(), wayland_rofi_view_get_current_monitor(), wayland_rofi_view_get_menu_rect(), wayland_rofi_view_queue_redraw(), wayland_rofi_view_reload(), wayland_rofi_view_reload_idle(), wayland_rofi_view_repaint(), wayland_rofi_view_update(), wayland_rofi_view_window_update_size(), window_update_size_normal(), and window_update_size_with_outside_click().