gEDA-dev: Printing from PCB

Dan McMahill dan at mcmahill.net
Wed Nov 29 11:30:09 EST 2006


DJ Delorie wrote:
>>Obviously the lack of header is what is causing the printers to print
>>text rather than graphics.
> 
> 
> Yup.
> 
> 
>>Should / do the print and ps export share code. I would have thought
>>they were 99.99% similar.
> 
> 
> Closer to 100% since the printer just calls the exporter, with a pipe
> as the file.  I'll add it to the list of things to investigate.

yes, but it never calls ps_start_file on the pipe :)

Try this:


Index: hid/ps/ps.c
===================================================================
RCS file: /cvsroot/pcb/pcb/src/hid/ps/ps.c,v
retrieving revision 1.17
diff -u -2 -r1.17 ps.c
--- hid/ps/ps.c 10 Nov 2006 21:57:45 -0000      1.17
+++ hid/ps/ps.c 29 Nov 2006 16:29:21 -0000
@@ -243,5 +243,5 @@
  static double fill_zoom;

-static void
+void
  ps_start_file (FILE *f)
  {
Index: hid/ps/ps.h
===================================================================
RCS file: /cvsroot/pcb/pcb/src/hid/ps/ps.h,v
retrieving revision 1.3
diff -u -2 -r1.3 ps.h
--- hid/ps/ps.h 22 Mar 2006 23:14:58 -0000      1.3
+++ hid/ps/ps.h 29 Nov 2006 16:29:21 -0000
@@ -3,4 +3,5 @@
  extern HID ps_hid;
  extern void ps_hid_export_to_file (FILE *, HID_Attr_Val *);
+extern void ps_start_file (FILE *);

  extern void hid_eps_init ();
Index: hid/lpr/lpr.c
===================================================================
RCS file: /cvsroot/pcb/pcb/src/hid/lpr/lpr.c,v
retrieving revision 1.8
diff -u -2 -r1.8 lpr.c
--- hid/lpr/lpr.c       9 Oct 2006 00:35:27 -0000       1.8
+++ hid/lpr/lpr.c       29 Nov 2006 16:29:21 -0000
@@ -92,4 +92,5 @@
      }

+  ps_start_file (f);
    ps_hid_export_to_file (f, options);



More information about the geda-dev mailing list