gdiplus: Implemented GdipCreateLineBrushFromRect.
This commit is contained in:
parent
836b4183b9
commit
5873bac95d
|
@ -149,7 +149,7 @@ GpStatus WINGDIPAPI GdipCreateLineBrushI(GDIPCONST GpPoint* startpoint,
|
||||||
return GdipCreateLineBrush(&stF, &endF, startcolor, endcolor, wrap, line);
|
return GdipCreateLineBrush(&stF, &endF, startcolor, endcolor, wrap, line);
|
||||||
}
|
}
|
||||||
|
|
||||||
GpStatus WINGDIPAPI GdipCreateLineBrushFromRectI(GDIPCONST GpRect* rect,
|
GpStatus WINGDIPAPI GdipCreateLineBrushFromRect(GDIPCONST GpRectF* rect,
|
||||||
ARGB startcolor, ARGB endcolor, LinearGradientMode mode, GpWrapMode wrap,
|
ARGB startcolor, ARGB endcolor, LinearGradientMode mode, GpWrapMode wrap,
|
||||||
GpLineGradient **line)
|
GpLineGradient **line)
|
||||||
{
|
{
|
||||||
|
@ -158,14 +158,28 @@ GpStatus WINGDIPAPI GdipCreateLineBrushFromRectI(GDIPCONST GpRect* rect,
|
||||||
if(!line || !rect)
|
if(!line || !rect)
|
||||||
return InvalidParameter;
|
return InvalidParameter;
|
||||||
|
|
||||||
start.X = (REAL) rect->X;
|
start.X = rect->X;
|
||||||
start.Y = (REAL) rect->Y;
|
start.Y = rect->Y;
|
||||||
end.X = (REAL) (rect->X + rect->Width);
|
end.X = rect->X + rect->Width;
|
||||||
end.Y = (REAL) (rect->Y + rect->Height);
|
end.Y = rect->Y + rect->Height;
|
||||||
|
|
||||||
return GdipCreateLineBrush(&start, &end, startcolor, endcolor, wrap, line);
|
return GdipCreateLineBrush(&start, &end, startcolor, endcolor, wrap, line);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GpStatus WINGDIPAPI GdipCreateLineBrushFromRectI(GDIPCONST GpRect* rect,
|
||||||
|
ARGB startcolor, ARGB endcolor, LinearGradientMode mode, GpWrapMode wrap,
|
||||||
|
GpLineGradient **line)
|
||||||
|
{
|
||||||
|
GpRectF rectF;
|
||||||
|
|
||||||
|
rectF.X = (REAL) rect->X;
|
||||||
|
rectF.Y = (REAL) rect->Y;
|
||||||
|
rectF.Width = (REAL) rect->Width;
|
||||||
|
rectF.Height = (REAL) rect->Height;
|
||||||
|
|
||||||
|
return GdipCreateLineBrushFromRect(&rectF, startcolor, endcolor, mode, wrap, line);
|
||||||
|
}
|
||||||
|
|
||||||
GpStatus WINGDIPAPI GdipCreatePathGradient(GDIPCONST GpPointF* points,
|
GpStatus WINGDIPAPI GdipCreatePathGradient(GDIPCONST GpPointF* points,
|
||||||
INT count, GpWrapMode wrap, GpPathGradient **grad)
|
INT count, GpWrapMode wrap, GpPathGradient **grad)
|
||||||
{
|
{
|
||||||
|
|
|
@ -99,7 +99,7 @@
|
||||||
@ stub GdipCreateHatchBrush
|
@ stub GdipCreateHatchBrush
|
||||||
@ stdcall GdipCreateImageAttributes(ptr)
|
@ stdcall GdipCreateImageAttributes(ptr)
|
||||||
@ stdcall GdipCreateLineBrush(ptr ptr long long long ptr)
|
@ stdcall GdipCreateLineBrush(ptr ptr long long long ptr)
|
||||||
@ stub GdipCreateLineBrushFromRect
|
@ stdcall GdipCreateLineBrushFromRect(ptr long long long long ptr)
|
||||||
@ stdcall GdipCreateLineBrushFromRectI(ptr long long long long ptr)
|
@ stdcall GdipCreateLineBrushFromRectI(ptr long long long long ptr)
|
||||||
@ stub GdipCreateLineBrushFromRectWithAngle
|
@ stub GdipCreateLineBrushFromRectWithAngle
|
||||||
@ stub GdipCreateLineBrushFromRectWithAngleI
|
@ stub GdipCreateLineBrushFromRectWithAngleI
|
||||||
|
|
Loading…
Reference in New Issue