rofi 2.0.0
display.h File Reference
#include "helper.h"
#include "nkutils-bindings.h"
#include <glib.h>
Include dependency graph for display.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  _workarea

Typedefs

typedef struct _workarea workarea
typedef void(* ClipboardCb) (char *clipboard_data, void *user_data)

Enumerations

enum  clipboard_type { CLIPBOARD_DEFAULT , CLIPBOARD_PRIMARY }

Functions

void display_init (const struct _display_proxy *disp_in)
int monitor_active (workarea *mon)
gboolean display_setup (GMainLoop *main_loop, NkBindings *bindings)
gboolean display_late_setup (void)
void display_early_cleanup (void)
void display_cleanup (void)
void display_dump_monitor_layout (void)
void display_startup_notification (RofiHelperExecuteContext *context, GSpawnChildSetupFunc *child_setup, gpointer *user_data)
void display_set_input_focus (guint w)
void display_revert_input_focus (void)
guint display_scale (void)
void display_get_clipboard_data (enum clipboard_type, ClipboardCb callback, void *user_data)
void display_set_fullscreen_mode (void)

Variables

struct _display_proxy *const xcb_proxy

Typedef Documentation

◆ ClipboardCb

typedef void(* ClipboardCb) (char *clipboard_data, void *user_data)

Definition at line 130 of file display.h.

◆ workarea

typedef struct _workarea workarea

Structure describing a workarea/monitor.

Enumeration Type Documentation

◆ clipboard_type

Enumerator
CLIPBOARD_DEFAULT 
CLIPBOARD_PRIMARY 

Definition at line 125 of file display.h.

Function Documentation

◆ display_cleanup()

void display_cleanup ( void )

Cleanup any remaining display related stuff

Definition at line 32 of file display.c.

References proxy.

Referenced by cleanup().

Here is the caller graph for this function:

◆ display_dump_monitor_layout()

void display_dump_monitor_layout ( void )

Dumps the display layout for -help output

Definition at line 34 of file display.c.

References proxy.

Referenced by help().

Here is the caller graph for this function:

◆ display_early_cleanup()

void display_early_cleanup ( void )

Do some early cleanup, like unmapping the surface

Definition at line 30 of file display.c.

References proxy.

Referenced by teardown(), wayland_rofi_view_hide(), and xcb_rofi_view_hide().

Here is the caller graph for this function:

◆ display_get_clipboard_data()

void display_get_clipboard_data ( enum clipboard_type,
ClipboardCb callback,
void * user_data )

Definition at line 44 of file display.c.

References proxy.

Referenced by rofi_view_trigger_global_action().

Here is the caller graph for this function:

◆ display_init()

void display_init ( const struct _display_proxy * disp_in)

References bindings, main_loop, and mon.

◆ display_late_setup()

gboolean display_late_setup ( void )

Do some late setup of the display backend

Returns
Whether the setup succeeded or not

Definition at line 28 of file display.c.

References proxy.

Referenced by main().

Here is the caller graph for this function:

◆ display_revert_input_focus()

void display_revert_input_focus ( void )

Definition at line 22 of file display.c.

References proxy.

Referenced by xcb_rofi_view_hide().

Here is the caller graph for this function:

◆ display_scale()

guint display_scale ( void )

Definition at line 42 of file display.c.

References proxy.

Referenced by _get_icon(), _get_icon(), _get_icon(), dmenu_get_icon(), main(), rofi_icon_fetcher_query(), rofi_icon_fetcher_query_advanced(), script_get_icon(), and wayland_rofi_view_update().

Here is the caller graph for this function:

◆ display_set_fullscreen_mode()

void display_set_fullscreen_mode ( void )

Definition at line 48 of file display.c.

References proxy.

Referenced by wayland___create_window().

Here is the caller graph for this function:

◆ display_set_input_focus()

void display_set_input_focus ( guint w)

Definition at line 20 of file display.c.

References proxy.

Referenced by rofi_view_create().

Here is the caller graph for this function:

◆ display_setup()

gboolean display_setup ( GMainLoop * main_loop,
NkBindings * bindings )
Parameters
main_loopThe GMainLoop
bindingsThe bindings object

Setup the display backend

Returns
Whether the setup succeeded or not

Definition at line 24 of file display.c.

References bindings, main_loop, and proxy.

Referenced by main().

Here is the caller graph for this function:

◆ display_startup_notification()

void display_startup_notification ( RofiHelperExecuteContext * context,
GSpawnChildSetupFunc * child_setup,
gpointer * user_data )
Parameters
contextThe startup notification context for the application to launch
child_setupA pointer to return the child setup function
user_dataA pointer to return the child setup function user_data

Provides the needed child setup function

Definition at line 36 of file display.c.

References proxy.

Referenced by helper_execute().

Here is the caller graph for this function:

◆ monitor_active()

int monitor_active ( workarea * mon)
Parameters
monworkarea to be filled in.

Fills in mon with the information about the monitor rofi should show on.

Returns
TRUE if monitor is found, FALSE if no monitor could be detected.

Definition at line 18 of file display.c.

References mon, and proxy.

Referenced by config_sanity_check(), rofi_theme_parse_process_conditionals(), and xcb___create_window().

Here is the caller graph for this function:

Variable Documentation

◆ xcb_proxy

struct _display_proxy* const xcb_proxy
extern

Definition at line 2048 of file display.c.

Referenced by main().