drop gtk2 support
This commit is contained in:
parent
3b4120fabc
commit
9b9be657bf
10
Makefile
10
Makefile
|
@ -1,12 +1,6 @@
|
||||||
PREFIX = /usr/local
|
PREFIX = /usr/local
|
||||||
|
GTK = gtk+-3.0
|
||||||
ifeq (${GTK3}, 1)
|
VTE = vte-2.90
|
||||||
GTK = gtk+-3.0
|
|
||||||
VTE = vte-2.90
|
|
||||||
else
|
|
||||||
GTK = gtk+-2.0
|
|
||||||
VTE = vte
|
|
||||||
endif
|
|
||||||
|
|
||||||
CFLAGS += -std=c99 -O3 \
|
CFLAGS += -std=c99 -O3 \
|
||||||
-Wall -Wextra -pedantic \
|
-Wall -Wextra -pedantic \
|
||||||
|
|
|
@ -5,7 +5,7 @@ Configuration is done at compile-time via ``config.h``.
|
||||||
DEPENDENCIES
|
DEPENDENCIES
|
||||||
============
|
============
|
||||||
|
|
||||||
A vte version >= 0.28. You can use vte3 by building with ``make GTK3=1``.
|
A vte version >= 0.30.
|
||||||
|
|
||||||
KEYBINDINGS
|
KEYBINDINGS
|
||||||
===========
|
===========
|
||||||
|
|
|
@ -262,20 +262,11 @@ int main(int argc, char **argv) {
|
||||||
|
|
||||||
#ifdef TRANSPARENCY
|
#ifdef TRANSPARENCY
|
||||||
GdkScreen *screen = gtk_widget_get_screen(window);
|
GdkScreen *screen = gtk_widget_get_screen(window);
|
||||||
|
|
||||||
#if GTK_CHECK_VERSION(2, 90, 7)
|
|
||||||
GdkVisual *visual = gdk_screen_get_rgba_visual(screen);
|
GdkVisual *visual = gdk_screen_get_rgba_visual(screen);
|
||||||
if (!visual) {
|
if (!visual) {
|
||||||
visual = gdk_screen_get_system_visual(screen);
|
visual = gdk_screen_get_system_visual(screen);
|
||||||
}
|
}
|
||||||
gtk_widget_set_visual(GTK_WIDGET(window), visual);
|
gtk_widget_set_visual(GTK_WIDGET(window), visual);
|
||||||
#else
|
|
||||||
GdkColormap *colormap = gdk_screen_get_rgba_colormap(screen);
|
|
||||||
if (colormap) {
|
|
||||||
gtk_widget_set_colormap(window, colormap);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
vte_terminal_set_background_saturation(VTE_TERMINAL(vte), TRANSPARENCY);
|
vte_terminal_set_background_saturation(VTE_TERMINAL(vte), TRANSPARENCY);
|
||||||
vte_terminal_set_opacity(VTE_TERMINAL(vte), (guint16)(0xffff * (1 - TRANSPARENCY)));
|
vte_terminal_set_opacity(VTE_TERMINAL(vte), (guint16)(0xffff * (1 - TRANSPARENCY)));
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue