xref: /haiku/src/add-ons/print/drivers/gutenprint/GPCapabilities.h (revision 83b1a68c52ba3e0e8796282759f694b7fdddf06d)
1 /*
2 * Copyright 1999-2000 Y.Takagi. All Rights Reserved.
3 *
4 * Copyright 2010, Haiku. All rights reserved.
5 * Distributed under the terms of the MIT License.
6 *
7 * Authors:
8 *		Michael Pfeiffer
9 *
10 */
11 #ifndef GP_CAPABILITIES_H
12 #define GP_CAPABILITIES_H
13 
14 
15 #include "PrinterCap.h"
16 
17 #include "GPArray.h"
18 
19 #include <map>
20 
21 class GPCapabilityExtractor;
22 
23 class GPCapabilities : public PrinterCap {
24 public:
25 					GPCapabilities(const PrinterData* printer_data);
26 					~GPCapabilities();
27 
28 	virtual	int		CountCap(CapID) const;
29 	virtual	bool	Supports(CapID) const;
30 	virtual	const	BaseCap **GetCaps(CapID) const;
31 
32 private:
33 	void			InitCapabilitiesFromGutenprint();
34 	const GPArray<struct BaseCap>*
35 					DriverSpecificCapabilities(int32 category) const;
36 
37 	GPArray<struct BaseCap>	fPageSizes;
38 	GPArray<struct BaseCap>	fResolutions;
39 	GPArray<struct BaseCap>	fInputSlots;
40 	GPArray<struct BaseCap>	fPrintingModes;
41 
42 	GPArray<struct BaseCap> fDriverSpecificCategories;
43 
44 	typedef map<int32, GPArray<struct BaseCap> > DriverSpecificCapabilitiesType;
45 	DriverSpecificCapabilitiesType fDriverSpecificCapabilities;
46 
47 	friend class GPCapabilityExtractor;
48 };
49 
50 
51 #endif
52