1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
mod annotation;
pub use annotation::annotate;

mod bbh_factory;
pub use bbh_factory::*;

mod bitmap;
pub use bitmap::*;

mod blend_mode;
pub use blend_mode::*;

mod blur_types;
pub use blur_types::*;

pub mod canvas;
#[deprecated(since = "0.12.0", note = "use canvas::lattice::RectType")]
pub use canvas::lattice::RectType as CanvasLatticeRectType;
#[deprecated(since = "0.12.0", note = "use canvas::Lattice")]
pub use canvas::Lattice as CanvasLattice;
#[deprecated(since = "0.12.0", note = "use canvas::PointMode")]
pub use canvas::PointMode as CanvasPointMode;
#[deprecated(since = "0.12.0", note = "use canvas::SaveLayerFlags")]
pub use canvas::SaveLayerFlags;
#[deprecated(since = "0.12.0", note = "use canvas::SaveLayerRec")]
pub use canvas::SaveLayerRec;
#[deprecated(since = "0.12.0", note = "use canvas::SrcRectConstraint")]
pub use canvas::SrcRectConstraint;
#[deprecated(since = "0.12.0", note = "use canvas::TopLayerPixels")]
pub use canvas::TopLayerPixels as CanvasTopLayerPixels;
pub use canvas::{AutoCanvasRestore, Canvas, OwnedCanvas};

mod clip_op;
pub use clip_op::*;

mod color;
pub use color::*;

pub mod color_filter;
#[deprecated(since = "0.12.0", note = "use ColorFilter::Flags")]
pub use color_filter::Flags as ColorFilterFlags;
pub use color_filter::{color_filters, ColorFilter};
#[deprecated(since = "0.12.0", note = "use color_filters")]
pub use color_filters as ColorFilters;

mod color_space;
pub use color_space::*;
#[deprecated(since = "0.12.0", note = "use named_transfer_fn")]
pub use named_transfer_fn as NamedTransferFn;

pub mod contour_measure;
pub use contour_measure::{ContourMeasure, ContourMeasureIter};

mod coverage_mode;
pub use coverage_mode::*;

mod cubic_map;
pub use cubic_map::*;

mod data;
pub use data::*;

mod data_table;
pub use data_table::*;

mod deferred_display_list_recorder;
pub use deferred_display_list_recorder::*;

pub mod document;
pub use document::Document;

pub mod draw_looper;
#[deprecated(since = "0.12.0", note = "use draw_looper::BlurShadowRec")]
pub use draw_looper::BlurShadowRec as DrawLooperBlurShadowRec;
pub use draw_looper::DrawLooper;

pub mod drawable;
pub use drawable::Drawable;

mod encoded_image_format;
pub use encoded_image_format::*;

// unsupported, because it's used in experimental APIs only.
// mod executor;

mod filter_quality;
pub use filter_quality::*;

mod flattenable;
pub use flattenable::*;

pub mod font;
#[deprecated(since = "0.12.0", note = "use font::Edging")]
pub use font::Edging as FontEdging;
pub use font::Font;

pub mod font_arguments;
#[deprecated(
    since = "0.12.0",
    note = "use font_arguments::variation_position::Coordinate"
)]
pub use font_arguments::variation_position::Coordinate as FontArgumentsVariationPositionCoordinate;
pub use font_arguments::FontArguments;
#[deprecated(since = "0.12.0", note = "use font_arguments::VariationPosition")]
pub use font_arguments::VariationPosition as FontArgumentsVariationPosition;

// unsupported, because it's not used in publicly exposed APIs:
// mod font_lcd_config;

pub mod font_metrics;
#[deprecated(since = "0.12.0", note = "use font_metrics::Flags")]
pub use font_metrics::Flags as FontMetricsFlags;
pub use font_metrics::FontMetrics;

mod font_mgr;
pub use font_mgr::*;

pub mod font_parameters;

pub mod font_style;
pub use font_style::FontStyle;
#[deprecated(since = "0.12.0", note = "use font_style::Slant")]
pub use font_style::Slant as FontStyleSlant;
#[deprecated(since = "0.12.0", note = "use font_style::Weight")]
pub use font_style::Weight as FontStyleWeight;
#[deprecated(since = "0.12.0", note = "use font_style::Width")]
pub use font_style::Width as FontStyleWidth;

mod font_types;
pub use font_types::*;

pub mod graphics;

pub mod image;
#[deprecated(since = "0.12.0", note = "use image::BitDepth")]
pub use image::BitDepth as ImageBitDepth;
#[deprecated(since = "0.12.0", note = "use image::CachingHint")]
pub use image::CachingHint as ImageCachingHint;
#[deprecated(since = "0.12.0", note = "use image::CompressionType")]
pub use image::CompressionType as ImageCompressionType;
pub use image::Image;

mod image_encoder;
pub use image_encoder::*;

pub mod image_filter;
#[deprecated(since = "0.12.0", note = "use image_filter::crop_rect::CropEdge")]
pub use image_filter::crop_rect::CropEdge as ImageFilterCropRectCropEdge;
#[deprecated(since = "0.12.0", note = "use image_filter::Context")]
pub use image_filter::Context as ImageFilterContext;
#[deprecated(since = "0.12.0", note = "use image_filter::CropRect")]
pub use image_filter::CropRect as ImageFilterCropRect;
pub use image_filter::ImageFilter;
#[deprecated(since = "0.12.0", note = "use image_filter::MapDirection")]
pub use image_filter::MapDirection as ImageFilterMapDirection;
#[deprecated(since = "0.12.0", note = "use image_filter::OutputProperties")]
pub use image_filter::OutputProperties as ImageFilterOutputProperties;
#[deprecated(since = "0.12.0", note = "use image_filter::TileUsage")]
pub use image_filter::TileUsage as ImageFilterTileUsage;

mod image_generator;
pub use image_generator::*;

mod image_info;
pub use image_info::*;

mod mask_filter;
pub use mask_filter::*;

pub mod matrix;
#[deprecated(since = "0.12.0", note = "use matrix::AffineMember")]
pub use matrix::AffineMember as AffineMatrixMember;
pub use matrix::Matrix;
#[deprecated(since = "0.12.0", note = "use matrix::Member")]
pub use matrix::Member as MatrixMember;
#[deprecated(since = "0.12.0", note = "use matrix::ScaleToFit")]
pub use matrix::ScaleToFit as MatrixScaletoFit;
#[deprecated(since = "0.12.0", note = "use matrix::TypeMask")]
pub use matrix::TypeMask as MatrixTypeMask;

pub mod matrix44;
pub use matrix44::{Matrix44, Vector4};

mod milestone;
pub use milestone::*;

mod multi_picture_draw;
pub use multi_picture_draw::*;

pub mod paint;
pub use paint::Paint;
// We keep these around for the time being.
pub use paint::Cap as PaintCap;
pub use paint::Join as PaintJoin;
pub use paint::Style as PaintStyle;

pub mod path;
#[deprecated(since = "0.12.0", note = "use path::AddPathMode")]
pub use path::AddPathMode;
#[deprecated(since = "0.12.0", note = "use path::ArcSize")]
pub use path::ArcSize as PathArcSize;
#[deprecated(since = "0.12.0", note = "use path::Convexity")]
pub use path::Convexity as PathConvexity;
#[deprecated(since = "0.12.0", note = "use matrix::AffineMember")]
pub use path::Direction as PathDirection;
#[deprecated(since = "0.12.0", note = "use path::FillType")]
pub use path::FillType as PathFillType;
pub use path::Path;
#[deprecated(since = "0.12.0", note = "use path::SegmentMask")]
pub use path::SegmentMask as PathSegmentMask;

pub mod path_effect;
#[deprecated(since = "0.12.0", note = "use path_effect::point_data::PointFlags")]
pub use path_effect::point_data::PointFlags as PointDataPointFlags;
#[deprecated(since = "0.12.0", note = "use path_effect::DashInfo")]
pub use path_effect::DashInfo as PathEffectDashInfo;
pub use path_effect::PathEffect;
#[deprecated(since = "0.12.0", note = "use path_effect::PointData")]
pub use path_effect::PointData as PathEffectPointData;

pub mod path_measure;
pub use path_measure::PathMeasure;

mod picture;
pub use picture::*;

pub mod picture_recorder;
pub use picture_recorder::PictureRecorder;
#[deprecated(since = "0.12.0", note = "use picture_recorder::RecordFlags")]
pub use picture_recorder::RecordFlags as PictureRecorderRecordFlags;

mod pixel_ref;
pub use pixel_ref::*;

mod pixmap;
pub use pixmap::*;

mod point;
pub use point::*;

mod point3;
pub use point3::*;

mod promise_image_texture;
pub use promise_image_texture::*;

mod raster_handle_allocator;
pub use raster_handle_allocator::*;

mod rect;
pub use rect::*;

pub mod region;
pub use region::Region;

pub mod rrect;
#[deprecated(since = "0.12.0", note = "use rrect::Corner")]
pub use rrect::Corner as RRectCorner;
pub use rrect::RRect;
#[deprecated(since = "0.12.0", note = "use rrect::Type")]
pub use rrect::Type as RRectType;

mod rsxform;
pub use rsxform::*;

mod scalar_;
pub use scalar_::*;

pub mod shader;
#[deprecated(since = "0.12.0", note = "use shader::GradientInfo")]
pub use shader::GradientInfo as ShaderGradientInfo;
#[deprecated(since = "0.12.0", note = "use shader::GradientType")]
pub use shader::GradientType as ShaderGradientType;
pub use shader::{shaders, Shader};
#[deprecated(since = "0.12.0", note = "use shaders")]
pub use shaders as Shaders;
#[deprecated(since = "0.12.0", note = "use TileMode")]
pub use TileMode as ShaderTileMode;

mod size;
pub use size::*;

pub mod stroke_rec;
#[deprecated(since = "0.12.0", note = "use stroke_rec::InitStyle")]
pub use stroke_rec::InitStyle as StrokeRecInitStyle;
pub use stroke_rec::StrokeRec;
#[deprecated(since = "0.12.0", note = "use stroke_rec::Style")]
pub use stroke_rec::Style as StrokeRecStyle;

pub mod surface;
pub use surface::Surface;
#[deprecated(since = "0.12.0", note = "use Borrows<'a, Surface>")]
pub type OwnedSurface<'a> = crate::Borrows<'a, Surface>;
#[deprecated(since = "0.12.0", note = "use surface::BackendHandleAccess")]
pub use surface::BackendHandleAccess as SurfaceBackendHandleAccess;
#[deprecated(since = "0.12.0", note = "use surface::ContentChangeMode")]
pub use surface::ContentChangeMode as SurfaceContentChangeMode;

mod surface_characterization;
pub use surface_characterization::*;

mod surface_props;
pub use surface_props::*;

mod swizzle;
pub use swizzle::*;

mod text_blob;
pub use text_blob::*;

mod tile_mode;
pub use self::tile_mode::*;

mod time;
pub use time::*;

mod trace_memory_dump;
pub use trace_memory_dump::*;

pub mod typeface;
#[deprecated(since = "0.12.0", note = "use typeface::LocalizedString")]
pub use typeface::LocalizedString as TypefaceLocalizedString;
#[deprecated(since = "0.12.0", note = "use typeface::SerializeBehavior")]
pub use typeface::SerializeBehavior as TypefaceSerializeBehavior;
pub use typeface::Typeface;

mod types;
pub use types::*;

mod un_pre_multiply;
pub use un_pre_multiply::*;

pub mod vertices;
#[deprecated(since = "0.12.0", note = "use vertices::Bone")]
pub use vertices::Bone as VerticesBone;
#[deprecated(since = "0.12.0", note = "use vertices::BoneIndices")]
pub use vertices::BoneIndices;
#[deprecated(since = "0.12.0", note = "use vertices::BoneWeights")]
pub use vertices::BoneWeights;
#[deprecated(since = "0.12.0", note = "use vertices::Builder")]
pub use vertices::Builder as VerticesBuilder;
#[deprecated(since = "0.12.0", note = "use vertices::BuilderFlags")]
pub use vertices::BuilderFlags as VerticesBuilderFlags;
#[deprecated(since = "0.12.0", note = "use vertices::VertexMode")]
pub use vertices::VertexMode as VerticesVertexMode;
pub use vertices::Vertices;

pub mod yuva_index;
pub use yuva_index::{ColorChannel, YUVAIndex};

mod yuva_size_info;
pub use yuva_size_info::*;

//
// Skia specific traits used for overloading.
//

pub trait Contains<T> {
    fn contains(&self, other: T) -> bool;
}

pub trait QuickReject<T> {
    fn quick_reject(&self, other: &T) -> bool;
}