xref: /reactos/sdk/include/psdk/gdiplusbrush.h (revision 5100859e)
1 /*
2  * GdiPlusBrush.h
3  *
4  * Windows GDI+
5  *
6  * This file is part of the w32api package.
7  *
8  * THIS SOFTWARE IS NOT COPYRIGHTED
9  *
10  * This source code is offered for use in the public domain. You may
11  * use, modify or distribute it freely.
12  *
13  * This code is distributed in the hope that it will be useful but
14  * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
15  * DISCLAIMED. This includes but is not limited to warranties of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
17  */
18 
19 #ifndef _GDIPLUSBRUSH_H
20 #define _GDIPLUSBRUSH_H
21 
22 class Image;
23 
24 class Brush : public GdiplusBase
25 {
26 public:
27   friend class Graphics;
28   friend class Pen;
29 
30   Brush *Clone(VOID) const
31   {
32     return NULL;
33   }
34 
35   Status GetLastStatus(VOID)
36   {
37     return status;
38   }
39 
40   BrushType GetType(VOID)
41   {
42     BrushType type;
43     SetStatus(DllExports::GdipGetBrushType(brush, &type));
44     return type;
45   }
46 
47 private:
48   mutable Status status;
49   GpBrush *brush;
50 
51   Status SetStatus(Status status) const
52   {
53     if (status == Ok)
54       return status;
55     this->status = status;
56     return status;
57   }
58 };
59 
60 
61 class HatchBrush : public Brush
62 {
63 public:
64   HatchBrush(HatchStyle hatchStyle, const Color &foreColor, const Color &backColor)
65   {
66   }
67 
68   Status GetBackgroundColor(Color *color) const
69   {
70     return NotImplemented;
71   }
72 
73   Status GetForegroundColor(Color *color) const
74   {
75     return NotImplemented;
76   }
77 
78   HatchStyle GetHatchStyle(VOID) const
79   {
80     return HatchStyleHorizontal;
81   }
82 };
83 
84 
85 class LinearGradientBrush : public Brush
86 {
87 public:
88   LinearGradientBrush(const PointF &point1, const PointF &point2, const Color &color1, const Color &color2)
89   {
90   }
91 
92   LinearGradientBrush(const Rect &rect, const Color &color1, const Color &color2, REAL angle, BOOL isAngleScalable)
93   {
94   }
95 
96   LinearGradientBrush(const Rect &rect, const Color &color1, const Color &color2, LinearGradientMode mode)
97   {
98   }
99 
100   LinearGradientBrush(const Point &point1, const Point &point2, const Color &color1, const Color &color2)
101   {
102   }
103 
104   LinearGradientBrush(const RectF &rect, const Color &color1, const Color &color2, REAL angle, BOOL isAngleScalable)
105   {
106   }
107 
108   LinearGradientBrush(const RectF &rect, const Color &color1, const Color &color2, LinearGradientMode mode)
109   {
110   }
111 
112   Status GetBlend(REAL *blendFactors, REAL *blendPositions, INT count)
113   {
114     return NotImplemented;
115   }
116 
117   INT GetBlendCount(VOID) const
118   {
119     return 0;
120   }
121 
122   BOOL GetGammaCorrection(VOID) const
123   {
124     return FALSE;
125   }
126 
127   INT GetInterpolationColorCount(VOID) const
128   {
129     return 0;
130   }
131 
132   Status GetInterpolationColors(Color *presetColors, REAL *blendPositions, INT count) const
133   {
134     return NotImplemented;
135   }
136 
137   Status GetLinearColors(Color* colors) const
138   {
139     return NotImplemented;
140   }
141 
142   Status GetRectangle(Rect *rect) const
143   {
144     return NotImplemented;
145   }
146 
147   Status GetRectangle(RectF* rect) const
148   {
149     return NotImplemented;
150   }
151 
152   Status GetTransform(Matrix* matrix) const
153   {
154     return NotImplemented;
155   }
156 
157   WrapMode GetWrapMode(VOID) const
158   {
159     return WrapModeTile;
160   }
161 
162   Status MultiplyTransform(const Matrix *matrix, MatrixOrder order)
163   {
164     return NotImplemented;
165   }
166 
167   Status ResetTransform(VOID)
168   {
169     return NotImplemented;
170   }
171 
172   Status RotateTransform(REAL angle, MatrixOrder order)
173   {
174     return NotImplemented;
175   }
176 
177   Status ScaleTransform(REAL sx, REAL sy, MatrixOrder order)
178   {
179     return NotImplemented;
180   }
181 
182   Status SetBlend(const REAL *blendFactors, const REAL *blendPositions, INT count)
183   {
184     return NotImplemented;
185   }
186 
187   Status SetBlendBellShape(REAL focus, REAL scale)
188   {
189     return NotImplemented;
190   }
191 
192   Status SetBlendTriangularShape(REAL focus, REAL scale)
193   {
194     return NotImplemented;
195   }
196 
197   Status SetGammaCorrection(BOOL useGammaCorrection)
198   {
199     return NotImplemented;
200   }
201 
202   Status SetInterpolationColors(const Color *presetColors, const REAL *blendPositions, INT count)
203   {
204     return NotImplemented;
205   }
206 
207   Status SetLinearColors(const Color& color1, const Color& color2)
208   {
209     return NotImplemented;
210   }
211 
212   Status SetTransform(const Matrix* matrix)
213   {
214     return NotImplemented;
215   }
216 
217   Status SetWrapMode(WrapMode wrapMode)
218   {
219     return NotImplemented;
220   }
221 
222   Status TranslateTransform(REAL dx, REAL dy, MatrixOrder order)
223   {
224     return NotImplemented;
225   }
226 };
227 
228 
229 class SolidBrush : Brush
230 {
231 public:
232   SolidBrush(const Color &color)
233   {
234   }
235 
236   Status GetColor(Color *color) const
237   {
238     return NotImplemented;
239   }
240 
241   Status SetColor(const Color &color)
242   {
243     return NotImplemented;
244   }
245 };
246 
247 
248 class TextureBrush : Brush
249 {
250 public:
251   TextureBrush(Image *image, WrapMode wrapMode, const RectF &dstRect)
252   {
253   }
254 
255   TextureBrush(Image *image, Rect &dstRect, ImageAttributes *imageAttributes)
256   {
257   }
258 
259   TextureBrush(Image *image, WrapMode wrapMode, INT dstX, INT dstY, INT dstWidth, INT dstHeight)
260   {
261   }
262 
263   TextureBrush(Image *image, WrapMode wrapMode, REAL dstX, REAL dstY, REAL dstWidth, REAL dstHeight)
264   {
265   }
266 
267   TextureBrush(Image *image, RectF &dstRect, ImageAttributes *imageAttributes)
268   {
269   }
270 
271   TextureBrush(Image *image, WrapMode wrapMode)
272   {
273   }
274 
275   TextureBrush(Image *image, WrapMode wrapMode, const Rect &dstRect)
276   {
277   }
278 
279   Image *GetImage(VOID) const
280   {
281     return NULL;
282   }
283 
284   Status GetTransform(Matrix *matrix) const
285   {
286     return NotImplemented;
287   }
288 
289   WrapMode GetWrapMode(VOID) const
290   {
291     return WrapModeTile;
292   }
293 
294   Status MultiplyTransform(Matrix *matrix, MatrixOrder order)
295   {
296     return NotImplemented;
297   }
298 
299   Status ResetTransform(VOID)
300   {
301     return NotImplemented;
302   }
303 
304   Status RotateTransform(REAL angle, MatrixOrder order)
305   {
306     return NotImplemented;
307   }
308 
309   Status ScaleTransform(REAL sx, REAL sy, MatrixOrder order)
310   {
311     return NotImplemented;
312   }
313 
314   Status SetTransform(const Matrix *matrix)
315   {
316     return NotImplemented;
317   }
318 
319   Status SetWrapMode(WrapMode wrapMode)
320   {
321     return NotImplemented;
322   }
323 
324   Status TranslateTransform(REAL dx, REAL dy, MatrixOrder order)
325   {
326     return NotImplemented;
327   }
328 };
329 
330 #endif /* _GDIPLUSBRUSH_H */
331