Index: /branches/eam_branches/ohana.20160226/src/kapa2/include/buttons.h
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/include/buttons.h	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/include/buttons.h	(revision 39418)
@@ -1,5 +1,5 @@
 #define PS_width 25
 #define PS_height 25
-static char PS_bits[] = {
+static unsigned char PS_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x81, 0x3f, 0x00,
    0x82, 0x67, 0x60, 0x00, 0x02, 0x26, 0x40, 0x00, 0x02, 0x24, 0x40, 0x00,
@@ -13,5 +13,5 @@
 #define grey_width 25
 #define grey_height 25
-static char grey_bits[] = {
+static unsigned char grey_bits[] = {
    0x90, 0x40, 0xf7, 0x01, 0x04, 0xaa, 0xad, 0x01, 0x68, 0xd5, 0xfe, 0x01,
    0x82, 0x28, 0xdb, 0x01, 0x10, 0xd2, 0x75, 0x01, 0x40, 0xad, 0xee, 0x01,
@@ -25,5 +25,5 @@
 #define rainbow_width 25
 #define rainbow_height 25
-static char rainbow_bits[] = {
+static unsigned char rainbow_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x00, 0x80, 0xff, 0x00, 0x00, 0x70, 0x00, 0x01, 0x00, 0x0c, 0x7f, 0x00,
@@ -37,5 +37,5 @@
 #define recenter_width 25
 #define recenter_height 25
-static char recenter_bits[] = {
+static unsigned char recenter_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x00,
    0x80, 0xef, 0x03, 0x00, 0xe0, 0x00, 0x0e, 0x00, 0x30, 0x00, 0x18, 0x00,
@@ -49,5 +49,5 @@
 #define heat_width 25
 #define heat_height 25
-static char heat_bits[] = {
+static unsigned char heat_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0xd8, 0x01,
    0x00, 0x0c, 0x37, 0x00, 0xf8, 0xc9, 0x6f, 0x00, 0x0c, 0xde, 0xf0, 0x00,
@@ -61,5 +61,5 @@
 #define red_width 25
 #define red_height 25
-static char red_bits[] = {
+static unsigned char red_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xfc, 0x03, 0x00,
    0x20, 0x07, 0x06, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x08, 0x00,
@@ -73,5 +73,5 @@
 #define green_width 25
 #define green_height 25
-static char green_bits[] = {
+static unsigned char green_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00,
    0x00, 0x06, 0x04, 0x00, 0x80, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00,
@@ -85,5 +85,5 @@
 #define blue_width 25
 #define blue_height 25
-static char blue_bits[] = {
+static unsigned char blue_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0xfe, 0x00, 0x00,
    0xc0, 0x83, 0x07, 0x00, 0xc0, 0x00, 0x0c, 0x00, 0x40, 0x00, 0x08, 0x00,
@@ -97,5 +97,5 @@
 #define yellow_width 25
 #define yellow_height 25
-static char yellow_bits[] = {
+static unsigned char yellow_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x18, 0x00,
    0x80, 0x01, 0x0c, 0x00, 0x00, 0x03, 0x06, 0x00, 0x00, 0x02, 0x02, 0x00,
@@ -109,5 +109,5 @@
 #define flipx_width 25
 #define flipx_height 25
-static char flipx_bits[] = {
+static unsigned char flipx_bits[] = {
    0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00,
    0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x01, 0x00, 0x80, 0x10, 0x02, 0x00,
@@ -121,5 +121,5 @@
 #define flipy_width 25
 #define flipy_height 25
-static char flipy_bits[] = {
+static unsigned char flipy_bits[] = {
    0x00, 0x10, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00,
    0x00, 0x82, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x80, 0x00, 0x02, 0x00,
@@ -133,5 +133,5 @@
 #define hex_width 25
 #define hex_height 12
-static char hex_bits[] = {
+static unsigned char hex_bits[] = {
    0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf0, 0x00, 0x1e, 0x00, 0x88, 0x00,
Index: /branches/eam_branches/ohana.20160226/src/kapa2/include/hms_buttons.h
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/include/hms_buttons.h	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/include/hms_buttons.h	(revision 39418)
@@ -1,5 +1,5 @@
 #define hms_width 25
 #define hms_height 12
-static char hms_bits[] = {
+static unsigned char hms_bits[] = {
    0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x00, 0x02, 0x01, 0xf0, 0x00, 0x1e, 0xef, 0x89, 0x00,
@@ -8,5 +8,5 @@
 #define ddd_width 25
 #define ddd_height 12
-static char ddd_bits[] = {
+static unsigned char ddd_bits[] = {
    0x40, 0x80, 0x80, 0x00, 0x40, 0x80, 0x80, 0x00, 0x40, 0x80, 0x80, 0x00,
    0x40, 0x80, 0x80, 0x00, 0x40, 0x80, 0x80, 0x00, 0x5c, 0xb8, 0xb8, 0x00,
Index: /branches/eam_branches/ohana.20160226/src/kapa2/include/prototypes.h
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/include/prototypes.h	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/include/prototypes.h	(revision 39418)
@@ -172,9 +172,9 @@
 void          SetImageSize        PROTO((Section *section));
 
-void          InitButtonSize      PROTO((Button *button, int width, int height, char *bitmap));
+void          InitButtonSize      PROTO((Button *button, int width, int height, unsigned char *bitmap));
 void          InitButtonFunc      PROTO((Button *button, int (*function)(Graphic *graphic, KapaImageWidget *image)));
 void          DrawImage           PROTO((KapaImageWidget *image));
 void          DrawButton          PROTO((Graphic *graphic, Button *button));
-void          DrawBitmap          PROTO((Graphic *graphic, int x, int y, int dx, int dy, char *bitmap, int mode));
+void          DrawBitmap          PROTO((Graphic *graphic, int x, int y, int dx, int dy, unsigned char *bitmap, int mode));
 void          CrossHairs          PROTO((Graphic *graphic, Picture *image));
 void          hh_hms              PROTO((char *line, double ra, double dec, char sep, int Nchar));
Index: /branches/eam_branches/ohana.20160226/src/kapa2/include/structures.h
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/include/structures.h	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/include/structures.h	(revision 39418)
@@ -55,5 +55,5 @@
   int      x, y, dx, dy;      /* position and size */
   int      width, height;     /* size of the bitmap */
-  char    *bitmap;            /* picture on button */
+  unsigned char *bitmap;            /* picture on button */
   int    (*function_1) ();    /* mouse_button 1 function */
   int    (*function_2) ();    /* mouse_button 2 function */
Index: /branches/eam_branches/ohana.20160226/src/kapa2/src/ButtonFunctions.c
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/src/ButtonFunctions.c	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/src/ButtonFunctions.c	(revision 39418)
@@ -3,4 +3,6 @@
 
 int PSfunction (Graphic *graphic, KapaImageWidget *image) {
+  OHANA_UNUSED_PARAM(graphic);
+  OHANA_UNUSED_PARAM(image);
 
   int status;
@@ -11,4 +13,6 @@
 
 int PNGfunction (Graphic *graphic, KapaImageWidget *image) {
+  OHANA_UNUSED_PARAM(graphic);
+  OHANA_UNUSED_PARAM(image);
 
   int status;
@@ -19,4 +23,6 @@
 
 int JPEGfunction (Graphic *graphic, KapaImageWidget *image) {
+  OHANA_UNUSED_PARAM(graphic);
+  OHANA_UNUSED_PARAM(image);
 
   int status;
@@ -137,4 +143,5 @@
 /*********** overlay_button functions ************/
 int Overlay0 (Graphic *graphic, KapaImageWidget *image) {
+  OHANA_UNUSED_PARAM(graphic);
 
   image[0].overlay[0].active = image[0].overlay[0].active ^ TRUE;
@@ -145,4 +152,5 @@
 
 int Overlay1 (Graphic *graphic, KapaImageWidget *image) {
+  OHANA_UNUSED_PARAM(graphic);
 
   image[0].overlay[1].active = image[0].overlay[1].active ^ TRUE;
@@ -153,4 +161,5 @@
 
 int Overlay2 (Graphic *graphic, KapaImageWidget *image) {
+  OHANA_UNUSED_PARAM(graphic);
 
   image[0].overlay[2].active = image[0].overlay[2].active ^ TRUE;
@@ -161,4 +170,5 @@
 
 int Overlay3 (Graphic *graphic, KapaImageWidget *image) {
+  OHANA_UNUSED_PARAM(graphic);
 
   image[0].overlay[3].active = image[0].overlay[3].active ^ TRUE;
Index: /branches/eam_branches/ohana.20160226/src/kapa2/src/DrawBitmap.c
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/src/DrawBitmap.c	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/src/DrawBitmap.c	(revision 39418)
@@ -1,5 +1,5 @@
 # include "Ximage.h"
 
-void DrawBitmap (Graphic *graphic, int x, int y, int dx, int dy, char *bitmap, int mode) {
+void DrawBitmap (Graphic *graphic, int x, int y, int dx, int dy, unsigned char *bitmap, int mode) {
 
   int i, j, byte_line, byte, bit, flag;
Index: /branches/eam_branches/ohana.20160226/src/kapa2/src/Image.c
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/src/Image.c	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/src/Image.c	(revision 39418)
@@ -132,5 +132,5 @@
 }
 
-void InitButtonSize (Button *button, int width, int height, char *bitmap) {
+void InitButtonSize (Button *button, int width, int height, unsigned char *bitmap) {
   button->dx = width + 2;
   button->dy = height + 2;
Index: /branches/eam_branches/ohana.20160226/src/kapa2/src/PNGit.c
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/src/PNGit.c	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/src/PNGit.c	(revision 39418)
@@ -32,5 +32,5 @@
   }
 
-  png_ptr = png_create_write_struct (PNG_LIBPNG_VER_STRING, (png_voidp) NULL, (png_voidp) NULL, (png_voidp) NULL);
+  png_ptr = png_create_write_struct (PNG_LIBPNG_VER_STRING, NULL, NULL, NULL);
   if (!png_ptr) {
     fprintf (stderr, "can't get png structure\n");
@@ -42,5 +42,5 @@
   if (!info_ptr) {
     fprintf (stderr, "can't get png info structure\n");
-    png_destroy_write_struct (&png_ptr, (png_infopp) NULL);
+    png_destroy_write_struct (&png_ptr, NULL);
     fclose (f);
     return (TRUE);
Index: /branches/eam_branches/ohana.20160226/src/kapa2/src/PaintOverlay.c
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/src/PaintOverlay.c	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/src/PaintOverlay.c	(revision 39418)
@@ -34,5 +34,5 @@
     if (X - dX > Xmax) continue;
     if (Y + dY < Ymin) continue; 
-    if (Y - dY > Ymax);
+    if (Y - dY > Ymax) continue;
 
     pX = (image[0].picture.flipx) ? -1.0 : +1.0;
Index: /branches/eam_branches/ohana.20160226/src/kapa2/src/Resize.c
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/src/Resize.c	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/src/Resize.c	(revision 39418)
@@ -12,5 +12,5 @@
 
   // must scan the message before possible return
-  KiiScanMessage (sock, "%d %d", &NX, &NY);
+  KiiScanMessage (sock, "%u %u", &NX, &NY);
 
   // XXX keep this min limit (or modify for !USE_XWINDOW)?
@@ -42,4 +42,5 @@
 // resise the window so the image in the currently active window fills its section
 int ResizeByImage (int sock) {
+  OHANA_UNUSED_PARAM(sock);
  
   int i, Nsection;
Index: /branches/eam_branches/ohana.20160226/src/kapa2/src/bDrawOverlay.c
===================================================================
--- /branches/eam_branches/ohana.20160226/src/kapa2/src/bDrawOverlay.c	(revision 39417)
+++ /branches/eam_branches/ohana.20160226/src/kapa2/src/bDrawOverlay.c	(revision 39418)
@@ -44,5 +44,5 @@
     if (X - dX > Xmax) continue;
     if (Y + dY < Ymin) continue; 
-    if (Y - dY > Ymax);
+    if (Y - dY > Ymax) continue;
 
     pX = (image[0].picture.flipx) ? -1.0 : +1.0;
