mirror of
https://git.pwmt.org/pwmt/zathura.git
synced 2024-11-14 07:53:45 +01:00
Fullscreen
It is now possible to enable a fullscreen mode.
This commit is contained in:
parent
f0c0c7b8ee
commit
ecfe451807
@ -65,6 +65,7 @@ Shortcut shortcuts[] = {
|
|||||||
/* mask, key, function, mode, argument */
|
/* mask, key, function, mode, argument */
|
||||||
{GDK_CONTROL_MASK, GDK_n, sc_toggle_statusbar, NORMAL, {0} },
|
{GDK_CONTROL_MASK, GDK_n, sc_toggle_statusbar, NORMAL, {0} },
|
||||||
{GDK_CONTROL_MASK, GDK_m, sc_toggle_inputbar, NORMAL, {0} },
|
{GDK_CONTROL_MASK, GDK_m, sc_toggle_inputbar, NORMAL, {0} },
|
||||||
|
{0, GDK_F5, sc_toggle_fullscreen, NORMAL, {0} },
|
||||||
{GDK_CONTROL_MASK, GDK_q, sc_quit, -1, {0} },
|
{GDK_CONTROL_MASK, GDK_q, sc_quit, -1, {0} },
|
||||||
{GDK_CONTROL_MASK, GDK_c, sc_abort, -1, {0} },
|
{GDK_CONTROL_MASK, GDK_c, sc_abort, -1, {0} },
|
||||||
{GDK_CONTROL_MASK, GDK_i, sc_recolor, NORMAL, {0} },
|
{GDK_CONTROL_MASK, GDK_i, sc_recolor, NORMAL, {0} },
|
||||||
|
24
zathura.c
24
zathura.c
@ -322,6 +322,7 @@ void sc_switch_goto_mode(Argument*);
|
|||||||
void sc_navigate_index(Argument*);
|
void sc_navigate_index(Argument*);
|
||||||
void sc_toggle_index(Argument*);
|
void sc_toggle_index(Argument*);
|
||||||
void sc_toggle_inputbar(Argument*);
|
void sc_toggle_inputbar(Argument*);
|
||||||
|
void sc_toggle_fullscreen(Argument*);
|
||||||
void sc_toggle_statusbar(Argument*);
|
void sc_toggle_statusbar(Argument*);
|
||||||
void sc_quit(Argument*);
|
void sc_quit(Argument*);
|
||||||
|
|
||||||
@ -1791,6 +1792,29 @@ sc_toggle_inputbar(Argument* argument)
|
|||||||
gtk_widget_show(GTK_WIDGET(Zathura.UI.inputbar));
|
gtk_widget_show(GTK_WIDGET(Zathura.UI.inputbar));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
sc_toggle_fullscreen(Argument* argument)
|
||||||
|
{
|
||||||
|
static gboolean fs = TRUE;
|
||||||
|
|
||||||
|
if(fs)
|
||||||
|
{
|
||||||
|
gtk_window_fullscreen(GTK_WINDOW(Zathura.UI.window));
|
||||||
|
gtk_widget_hide(GTK_WIDGET(Zathura.UI.inputbar));
|
||||||
|
gtk_widget_hide(GTK_WIDGET(Zathura.UI.statusbar));
|
||||||
|
|
||||||
|
fs = FALSE;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
gtk_window_unfullscreen(GTK_WINDOW(Zathura.UI.window));
|
||||||
|
gtk_widget_show(GTK_WIDGET(Zathura.UI.inputbar));
|
||||||
|
gtk_widget_show(GTK_WIDGET(Zathura.UI.statusbar));
|
||||||
|
|
||||||
|
fs = TRUE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
sc_toggle_statusbar(Argument* argument)
|
sc_toggle_statusbar(Argument* argument)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user