From b0abd5abd8f1260f0bc52090fea3b42972dac9d2 Mon Sep 17 00:00:00 2001 From: Daniel Micay Date: Wed, 30 May 2012 06:54:10 -0400 Subject: [PATCH] make icon an option in config.h --- config.h | 1 + termite.c | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/config.h b/config.h index d525826..f0408e9 100644 --- a/config.h +++ b/config.h @@ -6,6 +6,7 @@ #define URGENT_ON_BEEP #define DYNAMIC_TITLE #define CLICKABLE_URL +//#define ICON_NAME "terminal" #ifdef CLICKABLE_URL static const char *url_regex = "(ftp|http)s?://[-a-zA-Z0-9.?$%&/=_~#.,:;+]*"; diff --git a/termite.c b/termite.c index e9af5f5..8efd4e9 100644 --- a/termite.c +++ b/termite.c @@ -166,10 +166,13 @@ int main(int argc, char **argv) { GtkWidget *window = gtk_window_new(GTK_WINDOW_TOPLEVEL); /*gtk_window_set_default_size(GTK_WINDOW(window), 400, 400);*/ - GdkPixbuf *icon = gtk_icon_theme_load_icon (gtk_icon_theme_get_default (), "terminal", 48, 0, NULL); + +#ifdef ICON_NAME + GdkPixbuf *icon = gtk_icon_theme_load_icon(gtk_icon_theme_get_default(), ICON_NAME, 48, 0, NULL); if (icon) { - gtk_window_set_icon (GTK_WINDOW (window), icon); + gtk_window_set_icon(GTK_WINDOW(window), icon); } +#endif GtkWidget *vte = vte_terminal_new();