rofi 1.7.9
ViewThreadPool
Collaboration diagram for ViewThreadPool:

Functions

void rofi_view_workers_initialize (void)
 
void rofi_view_workers_finalize (void)
 
void rofi_view_get_current_monitor (int *width, int *height)
 
void rofi_capture_screenshot (void)
 
void rofi_view_set_window_title (const char *title)
 
void rofi_view_ellipsize_listview (RofiViewState *state, PangoEllipsizeMode mode)
 
gboolean rofi_set_im_window_pos (int new_x, int new_y)
 
WidgetTriggerActionResult textbox_button_trigger_action (widget *wid, MouseBindingMouseDefaultAction action, G_GNUC_UNUSED gint x, G_GNUC_UNUSED gint y, G_GNUC_UNUSED void *user_data)
 

Detailed Description

The view can (optionally) keep a set of worker threads around to parallize work. This includes filtering and sorting.

Function Documentation

◆ rofi_capture_screenshot()

void rofi_capture_screenshot ( void )

Takes a screenshot.

Stores a screenshot of Rofi at that point in time.

Definition at line 233 of file view.c.

References color_green, color_reset, current_active_menu, RofiViewState::height, RofiViewState::main_window, screenshot_taken_user_callback(), WIDGET, widget_draw(), and RofiViewState::width.

Referenced by record(), rofi_view_trigger_global_action(), and take_screenshot_quit().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ rofi_set_im_window_pos()

gboolean rofi_set_im_window_pos ( int new_x,
int new_y )
Parameters
new_xNew XIM window x pos
new_yNew XIM window y pos

Updates the XIM window position to new_x and new_y, relative to the main_window

Referenced by rofi_view_update().

Here is the caller graph for this function:

◆ rofi_view_ellipsize_listview()

void rofi_view_ellipsize_listview ( RofiViewState * state,
PangoEllipsizeMode mode )
Parameters
stateThe window state handle
modeThe pango ellipsize mode to user set ellipsize mode to start.

Definition at line 2896 of file view.c.

References RofiViewState::list_view, and listview_set_ellipsize().

Referenced by dmenu_mode_dialog().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ rofi_view_get_current_monitor()

void rofi_view_get_current_monitor ( int * width,
int * height )
Parameters
widththe width of the monitor.
heightthe height of the monitor.

Return the current monitor workarea.

Definition at line 186 of file view.c.

References CacheState.

Referenced by get_pixels().

Here is the caller graph for this function:

◆ rofi_view_set_window_title()

void rofi_view_set_window_title ( const char * title)

Set the window title.

Definition at line 2931 of file view.c.

References CacheState, and xcb.

Referenced by __create_window(), rofi_view_create(), and rofi_view_switch_mode().

Here is the caller graph for this function:

◆ rofi_view_workers_finalize()

void rofi_view_workers_finalize ( void )

Stop all threads and free the resources used by the threadpool

Definition at line 2838 of file view.c.

References tpool.

Referenced by cleanup(), and page_changed_callback().

Here is the caller graph for this function:

◆ rofi_view_workers_initialize()

void rofi_view_workers_initialize ( void )

Initialize the threadpool

Definition at line 2809 of file view.c.

References config, rofi_thread_pool_state_free(), rofi_thread_workers_sort(), rofi_view_call_thread(), TICK_N, and tpool.

Referenced by main(), and page_changed_callback().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ textbox_button_trigger_action()

WidgetTriggerActionResult textbox_button_trigger_action ( widget * wid,
MouseBindingMouseDefaultAction action,
G_GNUC_UNUSED gint x,
G_GNUC_UNUSED gint y,
G_GNUC_UNUSED void * user_data )
Parameters
widto test.
actionthe action done.
x[unused]
y[unsued]
user_data

textbux widget trigger action function.

Returns
the result.

Definition at line 2273 of file view.c.

References key_binding_get_action_from_name(), RofiViewState::line_map, RofiViewState::list_view, listview_get_selected(), MOUSE_CLICK_DOWN, MOUSE_CLICK_UP, MOUSE_DCLICK_DOWN, MOUSE_DCLICK_UP, rofi_theme_get_string(), rofi_view_trigger_global_action(), RofiViewState::selected_line, RofiViewState::skip_absorb, WIDGET_TRIGGER_ACTION_RESULT_HANDLED, and WIDGET_TRIGGER_ACTION_RESULT_IGNORED.

Referenced by listview_add_widget(), and rofi_view_add_widget().

Here is the call graph for this function:
Here is the caller graph for this function: