[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

gEDA-cvs: gaf.git: branch: master updated (1.5.0-20080706-222-g87a19a1)



The branch, master has been updated
       via  87a19a19e52a37f8ad14ae0c4c68f3292b0c3285 (commit)
      from  f76f82985f325d436e3522359a5b3f7d0a2344ea (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


=========
 Summary
=========

 gschem/src/x_preview.c |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)


=================
 Commit Messages
=================

commit 87a19a19e52a37f8ad14ae0c4c68f3292b0c3285
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Sat Oct 11 16:21:34 2008 +0200

    gschem: redraw empty preview on configure events [#2159047]
    
    If the preview widget contained an empty page, the redraw failed. In
    the preview_event_configure() function the function a_zoom_extents()
    returns without drawing if there are no objects on the page. Thus I've
    added a complement logic to redraw the background of the preview if
    required.

:100644 100644 b8fa521... a8b5049... M	gschem/src/x_preview.c

=========
 Changes
=========

commit 87a19a19e52a37f8ad14ae0c4c68f3292b0c3285
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Sat Oct 11 16:21:34 2008 +0200

    gschem: redraw empty preview on configure events [#2159047]
    
    If the preview widget contained an empty page, the redraw failed. In
    the preview_event_configure() function the function a_zoom_extents()
    returns without drawing if there are no objects on the page. Thus I've
    added a complement logic to redraw the background of the preview if
    required.

diff --git a/gschem/src/x_preview.c b/gschem/src/x_preview.c
index b8fa521..a8b5049 100644
--- a/gschem/src/x_preview.c
+++ b/gschem/src/x_preview.c
@@ -332,7 +332,13 @@ preview_event_configure (GtkWidget         *widget,
   retval = x_event_configure (widget, event, preview_w_current);
   preview_w_current->toplevel->DONT_REDRAW = save_redraw;
   if (preview_page != NULL) {
-    a_zoom_extents(preview_w_current, preview_page->object_head, 0);
+    /* If we have an empty page without object, just redraw the background */
+    if (preview_page->object_head == NULL
+	|| preview_page->object_head->next == NULL) {
+      x_repaint_background(preview_w_current);
+    } else {
+      a_zoom_extents(preview_w_current, preview_page->object_head, 0);
+    }
   }
   return retval;
 }




_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs