mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-28 15:23:51 +00:00
5dbd0055be
This also renames nsIPrinterList.getNamedPrinter to nsIPrinter.getPrinterByName for consistency. This is cheaper to lookup on platforms that use CUPS and do not show the Unix name for printers. This only applies to OS X at the present. Differential Revision: https://phabricator.services.mozilla.com/D90201
69 lines
2.0 KiB
Plaintext
69 lines
2.0 KiB
Plaintext
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
/* 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/. */
|
|
|
|
#include "nsIPaper.idl"
|
|
#include "nsISupports.idl"
|
|
|
|
[scriptable, uuid(d2dde9bb-df86-469c-bfcc-fd95a44b1db8)]
|
|
interface nsIPrinter : nsISupports
|
|
{
|
|
/**
|
|
* The name of the printer.
|
|
*/
|
|
readonly attribute AString name;
|
|
|
|
/**
|
|
* The system name of the printer.
|
|
*
|
|
* This may be faster for lookup in nsIPrinterList functions, but will only
|
|
* work for functions that will accept the system name.
|
|
*/
|
|
readonly attribute AString systemName;
|
|
|
|
/**
|
|
* Creates a Promise that will resolve to an nsIPrintSettings object containing
|
|
* the default settings for this printer. For convenience, a new, mutable
|
|
* nsIPrintSettings object is created for each call.
|
|
*/
|
|
[implicit_jscontext]
|
|
Promise createDefaultSettings();
|
|
|
|
/**
|
|
* Returns a Promise that resolves to an array of
|
|
* nsIPaper instances with the list of available paper
|
|
* sizes.
|
|
*/
|
|
[implicit_jscontext]
|
|
readonly attribute Promise paperList;
|
|
|
|
/**
|
|
* Returns a Promise that resolves to true or false to indicate whether this
|
|
* printer supports duplex printing.
|
|
*/
|
|
[implicit_jscontext]
|
|
readonly attribute Promise supportsDuplex;
|
|
|
|
/**
|
|
* Returns a Promise that resolves to true or false to indicate whether this
|
|
* printer supports color printing.
|
|
*/
|
|
[implicit_jscontext]
|
|
readonly attribute Promise supportsColor;
|
|
|
|
/**
|
|
* Returns a Promise that resolves to true or false to indicate whether this
|
|
* printer supports monochrome printing.
|
|
*/
|
|
[implicit_jscontext]
|
|
readonly attribute Promise supportsMonochrome;
|
|
|
|
/**
|
|
* Returns a Promise that resolves to true or false to indicate whether this
|
|
* printer supports collation.
|
|
*/
|
|
[implicit_jscontext]
|
|
readonly attribute Promise supportsCollation;
|
|
};
|