2006-02-07 04:13:47 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2006-02-07 04:13:47 +03:00
|
|
|
|
|
|
|
#include "nsISupports.idl"
|
|
|
|
|
|
|
|
%{ C++
|
|
|
|
#include "windows.h"
|
|
|
|
%}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Native types
|
|
|
|
*/
|
2008-10-22 04:54:26 +04:00
|
|
|
[ptr] native nsDevMode(DEVMODEW);
|
2016-01-22 19:05:19 +03:00
|
|
|
native nsHdc(HDC);
|
2006-02-07 04:13:47 +03:00
|
|
|
|
|
|
|
/**
|
2019-04-21 04:47:00 +03:00
|
|
|
* Simplified PrintSettings for Windows interface
|
2006-02-07 04:13:47 +03:00
|
|
|
*/
|
2019-05-14 11:19:10 +03:00
|
|
|
[uuid(c63eed41-6ac5-459e-8a64-033eb9ad770a)]
|
2006-02-07 04:13:47 +03:00
|
|
|
interface nsIPrintSettingsWin : nsISupports
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Data Members
|
|
|
|
*
|
2019-04-21 04:47:00 +03:00
|
|
|
* Each of these data members make a copy
|
|
|
|
* of the contents. If you get the value,
|
2006-02-07 04:13:47 +03:00
|
|
|
* you own the memory.
|
|
|
|
*
|
|
|
|
* The following three pieces of data are needed
|
2019-04-21 04:47:00 +03:00
|
|
|
* to create a DC for printing. These are typcially
|
2006-02-07 04:13:47 +03:00
|
|
|
* gotten via the PrintDLG call ro can be obtained
|
|
|
|
* via the "m_pd" data member of the CPrintDialog
|
|
|
|
* in MFC.
|
|
|
|
*/
|
2017-10-09 02:08:09 +03:00
|
|
|
[noscript] attribute AString deviceName;
|
|
|
|
[noscript] attribute AString driverName;
|
2006-02-07 04:13:47 +03:00
|
|
|
|
|
|
|
[noscript] attribute nsDevMode devMode;
|
|
|
|
|
2016-01-22 19:05:19 +03:00
|
|
|
/**
|
|
|
|
* Copy relevant print settings from native Windows device.
|
|
|
|
*
|
|
|
|
* @param hdc HDC to copy from
|
2016-01-12 20:40:07 +03:00
|
|
|
* @param devMode DEVMODE to copy from
|
2016-01-22 19:05:19 +03:00
|
|
|
*/
|
2016-01-12 20:40:07 +03:00
|
|
|
[notxpcom] void copyFromNative(in nsHdc hdc, in nsDevMode devMode);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Copy relevant print settings to native windows structures.
|
|
|
|
*
|
|
|
|
* @param devMode DEVMODE to be populated.
|
|
|
|
*/
|
|
|
|
[notxpcom] void copyToNative(in nsDevMode devMode);
|
2006-02-07 04:13:47 +03:00
|
|
|
};
|