• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright (c) 2022 The Chromium Embedded Framework Authors. All rights
2 // reserved. Use of this source code is governed by a BSD-style license that
3 // can be found in the LICENSE file.
4 //
5 // ---------------------------------------------------------------------------
6 //
7 // This file was generated by the CEF translator tool. If making changes by
8 // hand only do so within the body of existing method and function
9 // implementations. See the translator.README.txt file in the tools directory
10 // for more information.
11 //
12 // $hash=e74e75adf68001ef29e441fa1bbac27e3aa5c3c1$
13 //
14 
15 #ifndef CEF_LIBCEF_DLL_CTOCPP_PRINT_SETTINGS_CTOCPP_H_
16 #define CEF_LIBCEF_DLL_CTOCPP_PRINT_SETTINGS_CTOCPP_H_
17 #pragma once
18 
19 #if !defined(WRAPPING_CEF_SHARED)
20 #error This file can be included wrapper-side only
21 #endif
22 
23 #include "include/capi/cef_print_settings_capi.h"
24 #include "include/cef_print_settings.h"
25 #include "libcef_dll/ctocpp/ctocpp_ref_counted.h"
26 
27 // Wrap a C structure with a C++ class.
28 // This class may be instantiated and accessed wrapper-side only.
29 class CefPrintSettingsCToCpp
30     : public CefCToCppRefCounted<CefPrintSettingsCToCpp,
31                                  CefPrintSettings,
32                                  cef_print_settings_t> {
33  public:
34   CefPrintSettingsCToCpp();
35   virtual ~CefPrintSettingsCToCpp();
36 
37   // CefPrintSettings methods.
38   bool IsValid() override;
39   bool IsReadOnly() override;
40   void SetOrientation(bool landscape) override;
41   bool IsLandscape() override;
42   void SetPrinterPrintableArea(const CefSize& physical_size_device_units,
43                                const CefRect& printable_area_device_units,
44                                bool landscape_needs_flip) override;
45   void SetDeviceName(const CefString& name) override;
46   CefString GetDeviceName() override;
47   void SetDPI(int dpi) override;
48   int GetDPI() override;
49   void SetPageRanges(const PageRangeList& ranges) override;
50   size_t GetPageRangesCount() override;
51   void GetPageRanges(PageRangeList& ranges) override;
52   void SetSelectionOnly(bool selection_only) override;
53   bool IsSelectionOnly() override;
54   void SetCollate(bool collate) override;
55   bool WillCollate() override;
56   void SetColorModel(ColorModel model) override;
57   ColorModel GetColorModel() override;
58   void SetCopies(int copies) override;
59   int GetCopies() override;
60   void SetDuplexMode(DuplexMode mode) override;
61   DuplexMode GetDuplexMode() override;
62 };
63 
64 #endif  // CEF_LIBCEF_DLL_CTOCPP_PRINT_SETTINGS_CTOCPP_H_
65