Skip to content

Commit

Permalink
Add support for alpha channel to the window
Browse files Browse the repository at this point in the history
Getting the screen's visual and setting it on the window is all that's
needed for VTE's alpha channel support.

Fix thestinger#191
  • Loading branch information
tomjakubowski committed Oct 27, 2014
1 parent 05f3bbf commit c79f08d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions termite.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1420,6 +1420,12 @@ int main(int argc, char **argv) {
GtkWidget *vte_widget = vte_terminal_new();
VteTerminal *vte = VTE_TERMINAL(vte_widget);

GdkScreen *screen = gtk_widget_get_screen(window);
GdkVisual *visual = gdk_screen_get_rgba_visual(screen);
if (visual) {
gtk_widget_set_visual(GTK_WIDGET(window), visual);
}

if (role) {
gtk_window_set_role(GTK_WINDOW(window), role);
g_free(role);
Expand Down

0 comments on commit c79f08d

Please sign in to comment.