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

gEDA-cvs: gaf.git: branch: stable-1.4 updated (1.4.2-20081220-8-g89bb8cf)



The branch, stable-1.4 has been updated
       via  89bb8cf750c586b5b291f2fd90d204791650dae5 (commit)
      from  416c2900bcc126171a28e33341b90d9d49848ab8 (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 89bb8cf750c586b5b291f2fd90d204791650dae5
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Sun Dec 21 23:59:56 2008 +0000

    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.
    
    (cherry picked from commit 87a19a19e52a37f8ad14ae0c4c68f3292b0c3285)

:100644 100644 e8b23c5... 0eacebe... M	gschem/src/x_preview.c

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

commit 89bb8cf750c586b5b291f2fd90d204791650dae5
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Sun Dec 21 23:59:56 2008 +0000

    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.
    
    (cherry picked from commit 87a19a19e52a37f8ad14ae0c4c68f3292b0c3285)

diff --git a/gschem/src/x_preview.c b/gschem/src/x_preview.c
index e8b23c5..0eacebe 100644
--- a/gschem/src/x_preview.c
+++ b/gschem/src/x_preview.c
@@ -366,7 +366,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