From 0f91b311be2d598d38a66982f619432dfe61bc70 Mon Sep 17 00:00:00 2001 From: mitchell <70453897+667e-11@users.noreply.github.com> Date: Fri, 20 Jun 2008 14:10:47 -0400 Subject: Added icons to Textadept. --- core/images/ta_128x128.png | Bin 0 -> 11177 bytes core/images/ta_16x16.png | Bin 0 -> 855 bytes core/images/ta_32x32.png | Bin 0 -> 1988 bytes core/images/ta_48x48.png | Bin 0 -> 3329 bytes core/images/ta_64x64.png | Bin 0 -> 4863 bytes core/images/textadept.png | Bin 0 -> 17699 bytes core/images/textadept.svg | 239 +++++++++++++++++++++++++++++++++++++++++++++ src/textadept.c | 16 +++ 8 files changed, 255 insertions(+) create mode 100644 core/images/ta_128x128.png create mode 100644 core/images/ta_16x16.png create mode 100644 core/images/ta_32x32.png create mode 100644 core/images/ta_48x48.png create mode 100644 core/images/ta_64x64.png create mode 100644 core/images/textadept.png create mode 100644 core/images/textadept.svg diff --git a/core/images/ta_128x128.png b/core/images/ta_128x128.png new file mode 100644 index 00000000..beb7d0d1 Binary files /dev/null and b/core/images/ta_128x128.png differ diff --git a/core/images/ta_16x16.png b/core/images/ta_16x16.png new file mode 100644 index 00000000..5c8c4a3e Binary files /dev/null and b/core/images/ta_16x16.png differ diff --git a/core/images/ta_32x32.png b/core/images/ta_32x32.png new file mode 100644 index 00000000..ccbc4fbf Binary files /dev/null and b/core/images/ta_32x32.png differ diff --git a/core/images/ta_48x48.png b/core/images/ta_48x48.png new file mode 100644 index 00000000..43c37825 Binary files /dev/null and b/core/images/ta_48x48.png differ diff --git a/core/images/ta_64x64.png b/core/images/ta_64x64.png new file mode 100644 index 00000000..b7321f9c Binary files /dev/null and b/core/images/ta_64x64.png differ diff --git a/core/images/textadept.png b/core/images/textadept.png new file mode 100644 index 00000000..17a5a3ff Binary files /dev/null and b/core/images/textadept.png differ diff --git a/core/images/textadept.svg b/core/images/textadept.svg new file mode 100644 index 00000000..f3d02e6d --- /dev/null +++ b/core/images/textadept.svg @@ -0,0 +1,239 @@ + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/textadept.c b/src/textadept.c index e3024456..54546a1d 100644 --- a/src/textadept.c +++ b/src/textadept.c @@ -86,6 +86,22 @@ int main(int argc, char **argv) { * - Two status bars: one for notifications, the other for document status. */ void create_ui() { + GList *icons = NULL; + const char *icon_files[] = { + "ta_16x16.png", "ta_32x32.png", "ta_48x48.png", + "ta_64x64.png", "ta_128x128.png" + }; + for (int i = 0; i < 5; i++) { + char *icon_file = g_strconcat(textadept_home, "/core/images/", + icon_files[i], NULL); + GdkPixbuf *pb = gdk_pixbuf_new_from_file(icon_file, NULL); + if (pb) icons = g_list_prepend(icons, pb); + g_free(icon_file); + } + gtk_window_set_default_icon_list(icons); + g_list_foreach(icons, (GFunc) g_object_unref, NULL); + g_list_free(icons); + window = gtk_window_new(GTK_WINDOW_TOPLEVEL); gtk_window_set_default_size(GTK_WINDOW(window), 500, 400); signal(window, "delete_event", w_exit); -- cgit v1.2.3