[GRASS-SVN] r33915 - grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target

svn_grass at osgeo.org svn_grass at osgeo.org
Thu Oct 16 09:12:12 EDT 2008


Author: hamish
Date: 2008-10-16 09:12:12 -0400 (Thu, 16 Oct 2008)
New Revision: 33915

Modified:
   grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/analyze.c
   grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/ask.c
   grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/input.c
Log:
fix window rendering (merge from i.points r20395) 

Modified: grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/analyze.c
===================================================================
--- grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/analyze.c	2008-10-16 12:41:18 UTC (rev 33914)
+++ grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/analyze.c	2008-10-16 13:12:12 UTC (rev 33915)
@@ -115,7 +115,7 @@
     nums += left;
 
     /* save what is under this area, so it can be restored */
-    R_panel_save(tempfile1, top, bottom, left, right);
+    R_panel_save(tempfile1, top, bottom+1, left, right+1);
 
 
     /* fill it with white */
@@ -317,11 +317,14 @@
 	show_point(first_point + n, 1);
 	return 1;
     }
+
+    /* first click */
     which = n;
     show_point(first_point + n, 0);
     R_standard_color(RED);
-    Outline_box(report.top + n * height, report.top + (n + 1) * height,
+    Outline_box((report.top + n * height)+1, report.top + (n + 1) * height,
 		report.left, report.right - 1);
+    R_flush();
     return 0;			/* ignore first click */
 
 }
@@ -336,7 +339,7 @@
 {
     if (which >= 0) {
 	R_standard_color(BACKGROUND);
-	Outline_box(report.top + which * height,
+	Outline_box((report.top + which * height)+1,
 		    report.top + (which + 1) * height, report.left,
 		    report.right - 1);
 	show_point(first_point + which, 1);

Modified: grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/ask.c
===================================================================
--- grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/ask.c	2008-10-16 12:41:18 UTC (rev 33914)
+++ grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/ask.c	2008-10-16 13:12:12 UTC (rev 33915)
@@ -140,8 +140,8 @@
     rightx = leftx + widthx;
 
     /* save what is under these areas, so they can be restored */
-    R_panel_save(tempfile1, top, bottom, left, right);
-    R_panel_save(tempfile2, topx, bottomx, leftx, rightx);
+    R_panel_save(tempfile1, top, bottom+1, left, right+1);
+    R_panel_save(tempfile2, topx, bottomx+1, leftx, rightx+1);
 
     /* fill it top with GREY, pick area with white */
     R_standard_color(WHITE);
@@ -276,6 +276,7 @@
     R_standard_color(BLACK);
     Outline_box(top, bottom, left, right);
     dotext(text, top, bottom, left, right, centered);
+    R_flush();
 
     box->top = top;
     box->bottom = bottom;
@@ -327,6 +328,7 @@
 	which = -2;
 	R_standard_color(RED);
 	Outline_box(cancel.top, cancel.bottom, cancel.left, cancel.right);
+	R_flush();
 	return 0;
     }
     /* search name list. handle double click */
@@ -339,6 +341,7 @@
 	    R_standard_color(RED);
 	    Outline_box(list[n].box.top, list[n].box.bottom,
 			list[n].box.left, list[n].box.right);
+	    R_flush();
 	    return 0;		/* ignore first click */
 	}
 

Modified: grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/input.c
===================================================================
--- grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/input.c	2008-10-16 12:41:18 UTC (rev 33914)
+++ grass/branches/develbranch_6/imagery/i.ortho.photo/photo.2target/input.c	2008-10-16 13:12:12 UTC (rev 33915)
@@ -213,13 +213,14 @@
     R_standard_color(OUTLINE_COLOR);
     for (x = objects; x->type; x++) {
 	if (x->type == OPTION_OBJECT && *x->status == 0)
-	    Outline_box(x->top, x->bottom, x->left, x->right);
+	    Outline_box(x->top +1, x->bottom, x->left, x->right -1);
     }
     R_standard_color(GREEN);
     for (x = objects; x->type; x++) {
 	if (x->type == OPTION_OBJECT && *x->status > 0)
-	    Outline_box(x->top, x->bottom, x->left, x->right);
+	    Outline_box(x->top +1, x->bottom, x->left, x->right -1);
     }
+    R_flush();
 
     return 0;
 }



More information about the grass-commit mailing list