[GRASS-SVN] r63756 - in grass/trunk/display: d.barscale d.erase d.fontlist d.graph d.his d.info d.legend d.mon d.northarrow d.profile d.rast.arrow d.rgb d.text d.vect d.where

svn_grass at osgeo.org svn_grass at osgeo.org
Thu Dec 25 07:01:16 PST 2014


Author: martinl
Date: 2014-12-25 07:01:16 -0800 (Thu, 25 Dec 2014)
New Revision: 63756

Modified:
   grass/trunk/display/d.barscale/main.c
   grass/trunk/display/d.erase/main.c
   grass/trunk/display/d.fontlist/main.c
   grass/trunk/display/d.graph/main.c
   grass/trunk/display/d.his/main.c
   grass/trunk/display/d.info/main.c
   grass/trunk/display/d.legend/main.c
   grass/trunk/display/d.mon/main.c
   grass/trunk/display/d.northarrow/main.c
   grass/trunk/display/d.profile/main.c
   grass/trunk/display/d.rast.arrow/main.c
   grass/trunk/display/d.rgb/main.c
   grass/trunk/display/d.text/main.c
   grass/trunk/display/d.vect/main.c
   grass/trunk/display/d.where/main.c
Log:
update display modules to r63747 (no need to check return code of D_open_driver())


Modified: grass/trunk/display/d.barscale/main.c
===================================================================
--- grass/trunk/display/d.barscale/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.barscale/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -217,15 +217,12 @@
 	do_background = FALSE;
 
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
+
     D_setup(0);
 
-
     draw_scale(east, north, bar_style, text_position, fontsize);
 
-
     D_save_command(G_recreate_command());
     D_close_driver();
 

Modified: grass/trunk/display/d.erase/main.c
===================================================================
--- grass/trunk/display/d.erase/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.erase/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -41,9 +41,7 @@
     if (G_parser(argc, argv))
 	exit(EXIT_FAILURE);
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     D_setup_unity(0);
 

Modified: grass/trunk/display/d.fontlist/main.c
===================================================================
--- grass/trunk/display/d.fontlist/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.fontlist/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -57,9 +57,7 @@
     if (G_parser(argc, argv))
 	exit(EXIT_FAILURE);
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     if (flagL->answer)
 	D_font_info(&list, &count);

Modified: grass/trunk/display/d.graph/main.c
===================================================================
--- grass/trunk/display/d.graph/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.graph/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -94,9 +94,7 @@
 	infile = stdin;
 
     /* open graphics window */
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     /* Parse and select color */
     if (opt2->answer != NULL) {

Modified: grass/trunk/display/d.his/main.c
===================================================================
--- grass/trunk/display/d.his/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.his/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -115,9 +115,7 @@
 
     /* Do screen initializing stuff */
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     /* Prepare the raster cell drawing functions */
     D_setup(0);

Modified: grass/trunk/display/d.info/main.c
===================================================================
--- grass/trunk/display/d.info/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.info/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -66,9 +66,7 @@
 	G_fatal_error(_("No flag given"));
     }
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     if (rflag->answer || dflag->answer || fflag->answer)
 	D_get_frame(&t, &b, &l, &r);

Modified: grass/trunk/display/d.legend/main.c
===================================================================
--- grass/trunk/display/d.legend/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.legend/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -314,9 +314,7 @@
 	flip = !flip;
     }
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
 
     white = D_translate_color(DEFAULT_FG_COLOR);
     black = D_translate_color(DEFAULT_BG_COLOR);

Modified: grass/trunk/display/d.mon/main.c
===================================================================
--- grass/trunk/display/d.mon/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.mon/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -206,9 +206,7 @@
 			width, height, bgcolor_opt->answer,
 			!truecolor_flag->answer, x_flag->answer);
         if (output_opt->answer && !update_flag->answer) {
-            if (D_open_driver() != 0)
-                G_fatal_error(_("No graphics device selected. "
-                                "Use d.mon to select graphics device."));
+            D_open_driver();
             D_setup_unity(0);
             D_erase(bgcolor_opt->answer);
             D_close_driver();

Modified: grass/trunk/display/d.northarrow/main.c
===================================================================
--- grass/trunk/display/d.northarrow/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.northarrow/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -126,15 +126,12 @@
         line_width = 72;
 
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
+
     D_setup(0);
 
-
     draw_n_arrow(east, north, fontsize, n_arrow->answer, line_width);
 
-
     D_save_command(G_recreate_command());
     D_close_driver();
 

Modified: grass/trunk/display/d.profile/main.c
===================================================================
--- grass/trunk/display/d.profile/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.profile/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -256,9 +256,7 @@
 	G_fatal_error(_("At least two points are required"));
 
     /* establish connection with graphics driver */
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     D_setup2(1, 0, 1.05, -0.05, -0.15, 1.05);
 

Modified: grass/trunk/display/d.rast.arrow/main.c
===================================================================
--- grass/trunk/display/d.rast.arrow/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.rast.arrow/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -221,9 +221,7 @@
 
 
     /* Setup driver and check important information */
-    if (D_open_driver() != 0)
-      	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     D_setup(0);
 

Modified: grass/trunk/display/d.rgb/main.c
===================================================================
--- grass/trunk/display/d.rgb/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.rgb/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -78,9 +78,7 @@
 	exit(EXIT_FAILURE);
 
     /* Do screen initializing stuff */
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     overlay = !flag_n->answer;
 

Modified: grass/trunk/display/d.text/main.c
===================================================================
--- grass/trunk/display/d.text/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.text/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -282,9 +282,7 @@
 
     bold = flag.b->answer;
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     if (opt.font->answer)
 	D_font(opt.font->answer);

Modified: grass/trunk/display/d.vect/main.c
===================================================================
--- grass/trunk/display/d.vect/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.vect/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -299,9 +299,7 @@
     if (G_parser(argc, argv))
 	exit(EXIT_FAILURE);
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
+    D_open_driver();
     
     G_get_set_window(&window);
     

Modified: grass/trunk/display/d.where/main.c
===================================================================
--- grass/trunk/display/d.where/main.c	2014-12-25 14:50:03 UTC (rev 63755)
+++ grass/trunk/display/d.where/main.c	2014-12-25 15:01:16 UTC (rev 63756)
@@ -166,10 +166,8 @@
     else
 	fp = stdin;
 
-    if (D_open_driver() != 0)
-	G_fatal_error(_("No graphics device selected. "
-			"Use d.mon to select graphics device."));
-    
+    D_open_driver();
+
     D_setup(0);
 
     where_am_i(coords->answers, fp, have_spheroid, decimal->answer, dcoord->answer);



More information about the grass-commit mailing list