antiright-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Antiright-devel] antiright/src/wmarmon wmarmon.c


From: Jeffrey Bedard
Subject: [Antiright-devel] antiright/src/wmarmon wmarmon.c
Date: Sun, 03 Jul 2005 23:37:16 -0400

CVSROOT:        /cvsroot/antiright
Module name:    antiright
Branch:         
Changes by:     Jeffrey Bedard <address@hidden> 05/07/04 03:37:16

Modified files:
        src/wmarmon    : wmarmon.c 

Log message:
        Updated email address in copyright header and formatted lines to not 
wrap.

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/antiright/antiright/src/wmarmon/wmarmon.c.diff?tr1=1.4&tr2=1.5&r1=text&r2=text

Patches:
Index: antiright/src/wmarmon/wmarmon.c
diff -u antiright/src/wmarmon/wmarmon.c:1.4 antiright/src/wmarmon/wmarmon.c:1.5
--- antiright/src/wmarmon/wmarmon.c:1.4 Sun Jul  3 18:05:33 2005
+++ antiright/src/wmarmon/wmarmon.c     Mon Jul  4 03:37:16 2005
@@ -1,7 +1,7 @@
 /*
   AntiRight
   (c) 2003-2005 Jeffrey Bedard
-  address@hidden
+  address@hidden
    
   This file is part of AntiRight.
    
@@ -17,7 +17,8 @@
    
   You should have received a copy of the GNU General Public License
   along with AntiRight; if not, write to the Free Software
-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  
USA
+  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  
+  02110-1301  USA
 */
 
 #include <X11/Xlib.h>
@@ -76,7 +77,8 @@
 arshell_get_pixel(int red, int green, int blue)
 {
   XColor color;
-  Colormap colormap=DefaultColormap(display, DefaultScreen(display));
+  Colormap colormap=DefaultColormap(display, 
+                                   DefaultScreen(display));
   color.flags=DoRed|DoGreen|DoBlue;
   color.red=red*256;
   color.green=green*256;
@@ -133,24 +135,30 @@
   XFillRectangle(display, iconwin, gc, 4, 4, 56, 56);
   arshell_set_font("5x7");
   arshell_set_foreground(250, 250, 250);
-  XDrawString(display, iconwin, gc, 6, 16, hostname, strlen(hostname));
+  XDrawString(display, iconwin, gc, 6, 16, 
+             hostname, strlen(hostname));
   asprintf(&string, "%sM fr/sw", swap);
   arshell_set_foreground(250, 200, 200);
-  XDrawString(display, iconwin, gc, 6, 24, string, strlen(string));
+  XDrawString(display, iconwin, gc, 6, 24, 
+             string, strlen(string));
   free(string);
   asprintf(&string, "%s users", users);
   arshell_set_foreground(200, 200, 250);
-  XDrawString(display, iconwin, gc, 6, 32, string, strlen(string));
+  XDrawString(display, iconwin, gc, 6, 32, 
+             string, strlen(string));
   free(string);
   arshell_set_foreground(200, 250, 200);
   asprintf(&string, "%d%% 1m", (int)(load[0]*100));
-  XDrawString(display, iconwin, gc, 6, 40, string, strlen(string));
+  XDrawString(display, iconwin, gc, 6, 40, 
+             string, strlen(string));
   free(string);
   asprintf(&string, "%d%% 5m", (int)(load[1]*100));
-  XDrawString(display, iconwin, gc, 6, 48, string, strlen(string));
+  XDrawString(display, iconwin, gc, 6, 48, 
+             string, strlen(string));
   free(string);
   asprintf(&string, "%d%% 15m", (int)(load[2]*100));
-  XDrawString(display, iconwin, gc, 6, 56, string, strlen(string));
+  XDrawString(display, iconwin, gc, 6, 56, 
+             string, strlen(string));
   free(string);
   
   XFlush(display);
@@ -212,23 +220,31 @@
   mysizehints.flags=USSize | USPosition;
   mysizehints.x = 0;
   mysizehints.y = 0;
-  XWMGeometry(display, DefaultScreen(display), Geometry, NULL, 0, &mysizehints,
+  XWMGeometry(display, DefaultScreen(display), Geometry, 
+             NULL, 0, &mysizehints,
              &mysizehints.x, &mysizehints.y, 
              &mysizehints.width, &mysizehints.height, &dummy);
 
   mysizehints.width=64;
   mysizehints.height=64;
   
-  window=XCreateSimpleWindow(display, DefaultRootWindow(display),
-                            mysizehints.x, mysizehints.y, mysizehints.width, 
+  window=XCreateSimpleWindow(display, 
+                            DefaultRootWindow(display),
+                            mysizehints.x, mysizehints.y, 
+                            mysizehints.width, 
                             mysizehints.height, 0,
-                            BlackPixel(display, DefaultScreen(display)),
-                            WhitePixel(display, DefaultScreen(display)));
+                            BlackPixel(display, 
+                                       DefaultScreen(display)),
+                            WhitePixel(display, 
+                                       DefaultScreen(display)));
   iconwin=XCreateSimpleWindow(display, window,
-                             mysizehints.x, mysizehints.y, mysizehints.width, 
+                             mysizehints.x, mysizehints.y, 
+                             mysizehints.width, 
                              mysizehints.height, 0,
-                             BlackPixel(display, DefaultScreen(display)),
-                             WhitePixel(display, DefaultScreen(display)));
+                             BlackPixel(display, 
+                                        DefaultScreen(display)),
+                             WhitePixel(display, 
+                                        DefaultScreen(display)));
   XSetWMNormalHints(display, window, &mysizehints);
   classHint.res_name=wname;
   classHint.res_class=wname;
@@ -237,12 +253,14 @@
   XStoreName(display, window, "wmar");
   XSelectInput(display, window, ButtonPressMask | ExposureMask 
               | ButtonReleaseMask 
-              | PointerMotionMask | StructureNotifyMask | EnterWindowMask 
+              | PointerMotionMask | StructureNotifyMask 
+              | EnterWindowMask 
               | LeaveWindowMask 
               | KeyPressMask | KeyReleaseMask);
   XSelectInput(display, iconwin, ButtonPressMask | ExposureMask 
               | ButtonReleaseMask 
-              | PointerMotionMask | StructureNotifyMask | EnterWindowMask 
+              | PointerMotionMask | StructureNotifyMask 
+              | EnterWindowMask 
               | LeaveWindowMask 
               | KeyPressMask | KeyReleaseMask);
   gcm = GCForeground | GCBackground | GCGraphicsExposures;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]