From b2e8b36e509b7d2768e584cb2ef2a3a955b4e777 Mon Sep 17 00:00:00 2001 From: Francois Gouget Date: Fri, 22 Oct 2004 19:56:51 +0000 Subject: [PATCH] Flesh out the icm.h header (add COLORMATCHSETUP & co) so it is necessary to first include winuser.h like on Windows. --- dlls/mscms/handle.c | 2 +- dlls/mscms/mscms_main.c | 2 +- dlls/mscms/profile.c | 2 +- dlls/mscms/tests/profile.c | 2 +- include/icm.h | 77 +++++++++++++++++++++++++++++++++----- 5 files changed, 71 insertions(+), 14 deletions(-) diff --git a/dlls/mscms/handle.c b/dlls/mscms/handle.c index 66c6610718d..c13c46c00c6 100644 --- a/dlls/mscms/handle.c +++ b/dlls/mscms/handle.c @@ -23,8 +23,8 @@ #include "windef.h" #include "winbase.h" - #include "wingdi.h" +#include "winuser.h" #include "icm.h" #include "mscms_priv.h" diff --git a/dlls/mscms/mscms_main.c b/dlls/mscms/mscms_main.c index 94d7a3e6b46..5d0f4665865 100644 --- a/dlls/mscms/mscms_main.c +++ b/dlls/mscms/mscms_main.c @@ -28,8 +28,8 @@ #include "windef.h" #include "winbase.h" - #include "wingdi.h" +#include "winuser.h" #include "icm.h" #define LCMS_API_NO_REDEFINE diff --git a/dlls/mscms/profile.c b/dlls/mscms/profile.c index 29410b143a1..5c3f53644af 100644 --- a/dlls/mscms/profile.c +++ b/dlls/mscms/profile.c @@ -26,8 +26,8 @@ #include "windef.h" #include "winbase.h" #include "winnls.h" - #include "wingdi.h" +#include "winuser.h" #include "icm.h" #define LCMS_API_FUNCTION(f) extern typeof(f) * p##f; diff --git a/dlls/mscms/tests/profile.c b/dlls/mscms/tests/profile.c index 9690b32a329..6006ca21e00 100644 --- a/dlls/mscms/tests/profile.c +++ b/dlls/mscms/tests/profile.c @@ -23,8 +23,8 @@ #include "windef.h" #include "winbase.h" #include "winnls.h" - #include "wingdi.h" +#include "winuser.h" #include "icm.h" #include "wine/test.h" diff --git a/include/icm.h b/include/icm.h index 9854aa025db..37b32bfa376 100644 --- a/include/icm.h +++ b/include/icm.h @@ -29,7 +29,8 @@ typedef HANDLE HTRANSFORM; typedef DWORD TAGTYPE, *PTAGTYPE, *LPTAGTYPE; -typedef enum { +typedef enum +{ BM_x555RGB = 0x00, BM_565RGB = 0x01, BM_RGBTRIPLETS = 0x02, @@ -72,7 +73,8 @@ typedef enum { typedef BOOL (CALLBACK *PBMCALLBACKFN)(ULONG,ULONG,LPARAM); typedef PBMCALLBACKFN LPPBMCALLBACKFN; -typedef struct tagPROFILEHEADER { +typedef struct tagPROFILEHEADER +{ DWORD phSize; DWORD phCMMType; DWORD phVersion; @@ -92,29 +94,84 @@ typedef struct tagPROFILEHEADER { BYTE phReserved[44]; } PROFILEHEADER, *PPROFILEHEADER, *LPPROFILEHEADER; -typedef struct tagPROFILE { +typedef struct tagPROFILE +{ DWORD dwType; PVOID pProfileData; DWORD cbDataSize; } PROFILE, *PPROFILE, *LPPROFILE; + +struct _tagCOLORMATCHSETUPA; +struct _tagCOLORMATCHSETUPW; + +typedef BOOL (WINAPI *PCMSCALLBACKA)(struct _tagCOLORMATCHSETUPA*,LPARAM); +typedef BOOL (WINAPI *PCMSCALLBACKW)(struct _tagCOLORMATCHSETUPW*,LPARAM); + +typedef struct _tagCOLORMATCHSETUPA +{ + DWORD dwSize; + DWORD dwVersion; + DWORD dwFlags; + HWND hwndOwner; + PCSTR pSourceName; + PCSTR pDisplayName; + PCSTR pPrinterName; + DWORD dwRenderIntent; + DWORD dwProofingIntent; + PSTR pMonitorProfile; + DWORD ccMonitorProfile; + PSTR pPrinterProfile; + DWORD ccPrinterProfile; + PSTR pTargetProfile; + DWORD ccTargetProfile; + DLGPROC lpfnHook; + LPARAM lParam; + PCMSCALLBACKA lpfnApplyCallback; + LPARAM lParamApplyCallback; +} COLORMATCHSETUPA, *PCOLORMATCHSETUPA, *LPCOLORMATCHSETUPA; + +typedef struct _tagCOLORMATCHSETUPW +{ + DWORD dwSize; + DWORD dwVersion; + DWORD dwFlags; + HWND hwndOwner; + PCWSTR pSourceName; + PCWSTR pDisplayName; + PCWSTR pPrinterName; + DWORD dwRenderIntent; + DWORD dwProofingIntent; + PWSTR pMonitorProfile; + DWORD ccMonitorProfile; + PWSTR pPrinterProfile; + DWORD ccPrinterProfile; + PWSTR pTargetProfile; + DWORD ccTargetProfile; + DLGPROC lpfnHook; + LPARAM lParam; + PCMSCALLBACKW lpfnApplyCallback; + LPARAM lParamApplyCallback; +} COLORMATCHSETUPW, *PCOLORMATCHSETUPW, *LPCOLORMATCHSETUPW; + + +BOOL WINAPI CloseColorProfile(HPROFILE); BOOL WINAPI GetColorDirectoryA(PCSTR,PSTR,PDWORD); BOOL WINAPI GetColorDirectoryW(PCWSTR,PWSTR,PDWORD); #define GetColorDirectory WINELIB_NAME_AW(GetColorDirectory) - BOOL WINAPI InstallColorProfileA(PCSTR,PCSTR); BOOL WINAPI InstallColorProfileW(PCWSTR,PCWSTR); #define InstallColorProfile WINELIB_NAME_AW(InstallColorProfile) - +HPROFILE WINAPI OpenColorProfileA(PPROFILE,DWORD,DWORD,DWORD); +HPROFILE WINAPI OpenColorProfileW(PPROFILE,DWORD,DWORD,DWORD); +#define OpenColorProfile WINELIB_NAME_AW(OpenColorProfile) +BOOL WINAPI SetupColorMatchingA(PCOLORMATCHSETUPA); +BOOL WINAPI SetupColorMatchingW(PCOLORMATCHSETUPW); +#define SetupColorMatching WINELIB_NAME_AW(SetupColorMatching) BOOL WINAPI UninstallColorProfileA(PCSTR,PCSTR,BOOL); BOOL WINAPI UninstallColorProfileW(PCWSTR,PCWSTR,BOOL); #define UninstallColorProfile WINELIB_NAME_AW(UninstallColorProfile) -HPROFILE WINAPI OpenColorProfileA(PPROFILE,DWORD,DWORD,DWORD); -HPROFILE WINAPI OpenColorProfileW(PPROFILE,DWORD,DWORD,DWORD); -#define OpenColorProfile WINELIB_NAME_AW(OpenColorProfile) - -BOOL WINAPI CloseColorProfile(HPROFILE); #define PROFILE_FILENAME 1 #define PROFILE_MEMBUFFER 2