diff --git a/dlls/gdiplus/gdiplus.spec b/dlls/gdiplus/gdiplus.spec index 52179ec20cc..5d2c3bd777c 100644 --- a/dlls/gdiplus/gdiplus.spec +++ b/dlls/gdiplus/gdiplus.spec @@ -102,7 +102,7 @@ @ stdcall GdipCreateMetafileFromEmf(ptr long ptr) @ stub GdipCreateMetafileFromFile @ stub GdipCreateMetafileFromStream -@ stub GdipCreateMetafileFromWmf +@ stdcall GdipCreateMetafileFromWmf(ptr long ptr ptr) @ stub GdipCreateMetafileFromWmfFile @ stub GdipCreatePath2 @ stub GdipCreatePath2I diff --git a/dlls/gdiplus/graphics.c b/dlls/gdiplus/graphics.c index a29d3a100de..f53ea4ce0ca 100644 --- a/dlls/gdiplus/graphics.c +++ b/dlls/gdiplus/graphics.c @@ -818,6 +818,20 @@ GpStatus WINGDIPAPI GdipCreateMetafileFromEmf(HENHMETAFILE hemf, BOOL delete, return NotImplemented; } +GpStatus WINGDIPAPI GdipCreateMetafileFromWmf(HMETAFILE hwmf, BOOL delete, + GDIPCONST WmfPlaceableFileHeader * placeable, GpMetafile **metafile) +{ + static int calls; + + if(!hwmf || !metafile || !placeable) + return InvalidParameter; + + if(!(calls++)) + FIXME("not implemented\n"); + + return NotImplemented; +} + GpStatus WINGDIPAPI GdipDeleteGraphics(GpGraphics *graphics) { if(!graphics) return InvalidParameter; diff --git a/include/Makefile.in b/include/Makefile.in index 782e671e4de..44ef893f39e 100644 --- a/include/Makefile.in +++ b/include/Makefile.in @@ -169,6 +169,7 @@ SRCDIR_INCLUDES = \ gdiplusgpstubs.h \ gdiplusinit.h \ gdiplusmem.h \ + gdiplusmetaheader.h \ gdipluspixelformats.h \ gdiplustypes.h \ guiddef.h \ diff --git a/include/gdiplus.h b/include/gdiplus.h index e5da625ea4c..6b42093e832 100644 --- a/include/gdiplus.h +++ b/include/gdiplus.h @@ -32,6 +32,7 @@ namespace Gdiplus #include "gdiplusenums.h" #include "gdiplusinit.h" #include "gdipluspixelformats.h" +#include "gdiplusmetaheader.h" #include "gdiplusgpstubs.h" namespace DllExports @@ -48,6 +49,7 @@ namespace Gdiplus #include "gdiplusenums.h" #include "gdiplusinit.h" #include "gdipluspixelformats.h" +#include "gdiplusmetaheader.h" #include "gdiplusgpstubs.h" #include "gdiplusflat.h" diff --git a/include/gdiplusflat.h b/include/gdiplusflat.h index 2df7b7c7d3e..bfa2c41e80b 100644 --- a/include/gdiplusflat.h +++ b/include/gdiplusflat.h @@ -47,6 +47,8 @@ GpStatus WINGDIPAPI GdipSetPenStartCap(GpPen*,GpLineCap); GpStatus WINGDIPAPI GdipCreateFromHDC(HDC,GpGraphics**); GpStatus WINGDIPAPI GdipCreateFromHWND(HWND,GpGraphics**); GpStatus WINGDIPAPI GdipCreateMetafileFromEmf(HENHMETAFILE,BOOL,GpMetafile**); +GpStatus WINGDIPAPI GdipCreateMetafileFromWmf(HMETAFILE,BOOL, + GDIPCONST WmfPlaceableFileHeader*,GpMetafile**); GpStatus WINGDIPAPI GdipDeleteGraphics(GpGraphics *); GpStatus WINGDIPAPI GdipDrawArc(GpGraphics*,GpPen*,REAL,REAL,REAL,REAL,REAL,REAL); GpStatus WINGDIPAPI GdipDrawBezier(GpGraphics*,GpPen*,REAL,REAL,REAL,REAL,REAL, diff --git a/include/gdiplusmetaheader.h b/include/gdiplusmetaheader.h new file mode 100644 index 00000000000..2b4adf6b785 --- /dev/null +++ b/include/gdiplusmetaheader.h @@ -0,0 +1,44 @@ +/* + * Copyright (C) 2007 Google (Evan Stade) + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#ifndef _GDIPLUSMETAHEADER_H +#define _GDIPLUSMETAHEADER_H + +#include + +typedef struct +{ + INT16 Left; + INT16 Top; + INT16 Right; + INT16 Bottom; +} PWMFRect16; + +typedef struct +{ + UINT32 Key; + INT16 Hmf; + PWMFRect16 BoundingBox; + INT16 Inch; + UINT32 Reserved; + INT16 Checksum; +} WmfPlaceableFileHeader; + +#include + +#endif /* _GDIPLUSMETAHEADER_H */