Back to index

lightning-sunbird  0.9+nobinonly
nsIDeviceContextSpecXPrint.h
Go to the documentation of this file.
00001 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
00002 /* ***** BEGIN LICENSE BLOCK *****
00003  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
00004  *
00005  * The contents of this file are subject to the Mozilla Public License Version
00006  * 1.1 (the "License"); you may not use this file except in compliance with
00007  * the License. You may obtain a copy of the License at
00008  * http://www.mozilla.org/MPL/
00009  *
00010  * Software distributed under the License is distributed on an "AS IS" basis,
00011  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
00012  * for the specific language governing rights and limitations under the
00013  * License.
00014  *
00015  * The Original Code is mozilla.org code.
00016  *
00017  * The Initial Developer of the Original Code is
00018  * Netscape Communications Corporation.
00019  * Portions created by the Initial Developer are Copyright (C) 1998
00020  * the Initial Developer. All Rights Reserved.
00021  *
00022  * Contributor(s):
00023  *   Roland Mainz <roland.mainz@informatik.med.uni-giessen.de>
00024  *   Julien Lafon <julien.lafon@gmail.com>
00025  *
00026  * Alternatively, the contents of this file may be used under the terms of
00027  * either of the GNU General Public License Version 2 or later (the "GPL"),
00028  * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
00029  * in which case the provisions of the GPL or the LGPL are applicable instead
00030  * of those above. If you wish to allow use of your version of this file only
00031  * under the terms of either the GPL or the LGPL, and not to allow others to
00032  * use your version of this file under the terms of the MPL, indicate your
00033  * decision by deleting the provisions above and replace them with the notice
00034  * and other provisions required by the GPL or the LGPL. If you do not delete
00035  * the provisions above, a recipient may use your version of this file under
00036  * the terms of any one of the MPL, the GPL or the LGPL.
00037  *
00038  * ***** END LICENSE BLOCK ***** */
00039 
00040 #ifndef nsIDeviceContextSpecXP_h___
00041 #define nsIDeviceContextSpecXP_h___
00042 
00043 #include "nsISupports.h"
00044 
00045 /* UUID=12ab7845-a341-41ba-bc12-6025e0b11e0e */
00046 #define NS_IDEVICE_CONTEXT_SPEC_XP_IID { 0x12ab7845, 0xa341, 0x41ba, { 0x60, 0x25, 0xe0, 0xb1, 0x1e, 0x0e } }
00047 
00048 class nsIDeviceContextSpecXp : public nsISupports
00049 {
00050 
00051 public:
00052   NS_DEFINE_STATIC_IID_ACCESSOR(NS_IDEVICE_CONTEXT_SPEC_XP_IID);
00053 
00054   /*
00055    * If PR_TRUE, print to printer  
00056    * @update 
00057    * @param aToPrinter --  
00058    * @return 
00059    **/
00060    NS_IMETHOD GetToPrinter( PRBool &aToPrinter ) = 0; 
00061 
00062   /*
00063    * If PR_TRUE, first page first 
00064    * @update 
00065    * @param aFpf -- 
00066    * @return 
00067    **/
00068    NS_IMETHOD GetFirstPageFirst (  PRBool &aFpf ) = 0;     
00069 
00070   /*
00071    * If PR_TRUE, print grayscale 
00072    * @update 
00073    * @param aGrayscale --
00074    * @return 
00075    **/
00076    NS_IMETHOD GetGrayscale(  PRBool &aGrayscale ) = 0;   
00077 
00078   /*
00079    * Top margin 
00080    * @update 
00081    * @param aValue --
00082    * @return 
00083    **/
00084    NS_IMETHOD GetTopMargin (  float &aValue ) = 0; 
00085 
00086   /*
00087    * Bottom margin 
00088    * @update 
00089    * @param aValue --
00090    * @return 
00091    **/
00092    NS_IMETHOD GetBottomMargin (  float &aValue ) = 0; 
00093 
00094   /*
00095    * Left margin 
00096    * @update 
00097    * @param aValue --
00098    * @return 
00099    **/
00100    NS_IMETHOD GetLeftMargin (  float &aValue ) = 0; 
00101 
00102   /*
00103    * Right margin 
00104    * @update 
00105    * @param aValue --
00106    * @return 
00107    **/
00108    NS_IMETHOD GetRightMargin (  float &aValue ) = 0; 
00109 
00110   /*
00111    * Printer name e.g., myprinter or myprinter@myxprt:5 
00112    * @update 
00113    * @param aPrinter --
00114    * @return 
00115    **/
00116    NS_IMETHOD GetPrinterName ( const char **aPrinter ) = 0;   
00117 
00118   /*
00119    * If PR_TRUE, user chose Landscape
00120    * @update 
00121    * @param aLandscape
00122    * @return 
00123    **/
00124    NS_IMETHOD GetLandscape ( PRBool &aLandscape ) = 0;   
00125 
00126   /*
00127    * If toPrinter = PR_FALSE, dest file 
00128    * @update 
00129    * @param aPath --
00130    * @return 
00131    **/
00132    NS_IMETHOD GetPath ( const char **aPath ) = 0;    
00133 
00134   /*
00135    * If PR_TRUE, user cancelled 
00136    * @update 
00137    * @param aCancel -- 
00138    * @return 
00139    **/
00140    NS_IMETHOD GetUserCancelled(  PRBool &aCancel ) = 0;
00141    
00142   /*
00143    * Paper name e.g., "din-a4" or "manual/din-a4"
00144    * @update 
00145    * @param aPaperName --
00146    * @return 
00147    **/
00148    NS_IMETHOD GetPaperName ( const char **aPaperName ) = 0;   
00149 
00150   /*
00151    * Plex name e.g., "simplex", "duplex", "tumble" or any 
00152    * driver/printer-specific custom value
00153    * @update 
00154    * @param aPlexName --
00155    * @return 
00156    **/
00157    NS_IMETHOD GetPlexName ( const char **aPlexName ) = 0;   
00158 
00159   /*
00160    * Resolution/quality name e.g., "600", "600x300", "high-res",
00161    * "med-res"
00162    * driver/printer-specific custom value
00163    * @update 
00164    * @param aResolutionName --
00165    * @return 
00166    **/
00167    NS_IMETHOD GetResolutionName ( const char **aResolutionName ) = 0;   
00168    
00169   /*
00170    * Colorspace name e.g., "TrueColor", "Grayscale/10bit", "b/w",
00171    * "CYMK"
00172    * driver/printer-specific custom value
00173    * @update 
00174    * @param aColorspace --
00175    * @return 
00176    **/
00177    NS_IMETHOD GetColorspace ( const char **aColorspace ) = 0;   
00178 
00179   /*
00180    * If PR_TRUE, enable font download to printer
00181    * @update 
00182    * @param aDownloadFonts --
00183    * @return 
00184    **/
00185    NS_IMETHOD GetDownloadFonts( PRBool &aDownloadFonts ) = 0;   
00186 
00187   /*
00188    * Return number of copies to print
00189    * @update 
00190    * @param aCopies
00191    * @return 
00192    **/   
00193    NS_IMETHOD GetCopies ( int &aCopies ) = 0;
00194 };
00195 
00196 #endif /* !nsIDeviceContextSpecXP_h___ */
00197