Bug 1858509 add thread-safety annotations around MediaSourceDemuxer::mMonitor r=alwu
[gecko.git] / widget / nsIPrinter.idl
blobd95671f681d6fd411255e68b0b0689eb7e65c601
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #include "nsIPaper.idl"
7 #include "nsIPrintSettings.idl"
8 #include "nsISupports.idl"
10 [scriptable, uuid(855ae9dd-62a4-64aa-9c60-b1078ff028f1)]
11 interface nsIPrinterInfo : nsISupports
13 /**
14 * An array of nsIPaper instances that represents the available paper sizes.
16 readonly attribute Array<nsIPaper> paperList;
17 /**
18 * nsIPrintSettings object containing the default settings for a printer.
20 readonly attribute nsIPrintSettings defaultSettings;
23 [scriptable, uuid(d2dde9bb-df86-469c-bfcc-fd95a44b1db8)]
24 interface nsIPrinter : nsISupports
26 /**
27 * The name of the printer.
29 readonly attribute AString name;
31 /**
32 * The system name of the printer.
34 * This may be faster for lookup in nsIPrinterList functions, but will only
35 * work for functions that will accept the system name.
37 readonly attribute AString systemName;
39 /**
40 * Returns a Promise that resolves to a nsIPrinterInfo.
41 * This will contain the default printer settings, and the list of paper
42 * sizes supported by the printer.
44 [implicit_jscontext]
45 readonly attribute Promise printerInfo;
47 /**
48 * Returns a Promise that resolves to a new settings object that contains all
49 * of the settings from aSettingsToCopyFrom that are valid for this printer.
50 * Any settings that are not valid for the printer are set to default/fallback
51 * values.
53 [implicit_jscontext]
54 Promise copyFromWithValidation(in nsIPrintSettings aSettingsToCopyFrom);
56 /**
57 * Returns a Promise that resolves to true or false to indicate whether this
58 * printer supports duplex printing.
60 [implicit_jscontext]
61 readonly attribute Promise supportsDuplex;
63 /**
64 * Returns a Promise that resolves to true or false to indicate whether this
65 * printer supports color printing.
67 [implicit_jscontext]
68 readonly attribute Promise supportsColor;
70 /**
71 * Returns a Promise that resolves to true or false to indicate whether this
72 * printer supports monochrome printing.
74 [implicit_jscontext]
75 readonly attribute Promise supportsMonochrome;
77 /**
78 * Returns a Promise that resolves to true or false to indicate whether this
79 * printer supports collation.
81 [implicit_jscontext]
82 readonly attribute Promise supportsCollation;