Aspose.Tasks for C++
PageSettings.h
1 #pragma once
2 //-----------------------------------------------------------------------
3 // <copyright file="PageSettings.cs" company="Aspose Pty Ltd">
4 // Copyright (c) 2002-2024 Aspose Pty Ltd. All Rights Reserved.
5 // </copyright>
6 //-----------------------------------------------------------------------
7 
8 #include <system/object.h>
9 #include <cstdint>
10 
11 #include "aspose.tasks.cpp/aspose_tasks_api_defs.h"
12 
13 namespace Aspose
14 {
15 namespace Tasks
16 {
17 namespace Visualization
18 {
19 template <typename> class ApsBaseChartBuilder;
20 enum class PrinterPaperSize;
21 } // namespace Visualization
22 } // namespace Tasks
23 } // namespace Aspose
24 
25 namespace Aspose {
26 
27 namespace Tasks {
28 
29 namespace Visualization {
30 
31 /// <summary>
32 /// Represents printing settings for a page of project view.
33 /// </summary>
34 class ASPOSE_TASKS_SHARED_CLASS PageSettings : public System::Object
35 {
36  typedef PageSettings ThisType;
37  typedef System::Object BaseType;
38 
39  typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
40  ASPOSE_TASKS_SHARED_RTTI_INFO_DECL();
41 
42  template<typename FT0> friend class Aspose::Tasks::Visualization::ApsBaseChartBuilder;
43 
44 public:
45 
46  /// <summary>
47  /// Gets a value indicating whether the page orientation is portrait; returns false if the page orientation is landscape.
48  /// </summary>
49  /// <remarks>Is applicable during rendering when SaveOptions.PageSize == Visualization.PageSize.DefinedInView.</remarks>
50  ASPOSE_TASKS_SHARED_API bool get_IsPortrait() const;
51  /// <summary>
52  /// Sets a value indicating whether the page orientation is portrait; returns false if the page orientation is landscape.
53  /// </summary>
54  /// <remarks>Is applicable during rendering when SaveOptions.PageSize == Visualization.PageSize.DefinedInView.</remarks>
55  ASPOSE_TASKS_SHARED_API void set_IsPortrait(bool value);
56  /// <summary>
57  /// Gets a value indicating whether to adjust printing to the specified percentage (<see cref="PercentOfNormalSize"></see>) of normal size.
58  /// </summary>
59  /// <remarks>Is not effective when project is rendered in HTML format.</remarks>
60  ASPOSE_TASKS_SHARED_API bool get_AdjustToPercentOfNormalSize() const;
61  /// <summary>
62  /// Sets a value indicating whether to adjust printing to the specified percentage (<see cref="PercentOfNormalSize"></see>) of normal size.
63  /// </summary>
64  /// <remarks>Is not effective when project is rendered in HTML format.</remarks>
65  ASPOSE_TASKS_SHARED_API void set_AdjustToPercentOfNormalSize(bool value);
66  /// <summary>
67  /// Gets a percentage of normal size to adjust printing to.
68  /// </summary>
69  ASPOSE_TASKS_SHARED_API int32_t get_PercentOfNormalSize() const;
70  /// <summary>
71  /// Sets a percentage of normal size to adjust printing to.
72  /// </summary>
73  ASPOSE_TASKS_SHARED_API void set_PercentOfNormalSize(int32_t value);
74  /// <summary>
75  /// Gets a number of pages in width to be printed.
76  /// </summary>
77  ASPOSE_TASKS_SHARED_API int32_t get_PagesInWidth() const;
78  /// <summary>
79  /// Sets a number of pages in width to be printed.
80  /// </summary>
81  ASPOSE_TASKS_SHARED_API void set_PagesInWidth(int32_t value);
82  /// <summary>
83  /// Gets a number of pages in height to be printed.
84  /// </summary>
85  ASPOSE_TASKS_SHARED_API int32_t get_PagesInHeight() const;
86  /// <summary>
87  /// Sets a number of pages in height to be printed.
88  /// </summary>
89  ASPOSE_TASKS_SHARED_API void set_PagesInHeight(int32_t value);
90  /// <summary>
91  /// Gets a paper size. Can be one of the values of the <see cref="PrinterPaperSize"></see> enumeration.
92  /// </summary>
93  ASPOSE_TASKS_SHARED_API PrinterPaperSize get_PaperSize();
94  /// <summary>
95  /// Sets a paper size. Can be one of the values of the <see cref="PrinterPaperSize"></see> enumeration.
96  /// </summary>
97  ASPOSE_TASKS_SHARED_API void set_PaperSize(PrinterPaperSize value);
98  /// <summary>
99  /// Gets an integer representing one of the PrinterPaperSize values or a custom page size id.
100  /// This value can be used to get PaperSize from OS settings <seealso cref="T:System::Drawing::Printing::PrinterSettings::PaperSizes"></seealso>.
101  /// </summary>
102  ASPOSE_TASKS_SHARED_API int32_t get_PaperSizeId() const;
103  /// <summary>
104  /// Sets an integer representing one of the PrinterPaperSize values or a custom page size id.
105  /// This value can be used to get PaperSize from OS settings <seealso cref="T:System::Drawing::Printing::PrinterSettings::PaperSizes"></seealso>.
106  /// </summary>
107  ASPOSE_TASKS_SHARED_API void set_PaperSizeId(int32_t value);
108  /// <summary>
109  /// Gets a first page number for printing.
110  /// </summary>
111  ASPOSE_TASKS_SHARED_API int16_t get_FirstPageNumber() const;
112  /// <summary>
113  /// Sets a first page number for printing.
114  /// </summary>
115  ASPOSE_TASKS_SHARED_API void set_FirstPageNumber(int16_t value);
116 
117  /// <summary>
118  /// Initializes a new instance of the <see cref="PageSettings"></see> class.
119  /// Represents printing settings for a page of project view.
120  /// </summary>
121  ASPOSE_TASKS_SHARED_API PageSettings();
122 
123 protected:
124 
125  ASPOSE_TASKS_SHARED_API bool get_IsCustomPageSize();
126 
127 private:
128 
129  bool pr_IsPortrait;
130  bool pr_AdjustToPercentOfNormalSize;
131  int32_t pr_PercentOfNormalSize;
132  int32_t pr_PagesInWidth;
133  int32_t pr_PagesInHeight;
134  int32_t pr_PaperSizeId;
135  int16_t pr_FirstPageNumber;
136 
137 };
138 
139 } // namespace Visualization
140 } // namespace Tasks
141 } // namespace Aspose
142 
143 
Represents printing settings for a page of project view.
Definition: PageSettings.h:34