From b769f4fc271f38318458ae9938f96cd2e6287452 Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Mon, 8 Jul 2013 11:33:49 +0200 Subject: use new icons, update build system --- .gitignore | 1 + Makefile | 23 +- netlink-notify-address.svg | 923 ++++++++++++++++++++++++++-------------- netlink-notify-connected.svg | 369 ---------------- netlink-notify-disconnected.svg | 318 -------------- netlink-notify-down.svg | 491 +++++++++++++++++++++ netlink-notify-up.svg | 554 ++++++++++++++++++++++++ netlink-notify.c | 4 +- 8 files changed, 1666 insertions(+), 1017 deletions(-) delete mode 100644 netlink-notify-connected.svg delete mode 100644 netlink-notify-disconnected.svg create mode 100644 netlink-notify-down.svg create mode 100644 netlink-notify-up.svg diff --git a/.gitignore b/.gitignore index 218b07a..2e04b85 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ *~ *.o +*.png netlink-notify diff --git a/Makefile b/Makefile index 56248bf..f40abde 100644 --- a/Makefile +++ b/Makefile @@ -1,13 +1,32 @@ # netlink-notify - Notify about netlink changes CC := gcc +CONVERT := inkscape --export-png +INSTALL := install CFLAGS += -O2 -Wall -Werror CFLAGS += $(shell pkg-config --cflags --libs libnotify) VERSION = $(shell git describe --tags --long) -all: netlink-notify.c +all: binary icons + +binary: netlink-notify.c $(CC) $(CFLAGS) -o netlink-notify netlink-notify.c \ -DVERSION="\"$(VERSION)\"" +icons: + $(CONVERT) netlink-notify-up.png netlink-notify-up.svg + $(CONVERT) netlink-notify-down.png netlink-notify-down.svg + $(CONVERT) netlink-notify-address.png netlink-notify-address.svg + +install: + $(INSTALL) -D -m0755 netlink-notify /usr/bin/netlink-notify + $(INSTALL) -D -m0644 netlink-notify.desktop /etc/xdg/autostart/netlink-notify.desktop + $(INSTALL) -D -m0755 netlink-notify-up.svg /usr/share/icons/hicolor/scalable/status/netlink-notify-up.svg + $(INSTALL) -D -m0755 netlink-notify-down.svg /usr/share/icons/hicolor/scalable/status/netlink-notify-down.svg + $(INSTALL) -D -m0755 netlink-notify-address.svg /usr/share/icons/hicolor/scalable/status/netlink-notify-address.svg + $(INSTALL) -D -m0755 netlink-notify-up.png /usr/share/icons/hicolor/48x48/status/netlink-notify-up.png + $(INSTALL) -D -m0755 netlink-notify-down.png /usr/share/icons/hicolor/48x48/status/netlink-notify-down.png + $(INSTALL) -D -m0755 netlink-notify-address.png /usr/share/icons/hicolor/48x48/status/netlink-notify-address.png + clean: - /bin/rm -f *.o *~ netlink-notify + /bin/rm -f *.o *.png *~ netlink-notify diff --git a/netlink-notify-address.svg b/netlink-notify-address.svg index 658fc0d..3f05ab5 100644 --- a/netlink-notify-address.svg +++ b/netlink-notify-address.svg @@ -15,16 +15,19 @@ height="48" id="svg10439" inkscape:version="0.48.4 r9939" - sodipodi:docname="netlink-notify-connected.svg"> + sodipodi:docname="netlink-notify-address-new.svg" + inkscape:export-filename="/home/eworm/version_control/netlink-notify/netlink-notify-connected.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + id="metadata3469"> image/svg+xml - + @@ -39,10 +42,10 @@ inkscape:pageshadow="2" inkscape:window-width="1680" inkscape:window-height="1000" - id="namedview3360" + id="namedview3467" showgrid="false" - inkscape:zoom="1.7460215" - inkscape:cx="24" + inkscape:zoom="16.333333" + inkscape:cx="24.000001" inkscape:cy="24" inkscape:window-x="0" inkscape:window-y="31" @@ -178,408 +181,676 @@ style="stop-color:#737373;stop-opacity:1" offset="1" /> - + + + + + + + + - + + + + + gradientTransform="matrix(0,-0.80371125,0.80000005,0,19.526458,36.135587)" + x1="43.129921" + y1="15.195395" + x2="7.9313831" + y2="34.731434" /> + + gradientTransform="matrix(1,0,0,0.282946,0,13.64644)" + cx="11.25" + cy="19.03125" + fx="11.25" + fy="19.03125" + r="8.0625" /> + gradientTransform="matrix(0.80000005,0,0,0.80000005,21.120158,-4.699656)" + x1="23.964657" + y1="10.91593" + x2="23.964657" + y2="40.923775" /> + inkscape:collect="always" + xlink:href="#linearGradient5113" + id="linearGradient5482" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0,-0.80371125,0.80000005,0,19.526458,36.135587)" + x1="43.129921" + y1="15.195395" + x2="7.9313831" + y2="34.731434" /> + + + + + + + + + style="stop-color:#000000;stop-opacity:0" /> + + style="stop-color:#000000;stop-opacity:0" /> + id="linearGradient51765"> + style="stop-color:#000000;stop-opacity:1" /> + style="stop-color:#000000;stop-opacity:0" /> + style="stop-color:#d3d7cf;stop-opacity:1" /> + style="stop-color:#eeeeec;stop-opacity:1" /> + id="linearGradient3674"> + style="stop-color:#555753;stop-opacity:1" /> + style="stop-color:#888a85;stop-opacity:1" /> + id="linearGradient3690"> - + style="stop-color:white;stop-opacity:1;" /> + style="stop-color:white;stop-opacity:0.46875" /> + + gradientTransform="matrix(1.9576392,-8.146468e-7,6.6614241e-7,1.4565793,-59.017557,62.738067)" + cx="51.4375" + cy="-12.203125" + fx="51.4375" + fy="-12.203125" + r="2.171875" /> + + inkscape:collect="always" + xlink:href="#linearGradient3690" + id="linearGradient2289" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(1.2605424,0,0,1.2058553,-7.4733927,-4.9459439)" + x1="9.5" + y1="16.26436" + x2="9.5" + y2="13.408723" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + style="stop-color:#1f1f1f;stop-opacity:1" + id="stop8556-5" /> + offset="1" + style="stop-color:#000000;stop-opacity:1" + id="stop8558-6" /> + + + offset="0" + style="stop-color:#9b9b9b;stop-opacity:1" + id="stop8539-1" /> + style="stop-color:#ececec;stop-opacity:1" + id="stop8541-8" /> + + + style="display:inline" + inkscape:label="Base" + id="g2721" + transform="matrix(1.4596033,0,0,1.4596033,-35.449859,-64.333531)" /> + + transform="matrix(0.83338541,0,0,0.83338541,0,7.9975003)" + id="layer1"> + style="opacity:0.3" + id="Layer_2"> - + id="g8529"> + + + - - - - - - - + id="Layer_4"> + + + + + + + - - + id="Layer_5"> - + style="opacity:0.4" + id="g8546"> + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + id="Layer_3"> + + + + gradientUnits="userSpaceOnUse" + id="linearGradient10389" + y2="12.083" + x2="24" + y1="35.9175" + x1="24"> + offset="0" + style="stop-color:#1f1f1f;stop-opacity:1" + id="stop10391" /> + offset="1" + style="stop-color:#000000;stop-opacity:1" + id="stop10393" /> - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - + id="g4100"> diff --git a/netlink-notify-connected.svg b/netlink-notify-connected.svg deleted file mode 100644 index 7f86b4e..0000000 --- a/netlink-notify-connected.svg +++ /dev/null @@ -1,369 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/netlink-notify-disconnected.svg b/netlink-notify-disconnected.svg deleted file mode 100644 index 0dd2831..0000000 --- a/netlink-notify-disconnected.svg +++ /dev/null @@ -1,318 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/netlink-notify-down.svg b/netlink-notify-down.svg new file mode 100644 index 0000000..4dce0a1 --- /dev/null +++ b/netlink-notify-down.svg @@ -0,0 +1,491 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/netlink-notify-up.svg b/netlink-notify-up.svg new file mode 100644 index 0000000..e5bbb1a --- /dev/null +++ b/netlink-notify-up.svg @@ -0,0 +1,554 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/netlink-notify.c b/netlink-notify.c index eeeeee1..607fa8a 100644 --- a/netlink-notify.c +++ b/netlink-notify.c @@ -37,8 +37,8 @@ #endif #define ICON_NETWORK_ADDRESS "netlink-notify-address" -#define ICON_NETWORK_CONNECTED "netlink-notify-connected" -#define ICON_NETWORK_DISCONNECTED "netlink-notify-disconnected" +#define ICON_NETWORK_CONNECTED "netlink-notify-up" +#define ICON_NETWORK_DISCONNECTED "netlink-notify-down" #define TEXT_TOPIC "Netlink Notification" #define TEXT_NEWLINK "Interface %s is %s." -- cgit v1.2.3-70-g09d2