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

gEDA-cvs: pcb.git: branch: master updated (480e81559af88dacbfb6bd94cd5fb705ec4f7cb4)



The branch, master has been updated
       via  480e81559af88dacbfb6bd94cd5fb705ec4f7cb4 (commit)
       via  e85f5eea45e6db6245dd960916cd544e844e5cab (commit)
      from  050e6e6fea127f611ee0db11ef162c2dd27fb3d6 (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
=========

 src/hid/gtk/gui-top-window.c |   10 ++++++++--
 src/hid/png/png.c            |   11 +++++------
 2 files changed, 13 insertions(+), 8 deletions(-)


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

commit 480e81559af88dacbfb6bd94cd5fb705ec4f7cb4
Author: Dan McMahill <dan@xxxxxxxxxxxx>
Commit: Dan McMahill <dan@xxxxxxxxxxxx>

    When built with less than all of the graphic formats that
    the png exporter supports, don't segfault anymore.  The problem
    is an array is defined differently at compile time but the
    default value for the format was constant and a ways into the
    array.  Problem reported by jean on irc.

:100644 100644 404eb53... ba7e763... M	src/hid/png/png.c

commit e85f5eea45e6db6245dd960916cd544e844e5cab
Author: Dan McMahill <dan@xxxxxxxxxxxx>
Commit: Dan McMahill <dan@xxxxxxxxxxxx>

    Inform the user where (what file or compiled in defaults) the
    menu config came from.  Should help with some of the gpcb-menu.res
    versus pcb-menu.res and the ./gpcb-menu.res versus ~/.pcb/gpcb-menu.res
    confusion which comes up from time to time.

:100644 100644 eb8ba18... a594330... M	src/hid/gtk/gui-top-window.c

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

commit 480e81559af88dacbfb6bd94cd5fb705ec4f7cb4
Author: Dan McMahill <dan@xxxxxxxxxxxx>
Commit: Dan McMahill <dan@xxxxxxxxxxxx>

    When built with less than all of the graphic formats that
    the png exporter supports, don't segfault anymore.  The problem
    is an array is defined differently at compile time but the
    default value for the format was constant and a ways into the
    array.  Problem reported by jean on irc.

diff --git a/src/hid/png/png.c b/src/hid/png/png.c
index 404eb53..ba7e763 100644
--- a/src/hid/png/png.c
+++ b/src/hid/png/png.c
@@ -124,6 +124,10 @@ static int photo_groups[MAX_LAYER+2], photo_ngroups;
 #define FMT_png "PNG"
 
 static const char *filetypes[] = {
+#ifdef HAVE_GDIMAGEPNG
+  FMT_png,
+#endif
+
 #ifdef HAVE_GDIMAGEGIF
   FMT_gif,
 #endif
@@ -132,10 +136,6 @@ static const char *filetypes[] = {
   FMT_jpg,
 #endif
 
-#ifdef HAVE_GDIMAGEPNG
-  FMT_png,
-#endif
-
   NULL
 };
 
@@ -178,7 +178,7 @@ HID_Attribute png_attribute_list[] = {
 #define HA_use_alpha 8
 
   {"format", "Graphics file format",
-   HID_Enum, 0, 0, {2, 0, 0}, filetypes, 0},
+   HID_Enum, 0, 0, {0, 0, 0}, filetypes, 0},
 #define HA_filetype 9
 
   {"png-bloat", "Amount (in/mm/mil/pix) to add to trace/pad/pin edges (1 = 1/100 mil)",
@@ -221,7 +221,6 @@ static const char *get_file_suffix(void)
 	const char *fmt;
 	const char *result;
 	fmt = filetypes[png_attribute_list[HA_filetype].default_val.int_value];
-	/* or is it filetypes[png_attribute_list[HA_filetype].default_val.int_value]; ? */
 	     if (strcmp (fmt, FMT_gif) == 0)  result=".gif";
 	else if (strcmp (fmt, FMT_jpg) == 0)  result=".jpg";
 	else if (strcmp (fmt, FMT_png) == 0)  result=".png";

commit e85f5eea45e6db6245dd960916cd544e844e5cab
Author: Dan McMahill <dan@xxxxxxxxxxxx>
Commit: Dan McMahill <dan@xxxxxxxxxxxx>

    Inform the user where (what file or compiled in defaults) the
    menu config came from.  Should help with some of the gpcb-menu.res
    versus pcb-menu.res and the ./gpcb-menu.res versus ~/.pcb/gpcb-menu.res
    confusion which comes up from time to time.

diff --git a/src/hid/gtk/gui-top-window.c b/src/hid/gtk/gui-top-window.c
index eb8ba18..a594330 100644
--- a/src/hid/gtk/gui-top-window.c
+++ b/src/hid/gtk/gui-top-window.c
@@ -3756,7 +3756,10 @@ ghid_load_menus (void)
     }
 
   if (filename)
-    r = resource_parse (filename, 0);
+    {
+      Message ("Loading menus from %s\n", filename);
+      r = resource_parse (filename, 0);
+    }
 
   if (home_pcbmenu != NULL) 
     {
@@ -3764,7 +3767,10 @@ ghid_load_menus (void)
     }
 
   if (!r)
-    r = bir;
+    {
+      Message ("Using default menus\n");
+      r = bir;
+    }
 
   mr = resource_subres (r, "MainMenu");
   if (!mr)




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