aspose_slides_cloud 24.2.0 → 24.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +3 -3
- data/README.md +13 -0
- data/lib/aspose_slides_cloud/api/slides_api.rb +100 -22
- data/lib/aspose_slides_cloud/api/slides_async_api.rb +8 -8
- data/lib/aspose_slides_cloud/models/audio_frame.rb +2 -1
- data/lib/aspose_slides_cloud/models/chart.rb +2 -1
- data/lib/aspose_slides_cloud/models/connector.rb +2 -1
- data/lib/aspose_slides_cloud/models/effect.rb +23 -1
- data/lib/aspose_slides_cloud/models/export_format.rb +1 -0
- data/lib/aspose_slides_cloud/models/geometry_shape.rb +2 -1
- data/lib/aspose_slides_cloud/models/graphical_object.rb +2 -1
- data/lib/aspose_slides_cloud/models/group_shape.rb +2 -1
- data/lib/aspose_slides_cloud/models/handout_layouting_options.rb +133 -0
- data/lib/aspose_slides_cloud/models/html5_export_options.rb +22 -2
- data/lib/aspose_slides_cloud/models/html_export_options.rb +8 -72
- data/lib/aspose_slides_cloud/models/image_export_options.rb +12 -66
- data/lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb +155 -0
- data/lib/aspose_slides_cloud/models/ole_object_frame.rb +2 -1
- data/lib/aspose_slides_cloud/models/pdf_export_options.rb +8 -72
- data/lib/aspose_slides_cloud/models/picture_frame.rb +2 -1
- data/lib/aspose_slides_cloud/models/save.rb +2 -2
- data/lib/aspose_slides_cloud/models/save_slide.rb +2 -2
- data/lib/aspose_slides_cloud/models/section_zoom_frame.rb +2 -1
- data/lib/aspose_slides_cloud/models/shape.rb +2 -1
- data/lib/aspose_slides_cloud/models/shape_base.rb +11 -1
- data/lib/aspose_slides_cloud/models/slide_export_format.rb +1 -0
- data/lib/aspose_slides_cloud/models/slide_show_properties.rb +11 -1
- data/lib/aspose_slides_cloud/models/slides_layout_options.rb +102 -0
- data/lib/aspose_slides_cloud/models/smart_art.rb +2 -1
- data/lib/aspose_slides_cloud/models/smart_art_shape.rb +2 -1
- data/lib/aspose_slides_cloud/models/summary_zoom_frame.rb +2 -1
- data/lib/aspose_slides_cloud/models/summary_zoom_section.rb +2 -1
- data/lib/aspose_slides_cloud/models/table.rb +2 -1
- data/lib/aspose_slides_cloud/models/tiff_export_options.rb +23 -65
- data/lib/aspose_slides_cloud/models/video_frame.rb +2 -1
- data/lib/aspose_slides_cloud/models/zoom_frame.rb +2 -1
- data/lib/aspose_slides_cloud/models/zoom_object.rb +2 -1
- data/lib/aspose_slides_cloud/type_registry.rb +5 -0
- data/lib/aspose_slides_cloud/version.rb +1 -1
- data/lib/aspose_slides_cloud.rb +3 -0
- data/spec/api/slides_api_spec.rb +175 -0
- data/spec/use_cases/image_spec.rb +27 -0
- data/testRules.json +2 -0
- metadata +5 -2
@@ -0,0 +1,133 @@
|
|
1
|
+
=begin
|
2
|
+
Copyright (c) 2019 Aspose Pty Ltd
|
3
|
+
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
|
+
of this software and associated documentation files (the "Software"), to deal
|
6
|
+
in the Software without restriction, including without limitation the rights
|
7
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
8
|
+
copies of the Software, and to permit persons to whom the Software is
|
9
|
+
furnished to do so, subject to the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be included in all
|
12
|
+
copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
15
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
16
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
17
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
18
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
19
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
20
|
+
SOFTWARE.
|
21
|
+
=end
|
22
|
+
|
23
|
+
require 'date'
|
24
|
+
|
25
|
+
module AsposeSlidesCloud
|
26
|
+
# Handout layouting options
|
27
|
+
class HandoutLayoutingOptions < SlidesLayoutOptions
|
28
|
+
# Specified how many pages and in what sequence will be placed on the page.
|
29
|
+
attr_accessor :handout
|
30
|
+
|
31
|
+
# True to print the displayed slide numbers.
|
32
|
+
attr_accessor :print_slide_numbers
|
33
|
+
|
34
|
+
# True to display comments on slide.
|
35
|
+
attr_accessor :print_comments
|
36
|
+
|
37
|
+
# True to draw frames around the displayed slides.
|
38
|
+
attr_accessor :print_frame_slide
|
39
|
+
|
40
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
41
|
+
def self.attribute_map
|
42
|
+
super.merge({
|
43
|
+
:'handout' => :'Handout',
|
44
|
+
:'print_slide_numbers' => :'PrintSlideNumbers',
|
45
|
+
:'print_comments' => :'PrintComments',
|
46
|
+
:'print_frame_slide' => :'PrintFrameSlide',
|
47
|
+
})
|
48
|
+
end
|
49
|
+
|
50
|
+
# Attribute type mapping.
|
51
|
+
def self.swagger_types
|
52
|
+
super.merge({
|
53
|
+
:'handout' => :'String',
|
54
|
+
:'print_slide_numbers' => :'BOOLEAN',
|
55
|
+
:'print_comments' => :'BOOLEAN',
|
56
|
+
:'print_frame_slide' => :'BOOLEAN',
|
57
|
+
})
|
58
|
+
end
|
59
|
+
|
60
|
+
# Initializes the object
|
61
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
62
|
+
def initialize(attributes = {})
|
63
|
+
super
|
64
|
+
|
65
|
+
if attributes.has_key?(:'Handout')
|
66
|
+
self.handout = attributes[:'Handout']
|
67
|
+
end
|
68
|
+
|
69
|
+
if attributes.has_key?(:'PrintSlideNumbers')
|
70
|
+
self.print_slide_numbers = attributes[:'PrintSlideNumbers']
|
71
|
+
end
|
72
|
+
|
73
|
+
if attributes.has_key?(:'PrintComments')
|
74
|
+
self.print_comments = attributes[:'PrintComments']
|
75
|
+
end
|
76
|
+
|
77
|
+
if attributes.has_key?(:'PrintFrameSlide')
|
78
|
+
self.print_frame_slide = attributes[:'PrintFrameSlide']
|
79
|
+
end
|
80
|
+
self.layout_type = 'Handout'
|
81
|
+
end
|
82
|
+
|
83
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
84
|
+
# @return Array for valid properties with the reasons
|
85
|
+
def list_invalid_properties
|
86
|
+
invalid_properties = super
|
87
|
+
invalid_properties
|
88
|
+
end
|
89
|
+
|
90
|
+
# Check to see if the all the properties in the model are valid
|
91
|
+
# @return true if the model is valid
|
92
|
+
def valid?
|
93
|
+
return false if !super
|
94
|
+
handout_validator = EnumAttributeValidator.new('String', ['Handouts1', 'Handouts2', 'Handouts3', 'Handouts4Horizontal', 'Handouts4Vertical', 'Handouts6Horizontal', 'Handouts6Vertical', 'Handouts9Horizontal', 'Handouts9Vertical'])
|
95
|
+
return false unless handout_validator.valid?(@handout)
|
96
|
+
true
|
97
|
+
end
|
98
|
+
|
99
|
+
# Custom attribute writer method checking allowed values (enum).
|
100
|
+
# @param [Object] handout Object to be assigned
|
101
|
+
def handout=(handout)
|
102
|
+
validator = EnumAttributeValidator.new('String', ['Handouts1', 'Handouts2', 'Handouts3', 'Handouts4Horizontal', 'Handouts4Vertical', 'Handouts6Horizontal', 'Handouts6Vertical', 'Handouts9Horizontal', 'Handouts9Vertical'])
|
103
|
+
unless validator.valid?(handout)
|
104
|
+
fail ArgumentError, 'invalid value for "handout", must be one of #{validator.allowable_values}.'
|
105
|
+
end
|
106
|
+
@handout = handout
|
107
|
+
end
|
108
|
+
|
109
|
+
# Checks equality by comparing each attribute.
|
110
|
+
# @param [Object] Object to be compared
|
111
|
+
def ==(o)
|
112
|
+
return true if self.equal?(o)
|
113
|
+
self.class == o.class &&
|
114
|
+
layout_type == o.layout_type &&
|
115
|
+
handout == o.handout &&
|
116
|
+
print_slide_numbers == o.print_slide_numbers &&
|
117
|
+
print_comments == o.print_comments &&
|
118
|
+
print_frame_slide == o.print_frame_slide
|
119
|
+
end
|
120
|
+
|
121
|
+
# @see the `==` method
|
122
|
+
# @param [Object] Object to be compared
|
123
|
+
def eql?(o)
|
124
|
+
self == o
|
125
|
+
end
|
126
|
+
|
127
|
+
# Calculates hash code according to all attributes.
|
128
|
+
# @return [Fixnum] Hash code
|
129
|
+
def hash
|
130
|
+
[layout_type, handout, print_slide_numbers, print_comments, print_frame_slide].hash
|
131
|
+
end
|
132
|
+
end
|
133
|
+
end
|
@@ -31,11 +31,19 @@ module AsposeSlidesCloud
|
|
31
31
|
# Gets or sets shapes animation option.
|
32
32
|
attr_accessor :animate_shapes
|
33
33
|
|
34
|
+
# Gets or sets embed images option.
|
35
|
+
attr_accessor :embed_images
|
36
|
+
|
37
|
+
# Slides layouting options
|
38
|
+
attr_accessor :notes_comments_layouting
|
39
|
+
|
34
40
|
# Attribute mapping from ruby-style variable name to JSON key.
|
35
41
|
def self.attribute_map
|
36
42
|
super.merge({
|
37
43
|
:'animate_transitions' => :'AnimateTransitions',
|
38
44
|
:'animate_shapes' => :'AnimateShapes',
|
45
|
+
:'embed_images' => :'EmbedImages',
|
46
|
+
:'notes_comments_layouting' => :'NotesCommentsLayouting',
|
39
47
|
})
|
40
48
|
end
|
41
49
|
|
@@ -44,6 +52,8 @@ module AsposeSlidesCloud
|
|
44
52
|
super.merge({
|
45
53
|
:'animate_transitions' => :'BOOLEAN',
|
46
54
|
:'animate_shapes' => :'BOOLEAN',
|
55
|
+
:'embed_images' => :'BOOLEAN',
|
56
|
+
:'notes_comments_layouting' => :'NotesCommentsLayoutingOptions',
|
47
57
|
})
|
48
58
|
end
|
49
59
|
|
@@ -59,6 +69,14 @@ module AsposeSlidesCloud
|
|
59
69
|
if attributes.has_key?(:'AnimateShapes')
|
60
70
|
self.animate_shapes = attributes[:'AnimateShapes']
|
61
71
|
end
|
72
|
+
|
73
|
+
if attributes.has_key?(:'EmbedImages')
|
74
|
+
self.embed_images = attributes[:'EmbedImages']
|
75
|
+
end
|
76
|
+
|
77
|
+
if attributes.has_key?(:'NotesCommentsLayouting')
|
78
|
+
self.notes_comments_layouting = attributes[:'NotesCommentsLayouting']
|
79
|
+
end
|
62
80
|
self.format = 'html5'
|
63
81
|
end
|
64
82
|
|
@@ -86,7 +104,9 @@ module AsposeSlidesCloud
|
|
86
104
|
font_subst_rules == o.font_subst_rules &&
|
87
105
|
format == o.format &&
|
88
106
|
animate_transitions == o.animate_transitions &&
|
89
|
-
animate_shapes == o.animate_shapes
|
107
|
+
animate_shapes == o.animate_shapes &&
|
108
|
+
embed_images == o.embed_images &&
|
109
|
+
notes_comments_layouting == o.notes_comments_layouting
|
90
110
|
end
|
91
111
|
|
92
112
|
# @see the `==` method
|
@@ -98,7 +118,7 @@ module AsposeSlidesCloud
|
|
98
118
|
# Calculates hash code according to all attributes.
|
99
119
|
# @return [Fixnum] Hash code
|
100
120
|
def hash
|
101
|
-
[default_regular_font, font_fallback_rules, font_subst_rules, format, animate_transitions, animate_shapes].hash
|
121
|
+
[default_regular_font, font_fallback_rules, font_subst_rules, format, animate_transitions, animate_shapes, embed_images, notes_comments_layouting].hash
|
102
122
|
end
|
103
123
|
end
|
104
124
|
end
|
@@ -46,20 +46,8 @@ module AsposeSlidesCloud
|
|
46
46
|
# A boolean flag indicates if the cropped parts remain as part of the document. If true the cropped parts will removed, if false they will be serialized in the document (which can possible lead to a larger file)
|
47
47
|
attr_accessor :delete_pictures_cropped_areas
|
48
48
|
|
49
|
-
#
|
50
|
-
attr_accessor :
|
51
|
-
|
52
|
-
# Gets or sets the position of the comments on the page.
|
53
|
-
attr_accessor :comments_position
|
54
|
-
|
55
|
-
# Gets or sets the width of the comment output area in pixels (Applies only if comments are displayed on the right).
|
56
|
-
attr_accessor :comments_area_width
|
57
|
-
|
58
|
-
# Gets or sets the color of comments area (Applies only if comments are displayed on the right).
|
59
|
-
attr_accessor :comments_area_color
|
60
|
-
|
61
|
-
# True if comments that have no author are displayed. (Applies only if comments are displayed).
|
62
|
-
attr_accessor :show_comments_by_no_author
|
49
|
+
# Slides layouting options
|
50
|
+
attr_accessor :slides_layout_options
|
63
51
|
|
64
52
|
# Attribute mapping from ruby-style variable name to JSON key.
|
65
53
|
def self.attribute_map
|
@@ -71,11 +59,7 @@ module AsposeSlidesCloud
|
|
71
59
|
:'jpeg_quality' => :'JpegQuality',
|
72
60
|
:'pictures_compression' => :'PicturesCompression',
|
73
61
|
:'delete_pictures_cropped_areas' => :'DeletePicturesCroppedAreas',
|
74
|
-
:'
|
75
|
-
:'comments_position' => :'CommentsPosition',
|
76
|
-
:'comments_area_width' => :'CommentsAreaWidth',
|
77
|
-
:'comments_area_color' => :'CommentsAreaColor',
|
78
|
-
:'show_comments_by_no_author' => :'ShowCommentsByNoAuthor',
|
62
|
+
:'slides_layout_options' => :'SlidesLayoutOptions',
|
79
63
|
})
|
80
64
|
end
|
81
65
|
|
@@ -89,11 +73,7 @@ module AsposeSlidesCloud
|
|
89
73
|
:'jpeg_quality' => :'Integer',
|
90
74
|
:'pictures_compression' => :'String',
|
91
75
|
:'delete_pictures_cropped_areas' => :'BOOLEAN',
|
92
|
-
:'
|
93
|
-
:'comments_position' => :'String',
|
94
|
-
:'comments_area_width' => :'Integer',
|
95
|
-
:'comments_area_color' => :'String',
|
96
|
-
:'show_comments_by_no_author' => :'BOOLEAN',
|
76
|
+
:'slides_layout_options' => :'SlidesLayoutOptions',
|
97
77
|
})
|
98
78
|
end
|
99
79
|
|
@@ -130,24 +110,8 @@ module AsposeSlidesCloud
|
|
130
110
|
self.delete_pictures_cropped_areas = attributes[:'DeletePicturesCroppedAreas']
|
131
111
|
end
|
132
112
|
|
133
|
-
if attributes.has_key?(:'
|
134
|
-
self.
|
135
|
-
end
|
136
|
-
|
137
|
-
if attributes.has_key?(:'CommentsPosition')
|
138
|
-
self.comments_position = attributes[:'CommentsPosition']
|
139
|
-
end
|
140
|
-
|
141
|
-
if attributes.has_key?(:'CommentsAreaWidth')
|
142
|
-
self.comments_area_width = attributes[:'CommentsAreaWidth']
|
143
|
-
end
|
144
|
-
|
145
|
-
if attributes.has_key?(:'CommentsAreaColor')
|
146
|
-
self.comments_area_color = attributes[:'CommentsAreaColor']
|
147
|
-
end
|
148
|
-
|
149
|
-
if attributes.has_key?(:'ShowCommentsByNoAuthor')
|
150
|
-
self.show_comments_by_no_author = attributes[:'ShowCommentsByNoAuthor']
|
113
|
+
if attributes.has_key?(:'SlidesLayoutOptions')
|
114
|
+
self.slides_layout_options = attributes[:'SlidesLayoutOptions']
|
151
115
|
end
|
152
116
|
self.format = 'html'
|
153
117
|
end
|
@@ -165,10 +129,6 @@ module AsposeSlidesCloud
|
|
165
129
|
return false if !super
|
166
130
|
pictures_compression_validator = EnumAttributeValidator.new('String', ['Dpi330', 'Dpi220', 'Dpi150', 'Dpi96', 'Dpi72', 'DocumentResolution'])
|
167
131
|
return false unless pictures_compression_validator.valid?(@pictures_compression)
|
168
|
-
notes_position_validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated'])
|
169
|
-
return false unless notes_position_validator.valid?(@notes_position)
|
170
|
-
comments_position_validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right'])
|
171
|
-
return false unless comments_position_validator.valid?(@comments_position)
|
172
132
|
true
|
173
133
|
end
|
174
134
|
|
@@ -182,26 +142,6 @@ module AsposeSlidesCloud
|
|
182
142
|
@pictures_compression = pictures_compression
|
183
143
|
end
|
184
144
|
|
185
|
-
# Custom attribute writer method checking allowed values (enum).
|
186
|
-
# @param [Object] notes_position Object to be assigned
|
187
|
-
def notes_position=(notes_position)
|
188
|
-
validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated'])
|
189
|
-
unless validator.valid?(notes_position)
|
190
|
-
fail ArgumentError, 'invalid value for "notes_position", must be one of #{validator.allowable_values}.'
|
191
|
-
end
|
192
|
-
@notes_position = notes_position
|
193
|
-
end
|
194
|
-
|
195
|
-
# Custom attribute writer method checking allowed values (enum).
|
196
|
-
# @param [Object] comments_position Object to be assigned
|
197
|
-
def comments_position=(comments_position)
|
198
|
-
validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right'])
|
199
|
-
unless validator.valid?(comments_position)
|
200
|
-
fail ArgumentError, 'invalid value for "comments_position", must be one of #{validator.allowable_values}.'
|
201
|
-
end
|
202
|
-
@comments_position = comments_position
|
203
|
-
end
|
204
|
-
|
205
145
|
# Checks equality by comparing each attribute.
|
206
146
|
# @param [Object] Object to be compared
|
207
147
|
def ==(o)
|
@@ -218,11 +158,7 @@ module AsposeSlidesCloud
|
|
218
158
|
jpeg_quality == o.jpeg_quality &&
|
219
159
|
pictures_compression == o.pictures_compression &&
|
220
160
|
delete_pictures_cropped_areas == o.delete_pictures_cropped_areas &&
|
221
|
-
|
222
|
-
comments_position == o.comments_position &&
|
223
|
-
comments_area_width == o.comments_area_width &&
|
224
|
-
comments_area_color == o.comments_area_color &&
|
225
|
-
show_comments_by_no_author == o.show_comments_by_no_author
|
161
|
+
slides_layout_options == o.slides_layout_options
|
226
162
|
end
|
227
163
|
|
228
164
|
# @see the `==` method
|
@@ -234,7 +170,7 @@ module AsposeSlidesCloud
|
|
234
170
|
# Calculates hash code according to all attributes.
|
235
171
|
# @return [Fixnum] Hash code
|
236
172
|
def hash
|
237
|
-
[default_regular_font, font_fallback_rules, font_subst_rules, format, save_as_zip, sub_directory_name, show_hidden_slides, svg_responsive_layout, jpeg_quality, pictures_compression, delete_pictures_cropped_areas,
|
173
|
+
[default_regular_font, font_fallback_rules, font_subst_rules, format, save_as_zip, sub_directory_name, show_hidden_slides, svg_responsive_layout, jpeg_quality, pictures_compression, delete_pictures_cropped_areas, slides_layout_options].hash
|
238
174
|
end
|
239
175
|
end
|
240
176
|
end
|
@@ -25,40 +25,25 @@ require 'date'
|
|
25
25
|
module AsposeSlidesCloud
|
26
26
|
# Provides options that control how a presentation is saved in an image format.
|
27
27
|
class ImageExportOptions < ImageExportOptionsBase
|
28
|
-
# Gets or sets the position of the notes on the page.
|
29
|
-
attr_accessor :notes_position
|
30
|
-
|
31
|
-
# Gets or sets the position of the comments on the page.
|
32
|
-
attr_accessor :comments_position
|
33
|
-
|
34
|
-
# Gets or sets the width of the comment output area in pixels (Applies only if comments are displayed on the right).
|
35
|
-
attr_accessor :comments_area_width
|
36
|
-
|
37
|
-
# Gets or sets the color of comments area (Applies only if comments are displayed on the right).
|
38
|
-
attr_accessor :comments_area_color
|
39
|
-
|
40
28
|
# Show hidden slides. If true, hidden are exported.
|
41
29
|
attr_accessor :show_hidden_slides
|
42
30
|
|
31
|
+
# Slides layouting options
|
32
|
+
attr_accessor :slides_layout_options
|
33
|
+
|
43
34
|
# Attribute mapping from ruby-style variable name to JSON key.
|
44
35
|
def self.attribute_map
|
45
36
|
super.merge({
|
46
|
-
:'notes_position' => :'NotesPosition',
|
47
|
-
:'comments_position' => :'CommentsPosition',
|
48
|
-
:'comments_area_width' => :'CommentsAreaWidth',
|
49
|
-
:'comments_area_color' => :'CommentsAreaColor',
|
50
37
|
:'show_hidden_slides' => :'ShowHiddenSlides',
|
38
|
+
:'slides_layout_options' => :'SlidesLayoutOptions',
|
51
39
|
})
|
52
40
|
end
|
53
41
|
|
54
42
|
# Attribute type mapping.
|
55
43
|
def self.swagger_types
|
56
44
|
super.merge({
|
57
|
-
:'notes_position' => :'String',
|
58
|
-
:'comments_position' => :'String',
|
59
|
-
:'comments_area_width' => :'Integer',
|
60
|
-
:'comments_area_color' => :'String',
|
61
45
|
:'show_hidden_slides' => :'BOOLEAN',
|
46
|
+
:'slides_layout_options' => :'SlidesLayoutOptions',
|
62
47
|
})
|
63
48
|
end
|
64
49
|
|
@@ -67,25 +52,13 @@ module AsposeSlidesCloud
|
|
67
52
|
def initialize(attributes = {})
|
68
53
|
super
|
69
54
|
|
70
|
-
if attributes.has_key?(:'NotesPosition')
|
71
|
-
self.notes_position = attributes[:'NotesPosition']
|
72
|
-
end
|
73
|
-
|
74
|
-
if attributes.has_key?(:'CommentsPosition')
|
75
|
-
self.comments_position = attributes[:'CommentsPosition']
|
76
|
-
end
|
77
|
-
|
78
|
-
if attributes.has_key?(:'CommentsAreaWidth')
|
79
|
-
self.comments_area_width = attributes[:'CommentsAreaWidth']
|
80
|
-
end
|
81
|
-
|
82
|
-
if attributes.has_key?(:'CommentsAreaColor')
|
83
|
-
self.comments_area_color = attributes[:'CommentsAreaColor']
|
84
|
-
end
|
85
|
-
|
86
55
|
if attributes.has_key?(:'ShowHiddenSlides')
|
87
56
|
self.show_hidden_slides = attributes[:'ShowHiddenSlides']
|
88
57
|
end
|
58
|
+
|
59
|
+
if attributes.has_key?(:'SlidesLayoutOptions')
|
60
|
+
self.slides_layout_options = attributes[:'SlidesLayoutOptions']
|
61
|
+
end
|
89
62
|
self.format = 'image'
|
90
63
|
end
|
91
64
|
|
@@ -100,33 +73,9 @@ module AsposeSlidesCloud
|
|
100
73
|
# @return true if the model is valid
|
101
74
|
def valid?
|
102
75
|
return false if !super
|
103
|
-
notes_position_validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated'])
|
104
|
-
return false unless notes_position_validator.valid?(@notes_position)
|
105
|
-
comments_position_validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right'])
|
106
|
-
return false unless comments_position_validator.valid?(@comments_position)
|
107
76
|
true
|
108
77
|
end
|
109
78
|
|
110
|
-
# Custom attribute writer method checking allowed values (enum).
|
111
|
-
# @param [Object] notes_position Object to be assigned
|
112
|
-
def notes_position=(notes_position)
|
113
|
-
validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated'])
|
114
|
-
unless validator.valid?(notes_position)
|
115
|
-
fail ArgumentError, 'invalid value for "notes_position", must be one of #{validator.allowable_values}.'
|
116
|
-
end
|
117
|
-
@notes_position = notes_position
|
118
|
-
end
|
119
|
-
|
120
|
-
# Custom attribute writer method checking allowed values (enum).
|
121
|
-
# @param [Object] comments_position Object to be assigned
|
122
|
-
def comments_position=(comments_position)
|
123
|
-
validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right'])
|
124
|
-
unless validator.valid?(comments_position)
|
125
|
-
fail ArgumentError, 'invalid value for "comments_position", must be one of #{validator.allowable_values}.'
|
126
|
-
end
|
127
|
-
@comments_position = comments_position
|
128
|
-
end
|
129
|
-
|
130
79
|
# Checks equality by comparing each attribute.
|
131
80
|
# @param [Object] Object to be compared
|
132
81
|
def ==(o)
|
@@ -138,11 +87,8 @@ module AsposeSlidesCloud
|
|
138
87
|
format == o.format &&
|
139
88
|
height == o.height &&
|
140
89
|
width == o.width &&
|
141
|
-
|
142
|
-
|
143
|
-
comments_area_width == o.comments_area_width &&
|
144
|
-
comments_area_color == o.comments_area_color &&
|
145
|
-
show_hidden_slides == o.show_hidden_slides
|
90
|
+
show_hidden_slides == o.show_hidden_slides &&
|
91
|
+
slides_layout_options == o.slides_layout_options
|
146
92
|
end
|
147
93
|
|
148
94
|
# @see the `==` method
|
@@ -154,7 +100,7 @@ module AsposeSlidesCloud
|
|
154
100
|
# Calculates hash code according to all attributes.
|
155
101
|
# @return [Fixnum] Hash code
|
156
102
|
def hash
|
157
|
-
[default_regular_font, font_fallback_rules, font_subst_rules, format, height, width,
|
103
|
+
[default_regular_font, font_fallback_rules, font_subst_rules, format, height, width, show_hidden_slides, slides_layout_options].hash
|
158
104
|
end
|
159
105
|
end
|
160
106
|
end
|
@@ -0,0 +1,155 @@
|
|
1
|
+
=begin
|
2
|
+
Copyright (c) 2019 Aspose Pty Ltd
|
3
|
+
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
|
+
of this software and associated documentation files (the "Software"), to deal
|
6
|
+
in the Software without restriction, including without limitation the rights
|
7
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
8
|
+
copies of the Software, and to permit persons to whom the Software is
|
9
|
+
furnished to do so, subject to the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be included in all
|
12
|
+
copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
15
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
16
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
17
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
18
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
19
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
20
|
+
SOFTWARE.
|
21
|
+
=end
|
22
|
+
|
23
|
+
require 'date'
|
24
|
+
|
25
|
+
module AsposeSlidesCloud
|
26
|
+
# Notes & comments layouting options.
|
27
|
+
class NotesCommentsLayoutingOptions < SlidesLayoutOptions
|
28
|
+
# Gets or sets the position of the notes on the page.
|
29
|
+
attr_accessor :notes_position
|
30
|
+
|
31
|
+
# Gets or sets the position of the comments on the page.
|
32
|
+
attr_accessor :comments_position
|
33
|
+
|
34
|
+
# Gets or sets the width of the comment output area in pixels (Applies only if comments are displayed on the right).
|
35
|
+
attr_accessor :comments_area_width
|
36
|
+
|
37
|
+
# Gets or sets the color of comments area (Applies only if comments are displayed on the right).
|
38
|
+
attr_accessor :comments_area_color
|
39
|
+
|
40
|
+
# True if comments that have no author are displayed. (Applies only if comments are displayed).
|
41
|
+
attr_accessor :show_comments_by_no_author
|
42
|
+
|
43
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
44
|
+
def self.attribute_map
|
45
|
+
super.merge({
|
46
|
+
:'notes_position' => :'NotesPosition',
|
47
|
+
:'comments_position' => :'CommentsPosition',
|
48
|
+
:'comments_area_width' => :'CommentsAreaWidth',
|
49
|
+
:'comments_area_color' => :'CommentsAreaColor',
|
50
|
+
:'show_comments_by_no_author' => :'ShowCommentsByNoAuthor',
|
51
|
+
})
|
52
|
+
end
|
53
|
+
|
54
|
+
# Attribute type mapping.
|
55
|
+
def self.swagger_types
|
56
|
+
super.merge({
|
57
|
+
:'notes_position' => :'String',
|
58
|
+
:'comments_position' => :'String',
|
59
|
+
:'comments_area_width' => :'Integer',
|
60
|
+
:'comments_area_color' => :'String',
|
61
|
+
:'show_comments_by_no_author' => :'BOOLEAN',
|
62
|
+
})
|
63
|
+
end
|
64
|
+
|
65
|
+
# Initializes the object
|
66
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
67
|
+
def initialize(attributes = {})
|
68
|
+
super
|
69
|
+
|
70
|
+
if attributes.has_key?(:'NotesPosition')
|
71
|
+
self.notes_position = attributes[:'NotesPosition']
|
72
|
+
end
|
73
|
+
|
74
|
+
if attributes.has_key?(:'CommentsPosition')
|
75
|
+
self.comments_position = attributes[:'CommentsPosition']
|
76
|
+
end
|
77
|
+
|
78
|
+
if attributes.has_key?(:'CommentsAreaWidth')
|
79
|
+
self.comments_area_width = attributes[:'CommentsAreaWidth']
|
80
|
+
end
|
81
|
+
|
82
|
+
if attributes.has_key?(:'CommentsAreaColor')
|
83
|
+
self.comments_area_color = attributes[:'CommentsAreaColor']
|
84
|
+
end
|
85
|
+
|
86
|
+
if attributes.has_key?(:'ShowCommentsByNoAuthor')
|
87
|
+
self.show_comments_by_no_author = attributes[:'ShowCommentsByNoAuthor']
|
88
|
+
end
|
89
|
+
self.layout_type = 'NotesComments'
|
90
|
+
end
|
91
|
+
|
92
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
93
|
+
# @return Array for valid properties with the reasons
|
94
|
+
def list_invalid_properties
|
95
|
+
invalid_properties = super
|
96
|
+
invalid_properties
|
97
|
+
end
|
98
|
+
|
99
|
+
# Check to see if the all the properties in the model are valid
|
100
|
+
# @return true if the model is valid
|
101
|
+
def valid?
|
102
|
+
return false if !super
|
103
|
+
notes_position_validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated'])
|
104
|
+
return false unless notes_position_validator.valid?(@notes_position)
|
105
|
+
comments_position_validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right'])
|
106
|
+
return false unless comments_position_validator.valid?(@comments_position)
|
107
|
+
true
|
108
|
+
end
|
109
|
+
|
110
|
+
# Custom attribute writer method checking allowed values (enum).
|
111
|
+
# @param [Object] notes_position Object to be assigned
|
112
|
+
def notes_position=(notes_position)
|
113
|
+
validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated'])
|
114
|
+
unless validator.valid?(notes_position)
|
115
|
+
fail ArgumentError, 'invalid value for "notes_position", must be one of #{validator.allowable_values}.'
|
116
|
+
end
|
117
|
+
@notes_position = notes_position
|
118
|
+
end
|
119
|
+
|
120
|
+
# Custom attribute writer method checking allowed values (enum).
|
121
|
+
# @param [Object] comments_position Object to be assigned
|
122
|
+
def comments_position=(comments_position)
|
123
|
+
validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right'])
|
124
|
+
unless validator.valid?(comments_position)
|
125
|
+
fail ArgumentError, 'invalid value for "comments_position", must be one of #{validator.allowable_values}.'
|
126
|
+
end
|
127
|
+
@comments_position = comments_position
|
128
|
+
end
|
129
|
+
|
130
|
+
# Checks equality by comparing each attribute.
|
131
|
+
# @param [Object] Object to be compared
|
132
|
+
def ==(o)
|
133
|
+
return true if self.equal?(o)
|
134
|
+
self.class == o.class &&
|
135
|
+
layout_type == o.layout_type &&
|
136
|
+
notes_position == o.notes_position &&
|
137
|
+
comments_position == o.comments_position &&
|
138
|
+
comments_area_width == o.comments_area_width &&
|
139
|
+
comments_area_color == o.comments_area_color &&
|
140
|
+
show_comments_by_no_author == o.show_comments_by_no_author
|
141
|
+
end
|
142
|
+
|
143
|
+
# @see the `==` method
|
144
|
+
# @param [Object] Object to be compared
|
145
|
+
def eql?(o)
|
146
|
+
self == o
|
147
|
+
end
|
148
|
+
|
149
|
+
# Calculates hash code according to all attributes.
|
150
|
+
# @return [Fixnum] Hash code
|
151
|
+
def hash
|
152
|
+
[layout_type, notes_position, comments_position, comments_area_width, comments_area_color, show_comments_by_no_author].hash
|
153
|
+
end
|
154
|
+
end
|
155
|
+
end
|
@@ -157,6 +157,7 @@ module AsposeSlidesCloud
|
|
157
157
|
alternative_text == o.alternative_text &&
|
158
158
|
alternative_text_title == o.alternative_text_title &&
|
159
159
|
hidden == o.hidden &&
|
160
|
+
is_decorative == o.is_decorative &&
|
160
161
|
x == o.x &&
|
161
162
|
y == o.y &&
|
162
163
|
z_order_position == o.z_order_position &&
|
@@ -187,7 +188,7 @@ module AsposeSlidesCloud
|
|
187
188
|
# Calculates hash code according to all attributes.
|
188
189
|
# @return [Fixnum] Hash code
|
189
190
|
def hash
|
190
|
-
[self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, x, y, z_order_position, fill_format, effect_format, three_d_format, line_format, hyperlink_click, hyperlink_mouse_over, type, is_object_icon, substitute_picture_title, substitute_picture_format, object_name, embedded_file_base64_data, embedded_file_extension, object_prog_id, link_path, update_automatic].hash
|
191
|
+
[self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, is_decorative, x, y, z_order_position, fill_format, effect_format, three_d_format, line_format, hyperlink_click, hyperlink_mouse_over, type, is_object_icon, substitute_picture_title, substitute_picture_format, object_name, embedded_file_base64_data, embedded_file_extension, object_prog_id, link_path, update_automatic].hash
|
191
192
|
end
|
192
193
|
end
|
193
194
|
end
|