printer debugging.. the oki and mozilla just had to be able to talk fonts. yay
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 18 Nov 2005 20:06:26 +0000 (20:06 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 18 Nov 2005 20:06:26 +0000 (20:06 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@2084 dcc99617-32d9-48b4-a31d-7c20da2025e4

Evergreen/staff_client/chrome/content/evergreen/util/print.js

index 908b1ac..1ddb342 100644 (file)
@@ -224,13 +224,13 @@ function NSPrint(w,silent,params)
                        var gPrintSettings = GetPrintSettings();
                        if (silent) gPrintSettings.printSilent = true;
                        else gPrintSettings.printSilent = false;
-                       /*
-                        gPrintSettings.marginTop = 0;
-                        gPrintSettings.marginLeft = 0;
-                        gPrintSettings.marginBottom = 0;
-                        gPrintSettings.marginRight = 0;
-                       */
-                        if (params.marginLeft) gPrintSettings.marginLeft = params.marginLeft;
+                       if (params) {
+                               gPrintSettings.marginTop = 0;
+                               gPrintSettings.marginLeft = 0;
+                               gPrintSettings.marginBottom = 0;
+                               gPrintSettings.marginRight = 0;
+                               if (params.marginLeft) gPrintSettings.marginLeft = params.marginLeft;
+                       }
                         gPrintSettings.headerStrLeft = '';
                         gPrintSettings.headerStrCenter = '';
                         gPrintSettings.headerStrRight = '';
@@ -238,6 +238,7 @@ function NSPrint(w,silent,params)
                         gPrintSettings.footerStrCenter = '';
                         gPrintSettings.footerStrRight = '';
                        sdump('D_PRINT','gPrintSettings = ' + js2JSON(gPrintSettings));
+                       alert('gPrintSettings = ' + js2JSON(gPrintSettings));
                        webBrowserPrint.print(gPrintSettings, null);
                        //alert('Should be printing\n');
                        sdump('D_PRINT','Should be printing\n');