Author: tkreuzer
Date: Sat May 28 16:54:10 2011
New Revision: 51979
URL:
http://svn.reactos.org/svn/reactos?rev=51979&view=rev
Log:
[WIN32K]
- Add initial code for font driver support
Added:
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/ (with props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/dcfont.c (with props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/enumfont.c (with
props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fntdrvsup.c (with
props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontdata.c (with
props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontrsrc.c (with
props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/lfont.c (with props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/misc.c (with props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/rfont.c (with props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/strobj.c (with props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textmetric.c (with
props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textout.c (with
props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/ufi.c (with props)
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/font.h (with
props)
Modified:
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/CMakeLists.txt
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/text.h
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/ntuser/ntuser.c
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/objects/gdiobj.c
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/stubs/stubs.c
Modified: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/CMakeLists.txt
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/CMakeLists.txt [iso-8859-1]
(original)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/CMakeLists.txt [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -59,7 +59,6 @@
eng/rlecomp.c
eng/semaphor.c
eng/sort.c
- eng/string.c
eng/stretchblt.c
eng/surface.c
eng/transblt.c
@@ -138,11 +137,10 @@
objects/dibobj.c
objects/drawing.c
objects/fillshap.c
- objects/font.c
- objects/freetype.c
objects/gdibatch.c
objects/gdidbg.c
objects/gdiobj.c
+ objects/gdipool.c
objects/icm.c
objects/line.c
objects/metafile.c
@@ -154,9 +152,23 @@
objects/rect.c
objects/region.c
objects/stockobj.c
- objects/text.c
objects/wingl.c
objects/xformobj.c
+
+ font/dcfont.c
+ font/enumfont.c
+ font/fntdrvsup.c
+ font/fontdata.c
+ font/fontrsrc.c
+ font/glyphcache.c
+ font/lfont.c
+ font/rfont.c
+ font/strobj.c
+ font/textmetric.c
+ font/textout.c
+ font/ufi.c
+ font/misc.c
+
stubs/stubs.c
stubs/umpdstubs.c
win32k.rc)
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/
------------------------------------------------------------------------------
--- bugtraq:logregex (added)
+++ bugtraq:logregex Sat May 28 16:54:10 2011
@@ -1,0 +1,2 @@
+([Ii]ssue|[Bb]ug)s? #?(\d+)(,? ?#?(\d+))*(,? ?(and |or )?#?(\d+))?
+(\d+)
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/
------------------------------------------------------------------------------
bugtraq:message = See issue #%BUGID% for more details.
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/
------------------------------------------------------------------------------
bugtraq:url =
http://www.reactos.org/bugzilla/show_bug.cgi?id=%BUGID%
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/
------------------------------------------------------------------------------
tsvn:logminsize = 10
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/dcfont.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/dcfont.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/dcfont.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,154 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE: DC/font related functions
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+#if 0
+PRFONT
+NTAPI
+DC_prfnt(PDC pdc)
+{
+ PLFONT plfnt;
+ PRFONT prfnt;
+
+ /* Check if new font was selected */
+ if (pdc->pdcattr->ulDirty_ & DIRTY_TEXT)
+ {
+ /* Lock the new font */
+ plfnt = LFONT_ShareLockFont(pdc->pdcattr->hlfntNew);
+ if (plfnt)
+ {
+ LFONT_ShareUnlockFont(pdc->dclevel.pFont);
+ pdc->dclevel.pFont = plfnt;
+ }
+ else
+ {
+ // FIXME: test how selecting an invalid font is handled
+ pdc->pdcattr->hlfntNew = pdc->dclevel.pFont;
+ }
+ }
+
+ /* Check if font is already realized */
+ if (pdc->hlfntCur != pdc->pdcattr->hlfntNew)
+ {
+
+ prfnt = LFONT_prfntRealizeFont(pdc->dclevel.pFont);
+
+ /* Dereference the old RFONT */
+ RFONT_ShareUnlockFont(pdc->prfnt);
+
+ pdc->prfnt = prfnt;
+
+ /* Set as new active font */
+ pdc->hlfntCur = pdc->pdcattr->hlfntNew;
+ }
+
+ ASSERT(prfnt);
+ return prfnt;
+}
+#endif
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiAddRemoteFontToDC(
+ IN HDC hdc,
+ IN PVOID pvBuffer,
+ IN ULONG cjBuffer,
+ IN OPTIONAL PUNIVERSAL_FONT_ID pufi)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiAddEmbFontToDC(
+ IN HDC hdc,
+ IN VOID **pFontID)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiGetEmbedFonts(VOID)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+
+W32KAPI
+DWORD
+APIENTRY
+NtGdiGetCharSet(
+ IN HDC hdc)
+{
+ ASSERT(FALSE);
+#if 0
+ PDC pdc;
+
+ pdc = DC_LockDc(hdc);
+ if (!pdc)
+ {
+ return -1; // FIXME ???
+ }
+
+ prfnt = DC_prfnt(pdc);
+
+ jWinCharSet = prfnt->ppfe->pifi->jWinCharSet;
+
+
+ return jWinCharSet;
+#endif
+return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiSetFontXform(
+ IN HDC hdc,
+ IN DWORD dwxScale,
+ IN DWORD dwyScale)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiSetTextJustification(
+ IN HDC hdc,
+ IN INT lBreakExtra,
+ IN INT cBreak)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+HFONT
+APIENTRY
+NtGdiSelectFont(
+ IN HDC hdc,
+ IN HFONT hf)
+{
+ ASSERT(FALSE);
+ return 0;
+}
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/dcfont.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/enumfont.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/enumfont.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/enumfont.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,90 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE: Font enumeration
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiEnumFontChunk(
+ IN HDC hdc,
+ IN ULONG_PTR idEnum,
+ IN ULONG cjEfdw,
+ OUT ULONG *pcjEfdw,
+ OUT PENUMFONTDATAW pefdw)
+{
+ ASSERT(FALSE);
+#if 0
+ PEFSTATE pefstate;
+
+ /* Lock the EFSTATE object */
+ pefstate = GDIOBJ_LockObject((HGDIOBJ)idEnum, GDIObjType_EFSTATE_TYPE);
+ if (!pefstate)
+ {
+ EngSetLastError(ERROR_INVALID_HANDLE);
+ return FALSE;
+ }
+
+#endif
+ return 0;
+}
+
+W32KAPI
+ULONG_PTR
+APIENTRY
+NtGdiEnumFontOpen(
+ IN HDC hdc,
+ IN ULONG iEnumType,
+ IN FLONG flWin31Compat,
+ IN ULONG cwchMax,
+ IN OPTIONAL LPWSTR pwszFaceName,
+ IN ULONG lfCharSet,
+ OUT ULONG *pulCount)
+{
+ ULONG_PTR idEnum = 0;
+
+ ASSERT(FALSE);
+
+ /* Allocate an EFSTATE object */
+
+
+ return idEnum;
+}
+
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiEnumFontClose(
+ IN ULONG_PTR idEnum)
+{
+
+ /* Verify that idEnum is a handle to an EFSTATE object */
+ if (((idEnum >> 16) & 0x1f) != GDIObjType_EFSTATE_TYPE)
+ {
+ EngSetLastError(ERROR_INVALID_HANDLE);
+ return FALSE;
+ }
+
+ /* Delete the object */
+ return GreDeleteObject((HGDIOBJ)idEnum);
+}
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiSetFontEnumeration(
+ IN ULONG ulType)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/enumfont.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fntdrvsup.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fntdrvsup.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fntdrvsup.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,210 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+BOOL gbAttachedCSRSS;
+
+HSEMAPHORE ghsemFontDriver;
+LIST_ENTRY gleFontDriverList = {&gleFontDriverList, &gleFontDriverList};
+
+
+BOOL FASTCALL
+InitFontSupport(VOID)
+{
+ ghsemFontDriver = EngCreateSemaphore();
+ if (!ghsemFontDriver) return FALSE;
+ return TRUE;
+}
+
+
+typedef struct _FONTDEV
+{
+ LIST_ENTRY leLink;
+ DHPDEV dhpdev;
+ PLDEVOBJ pldev;
+ HSURF ahsurf[HS_DDI_MAX];
+ DEVINFO devinfo;
+
+ GDIINFO gdiinfo; // FIXME: something else?
+} FONTDEV, *PFONTDEV;
+
+C_ASSERT(sizeof(GDIINFO) == 0x130);
+
+
+//static
+VOID
+AttachCSRSS(KAPC_STATE *pApcState)
+{
+ ASSERT(gpepCSRSS);
+ KeStackAttachProcess(&gpepCSRSS->Pcb, pApcState);
+ gbAttachedCSRSS = TRUE;
+}
+
+//static
+VOID
+DetachCSRSS(KAPC_STATE *pApcState)
+{
+ ASSERT(gbAttachedCSRSS);
+ KeUnstackDetachProcess(pApcState);
+ gbAttachedCSRSS = FALSE;
+}
+
+
+ULONG_PTR
+FONTDEV_LoadFontFile(
+ PFONTDEV pfntdev,
+ ULONG cFiles,
+ ULONG_PTR *piFile,
+ PVOID *ppvView,
+ ULONG *pcjView,
+ DESIGNVECTOR *pdv,
+ ULONG ulLangID,
+ ULONG ulFastCheckSum)
+{
+ HFF hff;
+ ASSERT(gbAttachedCSRSS);
+
+ /* Call the drivers DrvLoadFontFile function */
+ hff = pfntdev->pldev->pfn.LoadFontFile(cFiles,
+ piFile,
+ ppvView,
+ pcjView,
+ pdv,
+ ulLangID,
+ ulFastCheckSum);
+
+ if (hff == 0) return 0;
+
+ return hff;
+
+}
+
+#if 0
+EngLoadFontFileFD(
+ PPFF ppff,
+{
+ KAPC_STATE ApcState;
+ ULONG_PTR aiFile[FD_MAX_FILES];
+ PVOID apvView[FD_MAX_FILES];
+ ULONG acjView[FD_MAX_FILES];
+ ULONG ulLangID = 0;
+ HFF hff = 0;
+
+ /* Loop all files */
+ for (i = 0; i < ppff->cFiles; i++)
+ {
+ /* Setup the file array */
+ aiFile[i] = (ULONG_PTR)ppff->ppfv[i];
+
+ /* Map the font file */
+ bResult = EngMapFontFileFD(aiFile[i], &apvView[i], &acjView[i]);
+ }
+
+ /* Attach to CSRSS */
+ AttachCSRSS(&ApcState);
+
+ /* Loop all installed font drivers */
+ for (pfntdev = gleFontDriverList.Flink;
+ pfntdev != &gleFontDriverList;
+ pfntdev = pfntdev->leLink.Flink)
+ {
+ /* Try to load the font file */
+ hff = FONTDEV_LoadFontFile(pfntdev,
+ cFiles,
+ aiFile,
+ apvView,
+ acjView,
+ pdv,
+ ulLangID,
+ ppff->ulCheckSum);
+ if (hff)
+ {
+ ppff->hff = hff;
+ break;
+ }
+ }
+
+ /* Detach from CSRSS */
+ DetachCSRSS(&ApcState)
+
+}
+#endif
+
+BOOL
+EngLoadFontDriver(
+ IN PWSTR pwszDriverName)
+{
+ PLDEVOBJ pldev;
+ PFONTDEV pfntdev;
+
+ /* Load the driver */
+ pldev = EngLoadImageEx(pwszDriverName, LDEV_FONT);
+ if (!pldev)
+ {
+ DPRINT1("Failed to load freetype font driver\n");
+ return FALSE;
+ }
+
+ // CHECK if all functions are there
+
+
+ /* Allocate a FONTDEV structure */
+ pfntdev = EngAllocMem(0, sizeof(FONTDEV), 'vdfG');
+ if (!pfntdev)
+ {
+ DPRINT1("Failed to allocate FONTDEV structure\n");
+ EngUnloadImage(pldev);
+ return FALSE;
+ }
+
+ pfntdev->pldev = pldev;
+
+ /* Call the drivers DrvEnablePDEV function */
+ pfntdev->dhpdev = pldev->pfn.EnablePDEV(NULL,
+ NULL,
+ HS_DDI_MAX,
+ pfntdev->ahsurf,
+ sizeof(GDIINFO),
+ &pfntdev->gdiinfo,
+ sizeof(DEVINFO),
+ &pfntdev->devinfo,
+ (HDEV)pfntdev,
+ NULL,
+ NULL);
+
+ /* Call the drivers DrvCompletePDEV function */
+ pldev->pfn.CompletePDEV(pfntdev->dhpdev, (HDEV)pfntdev);
+
+ /* Insert the driver into the list */
+ EngAcquireSemaphore(ghsemFontDriver);
+ InsertTailList(&gleFontDriverList, &pfntdev->leLink);
+ EngReleaseSemaphore(ghsemFontDriver);
+
+ return TRUE;
+}
+
+VOID
+NTAPI
+GreStartupFontDrivers(VOID)
+{
+ /* Load freetype font driver */
+ if (!EngLoadFontDriver(L"ftfd.dll"))
+ {
+ DPRINT1("Could not load freetype font driver\n");
+ KeBugCheck(VIDEO_DRIVER_INIT_FAILURE);
+ }
+
+
+ /* TODO: Enumerate installed font drivers */
+ DPRINT1("############ Started font drivers\n");
+}
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fntdrvsup.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontdata.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontdata.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontdata.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,149 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiGetFontData(
+ IN HDC hdc,
+ IN DWORD dwTable,
+ IN DWORD dwOffset,
+ OUT OPTIONAL PVOID pvBuf,
+ IN ULONG cjBuf)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetWidthTable(
+ IN HDC hdc,
+ IN ULONG cSpecial,
+ IN WCHAR *pwc,
+ IN ULONG cwc,
+ OUT USHORT *psWidth,
+ OUT OPTIONAL WIDTHDATA *pwd,
+ OUT FLONG *pflInfo)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+INT
+APIENTRY
+NtGdiGetTextFaceW(
+ IN HDC hdc,
+ IN INT cChar,
+ OUT OPTIONAL LPWSTR pszOut,
+ IN BOOL bAliasName)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+INT
+APIENTRY
+NtGdiGetTextCharsetInfo(
+ IN HDC hdc,
+ OUT OPTIONAL LPFONTSIGNATURE lpSig,
+ IN DWORD dwFlags)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+DWORD
+APIENTRY
+NtGdiGetFontUnicodeRanges(
+ IN HDC hdc,
+ OUT OPTIONAL LPGLYPHSET pgs)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+DWORD
+APIENTRY
+NtGdiGetGlyphIndicesW(
+ IN HDC hdc,
+ IN OPTIONAL LPWSTR pwc,
+ IN INT cwc,
+ OUT OPTIONAL LPWORD pgi,
+ IN DWORD iMode)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+DWORD
+APIENTRY
+NtGdiGetGlyphIndicesWInternal(
+ IN HDC hdc,
+ IN OPTIONAL LPWSTR pwc,
+ IN INT cwc,
+ OUT OPTIONAL LPWORD pgi,
+ IN DWORD iMode,
+ IN BOOL bSubset)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiGetKerningPairs(
+ IN HDC hdc,
+ IN ULONG cPairs,
+ OUT OPTIONAL KERNINGPAIR *pkpDst)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetRealizationInfo(
+ IN HDC hdc,
+ OUT PREALIZATION_INFO pri,
+ IN HFONT hf)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiGetGlyphOutline(
+ IN HDC hdc,
+ IN WCHAR wch,
+ IN UINT iFormat,
+ OUT LPGLYPHMETRICS pgm,
+ IN ULONG cjBuf,
+ OUT OPTIONAL PVOID pvBuf,
+ IN LPMAT2 pmat2,
+ IN BOOL bIgnoreRotation)
+{
+ ASSERT(FALSE);
+ return 0;
+}
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontdata.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontrsrc.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontrsrc.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontrsrc.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,307 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE: Font resource handling
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+HSEMAPHORE ghsemPFFList;
+PPFF gppffList;
+LIST_ENTRY glePFFList = {&glePFFList, &glePFFList};
+
+
+static
+BOOL
+ComparePFF(
+ PPFF ppff,
+ ULONG cFiles,
+ PFONTFILEVIEW pffv[])
+{
+ ULONG i;
+ ASSERT(cFiles >= 1 && cFiles <= FD_MAX_FILES);
+
+ /* Check if number of files matches */
+ if (ppff->cFiles != cFiles) return FALSE;
+
+ /* Loop all files */
+ for (i = 0; i < cFiles; i++)
+ {
+ /* Check if the files match */
+ if (pffv[i] != ppff->ppfv[i]) return FALSE;
+ }
+
+ return TRUE;
+}
+
+PPFF
+NTAPI
+EngLoadFontFile(
+ IN PWCHAR apwszFiles[],
+ IN ULONG cFiles)
+{
+ PFONTFILEVIEW apffv[FD_MAX_FILES];
+ PLIST_ENTRY ple;
+ PPFF ppff;
+ ULONG i, cjSize;
+
+ /* Loop the files */
+ for (i = 0; i < cFiles; i++)
+ {
+ /* Try to load the file */
+ apffv[i] = (PVOID)EngLoadModuleEx(apwszFiles[i], 0, FVF_FONTFILE);
+ if (!apffv[i])
+ {
+ /* Cleanup and return */
+ while (i--) EngFreeModule(apffv[i]);
+ return NULL;
+ }
+ }
+
+ /* Acquire PFF list lock */
+ EngAcquireSemaphore(ghsemPFFList);
+
+ /* Loop all physical font files (PFF) */
+ for (ple = glePFFList.Flink; ple != &glePFFList; ple = ple->Flink)
+ {
+ ppff = CONTAINING_RECORD(ple, PFF, leLink);
+
+ /* Check if the files are already loaded */
+ if (ComparePFF(ppff, cFiles, apffv))
+ {
+ /* Unload the loaded files */
+ while (i--) EngFreeModule(apffv[i]);
+ goto leave;
+ }
+ }
+
+ /* Allocate a new PFF */
+ cjSize = sizeof(PFF) + cFiles * sizeof(PVOID);
+ ppff = EngAllocMem(0, cjSize, 'ffpG');
+ if (!ppff)
+ {
+ goto leave;
+ }
+
+ ppff->sizeofThis = cjSize;
+ ppff->cFiles = cFiles;
+ ppff->ppfv = (PVOID)(ppff + 1);
+
+ /* Copy the FONTFILEVIEWs */
+ for (i = 0; i < cFiles; i++) ppff->ppfv[i] = apffv[i];
+
+ /* Insert the PFF into the list */
+ InsertTailList(&glePFFList, &ppff->leLink);
+
+leave:
+ /* Release PFF list lock */
+ EngReleaseSemaphore(ghsemPFFList);
+
+ return ppff;
+}
+
+INT
+NTAPI
+GreAddFontResourceInternal(
+ IN PWCHAR apwszFiles[],
+ IN ULONG cFiles,
+ IN FLONG f,
+ IN DWORD dwPidTid,
+ IN OPTIONAL DESIGNVECTOR *pdv)
+{
+
+
+ ASSERT(FALSE);
+ return 0;
+}
+
+static
+BOOL
+SeperateFileNames(
+ PWCHAR apwszFiles[],
+ PWCHAR pwcDest,
+ PWCHAR pwszFiles,
+ ULONG cwc,
+ ULONG cFiles)
+{
+ PWCHAR pwszEnd = pwszFiles + cwc;
+ WCHAR wc;
+ ULONG i = 0;
+
+ apwszFiles[0] = pwcDest;
+
+ /* Loop the file name string */
+ while (pwszFiles < pwszEnd)
+ {
+ wc = *pwszFiles++;
+
+ /* Must not be terminated before the end */
+ if (wc == 0) return FALSE;
+
+ /* Check for a seperator */
+ if (wc == '|')
+ {
+ /* Zero terminate current path name */
+ *pwcDest++ = 0;
+
+ /* Go to next file name and check if its too many */
+ if (++i >= cFiles) return FALSE;
+ apwszFiles[i] = pwcDest;
+ }
+ else
+ {
+ *pwcDest++ = wc;
+ }
+ }
+
+ /* Must be terminated now */
+ if (*pwszFiles != 0 || i != cFiles - 1)
+ {
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+
+W32KAPI
+INT
+APIENTRY
+NtGdiAddFontResourceW(
+ IN WCHAR *pwszFiles,
+ IN ULONG cwc,
+ IN ULONG cFiles,
+ IN FLONG fl,
+ IN DWORD dwPidTid,
+ IN OPTIONAL DESIGNVECTOR *pdv)
+{
+ PVOID pvBuffer;
+ PWCHAR apwszFiles[FD_MAX_FILES];
+ ULONG cjSize;
+ DESIGNVECTOR dv;
+ INT iRes = 0;
+
+ /* Check parameters */
+ if (cFiles > FD_MAX_FILES || cwc < 3 || cwc > FD_MAX_FILES * MAX_PATH)
+ {
+ return 0;
+ }
+
+ /* Allocate a buffer */
+ pvBuffer = EngAllocMem(0, (cwc + 1) * sizeof(WCHAR), 'pmTG');
+ if (!pvBuffer)
+ {
+ return 0;
+ }
+
+ _SEH2_TRY
+ {
+ ProbeForRead(pwszFiles, cwc * sizeof(WCHAR), 2);
+ if (!SeperateFileNames(apwszFiles, pvBuffer, pwszFiles, cwc, cFiles))
+ {
+ _SEH2_YIELD(goto cleanup);
+ }
+
+ /* Check if we have a DESIGNVECTOR */
+ if (pdv)
+ {
+ /* Probe and check first 2 fields */
+ ProbeForRead(pdv, 2 * sizeof(DWORD), sizeof(DWORD));
+ if (pdv->dvReserved != STAMP_DESIGNVECTOR ||
+ pdv->dvNumAxes > MM_MAX_NUMAXES)
+ {
+ _SEH2_YIELD(goto cleanup);
+ }
+
+ /* Copy the vector */
+ cjSize = FIELD_OFFSET(DESIGNVECTOR, dvValues) + pdv->dvNumAxes *
sizeof(LONG);
+ ProbeForRead(pdv, cjSize, sizeof(DWORD));
+ RtlCopyMemory(&dv, pdv, cjSize);
+ pdv = &dv;
+ }
+ }
+ _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER)
+ {
+ _SEH2_YIELD(goto cleanup);
+ }
+ _SEH2_END
+
+ /* Call the internal function */
+ iRes = GreAddFontResourceInternal(apwszFiles, cFiles, fl, dwPidTid, pdv);
+
+cleanup:
+ EngFreeMem(pvBuffer);
+
+ return iRes;
+}
+
+W32KAPI
+HANDLE
+APIENTRY
+NtGdiAddFontMemResourceEx(
+ IN PVOID pvBuffer,
+ IN DWORD cjBuffer,
+ IN DESIGNVECTOR *pdv,
+ IN ULONG cjDV,
+ OUT DWORD *pNumFonts)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiRemoveFontResourceW(
+ IN WCHAR *pwszFiles,
+ IN ULONG cwc,
+ IN ULONG cFiles,
+ IN ULONG fl,
+ IN DWORD dwPidTid,
+ IN OPTIONAL DESIGNVECTOR *pdv)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiRemoveFontMemResourceEx(
+ IN HANDLE hMMFont)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiUnmapMemFont(
+ IN PVOID pvView)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetFontResourceInfoInternalW(
+ IN LPWSTR pwszFiles,
+ IN ULONG cwc,
+ IN ULONG cFiles,
+ IN UINT cjIn,
+ OUT LPDWORD pdwBytes,
+ OUT LPVOID pvBuf,
+ IN DWORD iType)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/fontrsrc.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/lfont.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/lfont.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/lfont.c [iso-8859-1] Sat
May 28 16:54:10 2011
@@ -1,0 +1,97 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+INT
+FASTCALL
+LFONT_GetObject(PLFONT plfnt, INT cjSize, PVOID pvBuffer)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+HFONT
+NTAPI
+GreHfontCreate(
+ IN ENUMLOGFONTEXDVW *pelfw,
+ IN ULONG cjElfw,
+ IN LFTYPE lft,
+ IN FLONG fl,
+ IN PVOID pvCliData)
+{
+ PLFONT plfnt;
+ HFONT hfont;
+
+ /* Allocate an LFONT object */
+ plfnt = (PLFONT)GDIOBJ_AllocObjWithHandle(GDIObjType_LFONT_TYPE << 16,
sizeof(LFONT));
+ if (!plfnt)
+ {
+ DPRINT1("Could not allocate LFONT object\n");
+ return 0;
+ }
+
+ /* Get the handle */
+ hfont = plfnt->baseobj.hHmgr;
+
+ /* Set the fields */
+ plfnt->lft = lft;
+ plfnt->fl = fl;
+ plfnt->elfexw = *pelfw;
+
+ /* Set client data */
+ GDIOBJ_vSetObjectAttr(&plfnt->baseobj, pvCliData);
+
+ /* Unlock the object */
+ GDIOBJ_vUnlockObject(&plfnt->baseobj);
+
+ /* Return the handle */
+ return hfont;
+}
+
+
+W32KAPI
+HFONT
+APIENTRY
+NtGdiHfontCreate(
+ IN ENUMLOGFONTEXDVW *pelfw,
+ IN ULONG cjElfw,
+ IN LFTYPE lft,
+ IN FLONG fl,
+ IN PVOID pvCliData)
+{
+ ENUMLOGFONTEXDVW elfw;
+
+ if (!pelfw)
+ {
+ DPRINT1("NtGdiHfontCreate: pelfw == NULL\n");
+ return NULL;
+ }
+
+ /* Set maximum logfont size */
+ if (cjElfw > sizeof(elfw)) cjElfw = sizeof(elfw);
+
+ /* Enter SEH for buffer copy */
+ _SEH2_TRY
+ {
+ ProbeForRead(pelfw, cjElfw, 1);
+ RtlCopyMemory(&elfw, pelfw, cjElfw);
+ }
+ _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER)
+ {
+ _SEH2_YIELD(return NULL;)
+ }
+ _SEH2_END
+
+ /* Call internal function */
+ return GreHfontCreate(&elfw, cjElfw, lft, fl, pvCliData);
+}
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/lfont.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/misc.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/misc.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/misc.c [iso-8859-1] Sat
May 28 16:54:10 2011
@@ -1,0 +1,227 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiAnyLinkedFonts(VOID)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+
+W32KAPI
+INT
+APIENTRY
+NtGdiSetupPublicCFONT(
+ IN HDC hdc,
+ IN OPTIONAL HFONT hf,
+ IN ULONG ulAve)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+PVOID
+APIENTRY
+EngFntCacheAlloc(IN ULONG FastCheckSum,
+ IN ULONG ulSize)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+VOID
+APIENTRY
+EngFntCacheFault(IN ULONG ulFastCheckSum,
+ IN ULONG iFaultMode)
+{
+ ASSERT(FALSE);
+}
+
+PVOID
+APIENTRY
+EngFntCacheLookUp(IN ULONG FastCheckSum,
+ OUT PULONG pulSize)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiQueryFontAssocInfo(
+ IN HDC hdc)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiMakeFontDir(
+ IN FLONG flEmbed,
+ OUT PBYTE pjFontDir,
+ IN unsigned cjFontDir,
+ IN LPWSTR pwszPathname,
+ IN unsigned cjPathname)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiAddRemoteMMInstanceToDC(
+ IN HDC hdc,
+ IN DOWNLOADDESIGNVECTOR *pddv,
+ IN ULONG cjDDV)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiFontIsLinked(
+ IN HDC hdc)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetRasterizerCaps(
+ OUT LPRASTERIZER_STATUS praststat,
+ IN ULONG cjBytes)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiChangeGhostFont(
+ IN KERNEL_PVOID *pfontID,
+ IN BOOL bLoad)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiEudcLoadUnloadLink(
+ IN OPTIONAL LPCWSTR pBaseFaceName,
+ IN UINT cwcBaseFaceName,
+ IN LPCWSTR pEudcFontPath,
+ IN UINT cwcEudcFontPath,
+ IN INT iPriority,
+ IN INT iFontLinkType,
+ IN BOOL bLoadLin)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+
+// *********** hacks
+
+ULONG
+FASTCALL
+ftGdiGetGlyphOutline(
+ PDC dc,
+ WCHAR wch,
+ UINT iFormat,
+ LPGLYPHMETRICS pgm,
+ ULONG cjBuf,
+ PVOID pvBuf,
+ LPMAT2 pmat2,
+ BOOL bIgnoreRotation)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+int APIENTRY
+NtGdiGetFontFamilyInfo(HDC Dc,
+ LPLOGFONTW UnsafeLogFont,
+ PFONTFAMILYINFO UnsafeInfo,
+ DWORD Size)
+{
+ return 0;
+}
+
+NTSTATUS FASTCALL
+TextIntCreateFontIndirect(CONST LPLOGFONTW lf, HFONT *NewFont)
+{
+ *NewFont = GreHfontCreate((PVOID)lf, sizeof(LOGFONTW), 0, 0, 0);
+ if (*NewFont) return STATUS_SUCCESS;
+ return STATUS_UNSUCCESSFUL;
+}
+
+NTSTATUS
+FASTCALL
+TextIntRealizeFont(HFONT FontHandle, PTEXTOBJ pTextObj)
+{
+ ASSERT(FALSE);
+ return -1;
+}
+
+DWORD
+FASTCALL
+IntGetCharDimensions(HDC hdc, PTEXTMETRICW ptm, PDWORD height)
+{
+ ASSERT(FALSE);
+ return -1;
+}
+
+INT
+FASTCALL
+ftGdiGetTextCharsetInfo(
+ PDC Dc,
+ LPFONTSIGNATURE lpSig,
+ DWORD dwFlags)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+DWORD
+FASTCALL
+IntGetFontLanguageInfo(PDC Dc)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+PTEXTOBJ
+FASTCALL
+RealizeFontInit(HFONT hFont)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/misc.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/rfont.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/rfont.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/rfont.c [iso-8859-1] Sat
May 28 16:54:10 2011
@@ -1,0 +1,126 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+ULONG
+APIENTRY
+FONTOBJ_cGetAllGlyphHandles (
+ IN FONTOBJ *FontObj,
+ IN HGLYPH *Glyphs
+ )
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+ULONG
+APIENTRY
+FONTOBJ_cGetGlyphs(
+ IN FONTOBJ *FontObj,
+ IN ULONG Mode,
+ IN ULONG NumGlyphs,
+ IN HGLYPH *GlyphHandles,
+ IN PVOID *OutGlyphs)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+IFIMETRICS*
+APIENTRY
+FONTOBJ_pifi(IN FONTOBJ *pfo)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+PVOID
+APIENTRY
+FONTOBJ_pvTrueTypeFontFile(
+ IN FONTOBJ *FontObj,
+ IN ULONG *FileSize)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+#undef XFORMOBJ
+WIN32KAPI
+XFORMOBJ*
+APIENTRY
+FONTOBJ_pxoGetXform(
+ IN FONTOBJ *pfo)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+/*
+ * @unimplemented
+ */
+VOID
+APIENTRY
+FONTOBJ_vGetInfo(
+ IN FONTOBJ *FontObj,
+ IN ULONG InfoSize,
+ OUT PFONTINFO FontInfo)
+{
+ ASSERT(FALSE);
+}
+
+/*
+ * @unimplemented
+ */
+FD_GLYPHSET * APIENTRY
+FONTOBJ_pfdg(
+ IN FONTOBJ *FontObj)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+/*
+ * @unimplemented
+ */
+PBYTE APIENTRY
+FONTOBJ_pjOpenTypeTablePointer(
+ IN FONTOBJ *FontObj,
+ IN ULONG Tag,
+ OUT ULONG *Table)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+/*
+ * @unimplemented
+ */
+PFD_GLYPHATTR APIENTRY
+FONTOBJ_pQueryGlyphAttrs(
+ IN FONTOBJ *FontObj,
+ IN ULONG Mode)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
+
+/*
+ * @unimplemented
+ */
+LPWSTR APIENTRY
+FONTOBJ_pwszFontFilePaths(
+ IN FONTOBJ *FontObj,
+ OUT ULONG *PathLength)
+{
+ ASSERT(FALSE);
+ return NULL;
+}
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/rfont.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/strobj.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/strobj.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/strobj.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,84 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+
+BOOL
+APIENTRY
+STROBJ_bEnum(
+ IN STROBJ *pstro,
+ OUT ULONG *pc,
+ OUT PGLYPHPOS *ppgpos)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+DWORD
+APIENTRY
+STROBJ_dwGetCodePage(IN STROBJ *pstro)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+VOID
+APIENTRY
+STROBJ_vEnumStart(IN STROBJ *pstro)
+{
+ ASSERT(FALSE);
+}
+
+BOOL
+APIENTRY
+STROBJ_bEnumPositionsOnly(
+ IN STROBJ *StringObj,
+ OUT ULONG *Count,
+ OUT PGLYPHPOS *Pos)
+{
+ ASSERT(FALSE);
+ return (BOOL) DDI_ERROR;
+}
+
+ENGAPI
+BOOL
+APIENTRY
+STROBJ_bGetAdvanceWidths(
+ STROBJ *pso,
+ ULONG iFirst,
+ ULONG c,
+ POINTQF *pptqD)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+ENGAPI
+FIX
+APIENTRY
+STROBJ_fxBreakExtra(
+ STROBJ *pstro)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+ENGAPI
+FIX
+APIENTRY
+STROBJ_fxCharacterExtra(
+ STROBJ *pstro)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/strobj.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textmetric.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textmetric.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textmetric.c
[iso-8859-1] Sat May 28 16:54:10 2011
@@ -1,0 +1,136 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetTextMetricsW(
+ IN HDC hdc,
+ OUT TMW_INTERNAL * ptm,
+ IN ULONG cj)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetETM(
+ IN HDC hdc,
+ OUT EXTTEXTMETRIC *petm)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetCharABCWidthsW(
+ IN HDC hdc,
+ IN UINT wchFirst,
+ IN ULONG cwch,
+ IN OPTIONAL PWCHAR pwch,
+ IN FLONG fl,
+ OUT PVOID pvBuf)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+DWORD
+APIENTRY
+NtGdiGetCharacterPlacementW(
+ IN HDC hdc,
+ IN LPWSTR pwsz,
+ IN INT nCount,
+ IN INT nMaxExtent,
+ IN OUT LPGCP_RESULTSW pgcpw,
+ IN DWORD dwFlags)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetCharWidthW(
+ IN HDC hdc,
+ IN UINT wcFirst,
+ IN UINT cwc,
+ IN OPTIONAL PWCHAR pwc,
+ IN FLONG fl,
+ OUT PVOID pvBuf)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetCharWidthInfo(
+ IN HDC hdc,
+ OUT PCHWIDTHINFO pChWidthInfo)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+ULONG
+APIENTRY
+NtGdiGetOutlineTextMetricsInternalW(
+ IN HDC hdc,
+ IN ULONG cjotm,
+ OUT OPTIONAL OUTLINETEXTMETRICW *potmw,
+ OUT TMDIFF *ptmd)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetTextExtent(
+ IN HDC hdc,
+ IN LPWSTR lpwsz,
+ IN INT cwc,
+ OUT LPSIZE psize,
+ IN UINT flOpts)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetTextExtentExW(
+ IN HDC hdc,
+ IN OPTIONAL LPWSTR lpwsz,
+ IN ULONG cwc,
+ IN ULONG dxMax,
+ OUT OPTIONAL ULONG *pcCh,
+ OUT OPTIONAL PULONG pdxOut,
+ OUT LPSIZE psize,
+ IN FLONG fl)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textmetric.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textout.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textout.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textout.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,111 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE: Text output
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+/*
+ * @unimplemented
+ */
+BOOL
+APIENTRY
+EngTextOut (
+ SURFOBJ *pso,
+ STROBJ *pstro,
+ FONTOBJ *pfo,
+ CLIPOBJ *pco,
+ RECTL *prclExtra,
+ RECTL *prclOpaque,
+ BRUSHOBJ *pboFore,
+ BRUSHOBJ *pboOpaque,
+ POINTL *pptlOrg,
+ MIX mix
+ )
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+BOOL
+APIENTRY
+GreExtTextOutW(
+ IN HDC hDC,
+ IN INT XStart,
+ IN INT YStart,
+ IN UINT fuOptions,
+ IN OPTIONAL PRECTL lprc,
+ IN LPWSTR String,
+ IN INT Count,
+ IN OPTIONAL LPINT Dx,
+ IN DWORD dwCodePage)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiExtTextOutW(
+ IN HDC hdc,
+ IN INT x,
+ IN INT y,
+ IN UINT flOpts,
+ IN OPTIONAL LPRECT prcl,
+ IN LPWSTR pwsz,
+ IN INT cwc,
+ IN OPTIONAL LPINT pdx,
+ IN DWORD dwCodePage)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+
+BOOL
+APIENTRY
+NtGdiPolyTextOutW(
+ IN HDC hdc,
+ IN POLYTEXTW *pptw,
+ IN UINT cStr,
+ IN DWORD dwCodePage)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+
+W32KAPI
+UINT
+APIENTRY
+NtGdiGetStringBitmapW(
+ IN HDC hdc,
+ IN LPWSTR pwsz,
+ IN UINT cwc,
+ OUT BYTE *lpSB,
+ IN UINT cj)
+{
+ ASSERT(FALSE);
+ return 0;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiConsoleTextOut(
+ IN HDC hdc,
+ IN POLYTEXTW *lpto,
+ IN UINT nStrings,
+ IN RECTL *prclBounds)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/textout.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/ufi.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/ufi.c (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/ufi.c [iso-8859-1] Sat
May 28 16:54:10 2011
@@ -1,0 +1,120 @@
+/*
+ * PROJECT: ReactOS win32 subsystem
+ * LICENSE: GPL - See COPYING in the top level directory
+ * PURPOSE:
+ * PROGRAMMER: Timo Kreuzer (timo.kreuzer(a)reactos.org)
+ */
+
+#include <win32k.h>
+#include <include/font.h>
+
+#define NDEBUG
+#include <debug.h>
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetUFI(
+ IN HDC hdc,
+ OUT PUNIVERSAL_FONT_ID pufi,
+ OUT OPTIONAL DESIGNVECTOR *pdv,
+ OUT ULONG *pcjDV,
+ OUT ULONG *pulBaseCheckSum,
+ OUT FLONG *pfl)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetEmbUFI(
+ IN HDC hdc,
+ OUT PUNIVERSAL_FONT_ID pufi,
+ OUT OPTIONAL DESIGNVECTOR *pdv,
+ OUT ULONG *pcjDV,
+ OUT ULONG *pulBaseCheckSum,
+ OUT FLONG *pfl,
+ OUT KERNEL_PVOID *embFontID)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiGetUFIPathname(
+ IN PUNIVERSAL_FONT_ID pufi,
+ OUT OPTIONAL ULONG* pcwc,
+ OUT OPTIONAL LPWSTR pwszPathname,
+ OUT OPTIONAL ULONG* pcNumFiles,
+ IN FLONG fl,
+ OUT OPTIONAL BOOL *pbMemFont,
+ OUT OPTIONAL ULONG *pcjView,
+ OUT OPTIONAL PVOID pvView,
+ OUT OPTIONAL BOOL *pbTTC,
+ OUT OPTIONAL ULONG *piTTC)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiSetLinkedUFIs(
+ IN HDC hdc,
+ IN PUNIVERSAL_FONT_ID pufiLinks,
+ IN ULONG uNumUFIs)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+INT
+APIENTRY
+NtGdiGetLinkedUFIs(
+ IN HDC hdc,
+ OUT OPTIONAL PUNIVERSAL_FONT_ID pufiLinkedUFIs,
+ IN INT BufferSize)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiForceUFIMapping(
+ IN HDC hdc,
+ IN PUNIVERSAL_FONT_ID pufi)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+BOOL
+APIENTRY
+NtGdiRemoveMergeFont(
+ IN HDC hdc,
+ IN UNIVERSAL_FONT_ID *pufi)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
+
+W32KAPI
+INT
+APIENTRY
+NtGdiQueryFonts(
+ OUT PUNIVERSAL_FONT_ID pufiFontList,
+ IN ULONG nBufferSize,
+ OUT PLARGE_INTEGER pTimeStamp)
+{
+ ASSERT(FALSE);
+ return FALSE;
+}
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/font/ufi.c
------------------------------------------------------------------------------
svn:eol-style = native
Added: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/font.h
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/font.h (added)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/font.h [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -1,0 +1,218 @@
+
+#define LFONT_GetObject FontGetObject
+
+#define ENGAPI
+
+#define FD_MAX_FILES 4
+
+extern PEPROCESS gpepCSRSS;
+
+typedef struct _POINTEF
+{
+ FLOATOBJ x;
+ FLOATOBJ y;
+} POINTEF, *PPOINTEF;
+
+typedef struct _RFONT *PRFONT;
+
+typedef struct _PFF
+{
+ ULONG sizeofThis;
+ LIST_ENTRY leLink;
+ PWSTR pwszPathname;
+ ULONG cwc;
+ ULONG cFiles;
+ FLONG flState;
+ ULONG cLoaded;
+ ULONG cNotEnum;
+ ULONG cRFONT;
+ PRFONT prfntList;
+ HFF hff;
+ HDEV hdev;
+ DHPDEV dhpdev;
+ void *pfhFace;
+ void *pfhFamily;
+ void *pfhUFI;
+ struct _PFT *pPFT;
+ ULONG ulCheckSum;
+ ULONG cFonts;
+ PFONTFILEVIEW *ppfv;
+ void *pPvtDataHead;
+} PFF, *PPFF;
+
+typedef struct _PFE
+{
+ PFF * pPFF;
+ ULONG_PTR iFont;
+ FLONG flPFE;
+ FD_GLYPHSET * pfdg;
+ ULONG_PTR ulpId;
+ IFIMETRICS * pifi;
+ ULONG_PTR idifi;
+ FD_KERNINGPAIR *pkp;
+ ULONG_PTR idkp;
+ ULONG ckp;
+ ULONG iOrieintation;
+ ULONG cjEfdwPFE;
+ //GISET * pgiset;
+ ULONG ulTimeStamp;
+ UNIVERSAL_FONT_ID ufi;
+ DWORD pid;
+ DWORD tid;
+ LIST_ENTRY ql;
+ void * pFlEntry;
+ ULONG cAlt;
+ ULONG cPfdgRef;
+ ULONG aiFamilyName[1];
+} PFE, *PPFE;
+
+typedef struct
+{
+ PRFONT prfntPrev;
+ PRFONT prfntNext;
+} RFONTLINK, *PRFONTLINK;
+
+typedef struct _CACHE
+{
+ GLYPHDATA *pgdNext;
+ GLYPHDATA *pgdThreshold;
+ PBYTE pjFirstBlockEnd;
+ void *pdblBase;
+ ULONG cMetrics;
+ ULONG cjbbl;
+ ULONG cBlocksMax;
+ ULONG cBlocks;
+ ULONG cGlyphs;
+ ULONG cjTotal;
+ void * pbblBase;
+ void * pbblCur;
+ GLYPHBITS * pgbNext;
+ GLYPHBITS * pgbThreshold;
+ PBYTE pjAuxCacheMem;
+ ULONG cjAuxCacheMem;
+ ULONG cjGlyphMax;
+ BOOL bSmallMetrics;
+ ULONG iMax;
+ ULONG iFirst;
+ ULONG cBits;
+} CACHE;
+
+typedef struct _RFONT
+{
+ FONTOBJ fobj;
+
+ HDEV hdevProducer;
+ HDEV hdevConsumer;
+ DHPDEV dhpdev;
+
+ PFE * ppfe;
+ PFF * pPFF;
+ RFONTLINK rflPDEV;
+ RFONTLINK rflPFF;
+ PRFONT prfntSystemTT;
+ PRFONT prfntSysEUDC;
+ PRFONT prfntDefEUDC;
+ PRFONT *paprfntFaceName;
+ PRFONT aprfntQuickBuff[8];
+
+ FLONG flType;
+ FLONG flInfo;
+ FLONG flEUDCState;
+ ULONG ulContent;
+ ULONG ulTimeStamp;
+ ULONG uiNumLinks;
+ ULONG iGraphicsMode;
+ ULONG ulOrientation;
+ ULONG cBitsPerPel;
+ BOOL bVertical;
+ BOOL bDeviceFont;
+ BOOL bIsSystemFont;
+ BOOL bNeededPaths;
+ BOOL bFilledEudcArray;
+
+
+ FD_XFORM fdx;
+ FD_DEVICEMETRICS fddm;
+ FIX fxMaxExtent;
+ POINTFX ptfxMaxAscent;
+ POINTFX ptfxMaxDescent;
+ TEXTMETRICW *ptmw;
+ FD_GLYPHSET *pfdg;
+ HGLYPH *phg;
+ HGLYPH hgBreak;
+ FIX fxBreak;
+ void *wcgp;
+
+
+ MATRIX mxWorldToDevice;
+ MATRIX mxForDDI;
+ //EXFORMOBJ xoForDDI;
+
+ POINTEF pteUnitAscent;
+ FLOATOBJ efWtoDAscent;
+ FLOATOBJ efDtoWAscent;
+
+ POINTEF pteUnitBase;
+ FLOATOBJ efWtoDBase;
+ FLOATOBJ efDtoWBase;
+
+ FLOATOBJ efWtoDEsc;
+ FLOATOBJ efDtoWEsc;
+ FLOATOBJ efEscToBase;
+ FLOATOBJ efEscToAscent;
+ FLOATOBJ efDtoWBase_31;
+ FLOATOBJ efDtoWAscent_31;
+
+ POINTEF eptflNtoWScale;
+
+ ULONG bNtoWIdent;
+ LONG lCharInc;
+ LONG lMaxAscent;
+ LONG lMaxHeight;
+ LONG lAscent;
+ LONG lEscapement;
+ ULONG cSelected;
+
+ HSEMAPHORE hsemCache;
+ HSEMAPHORE hsemCache1;
+ CACHE cache;
+
+ POINTL ptlSim;
+} RFONT;
+
+typedef struct _LFONT
+{
+ BASEOBJECT baseobj;
+ LFTYPE lft;
+ FLONG fl;
+ PPDEVOBJ ppdev;
+ HGDIOBJ hPFE;
+ WCHAR awchFace[LF_FACESIZE];
+ ENUMLOGFONTEXDVW elfexw;
+} LFONT, *PLFONT;
+
+FORCEINLINE
+PLFONT
+LFONT_ShareLockFont(HFONT hfont)
+{
+ return (PLFONT)GDIOBJ_ReferenceObjectByHandle(hfont, GDIObjType_LFONT_TYPE);
+}
+
+FORCEINLINE
+VOID
+LFONT_ShareUnlockFont(PLFONT plfnt)
+{
+ GDIOBJ_vDereferenceObject(&plfnt->baseobj);
+}
+
+
+
+HFONT
+NTAPI
+GreHfontCreate(
+ IN ENUMLOGFONTEXDVW *pelfw,
+ IN ULONG cjElfw,
+ IN LFTYPE lft,
+ IN FLONG fl,
+ IN PVOID pvCliData);
+
Propchange: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/font.h
------------------------------------------------------------------------------
svn:eol-style = native
Modified: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/text.h
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/text.h [iso-8859-1]
(original)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/include/text.h [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -58,21 +58,7 @@
#define TEXTOBJECT_INIT 0x00010000
/* GDI logical font object */
-typedef struct
-{
- /* Header for all gdi objects in the handle table.
- Do not (re)move this. */
- BASEOBJECT BaseObject;
- LFTYPE lft;
- FLONG fl;
- FONTOBJ *Font;
- WCHAR FullName[LF_FULLFACESIZE];
- WCHAR Style[LF_FACESIZE];
- WCHAR FaceName[LF_FACESIZE];
- DWORD dwOffsetEndArray;
-// Fixed:
- ENUMLOGFONTEXDVW logfont;
-} TEXTOBJ, *PTEXTOBJ;
+typedef struct _LFONT TEXTOBJ, *PTEXTOBJ;
/* Internal interface */
Modified: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/ntuser/ntuser.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/ntuser/ntuser.c [iso-8859-1]
(original)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/ntuser/ntuser.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -128,6 +128,9 @@
return STATUS_SUCCESS;
}
+PEPROCESS gpepCSRSS;
+
+VOID NTAPI GreStartupFontDrivers(VOID);
/*
Called from win32csr.
*/
@@ -158,6 +161,9 @@
UserLeave();
return STATUS_UNSUCCESSFUL;
}
+
+ /* Safe CSRSS EPROCESS pointer */
+ gpepCSRSS = PsGetCurrentProcess();
// Initialize Power Request List.
// Initialize Media Change.
@@ -166,6 +172,7 @@
// Startup DxGraphics.
// calls ** IntGdiGetLanguageID() and sets it **.
// Enables Fonts drivers, Initialize Font table & Stock Fonts.
+ GreStartupFontDrivers();
// }
/* Initialize USER */
Modified: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/objects/gdiobj.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/objects/gdiobj.c [iso-8859-1]
(original)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/objects/gdiobj.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -215,7 +215,7 @@
InitLookasideList(GDIObjType_PATH_TYPE, sizeof(PATH));
InitLookasideList(GDIObjType_PAL_TYPE, sizeof(PALETTE));
InitLookasideList(GDIObjType_ICMLCS_TYPE, sizeof(COLORSPACE));
- InitLookasideList(GDIObjType_LFONT_TYPE, sizeof(TEXTOBJ));
+ //InitLookasideList(GDIObjType_LFONT_TYPE, sizeof(TEXTOBJ));
InitLookasideList(GDIObjType_BRUSH_TYPE, sizeof(BRUSH));
return STATUS_SUCCESS;
Modified: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/stubs/stubs.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/stubs/stubs.c [iso-8859-1]
(original)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/stubs/stubs.c [iso-8859-1]
Sat May 28 16:54:10 2011
@@ -6,31 +6,6 @@
#undef XFORMOBJ
#define UNIMPLEMENTED DbgPrint("(%s:%i) WIN32K: %s UNIMPLEMENTED\n", __FILE__,
__LINE__, __FUNCTION__ )
-
-
-
-/*
- * @unimplemented
- */
-BOOL
-APIENTRY
-EngTextOut (
- SURFOBJ *pso,
- STROBJ *pstro,
- FONTOBJ *pfo,
- CLIPOBJ *pco,
- RECTL *prclExtra,
- RECTL *prclOpaque,
- BRUSHOBJ *pboFore,
- BRUSHOBJ *pboOpaque,
- POINTL *pptlOrg,
- MIX mix
- )
-{
- //
www.osr.com/ddk/graphics/gdifncs_4tgn.htm
- UNIMPLEMENTED;
- return FALSE;
-}
/*
* @unimplemented
@@ -399,84 +374,6 @@
return FALSE;
}
-/*
- * @unimplemented
- */
-ULONG
-APIENTRY
-FONTOBJ_cGetAllGlyphHandles (
- IN FONTOBJ *FontObj,
- IN HGLYPH *Glyphs
- )
-{
- UNIMPLEMENTED;
- return 0;
-}
-
-/*
- * @unimplemented
- */
-ULONG
-APIENTRY
-FONTOBJ_cGetGlyphs(
- IN FONTOBJ *FontObj,
- IN ULONG Mode,
- IN ULONG NumGlyphs,
- IN HGLYPH *GlyphHandles,
- IN PVOID *OutGlyphs
- )
-{
- UNIMPLEMENTED;
- return 0;
-}
-
-/*
- * @unimplemented
- */
-IFIMETRICS*
-APIENTRY
-FONTOBJ_pifi ( IN FONTOBJ *FontObj )
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-/*
- * @unimplemented
- */
-PVOID
-APIENTRY
-FONTOBJ_pvTrueTypeFontFile (
- IN FONTOBJ *FontObj,
- IN ULONG *FileSize)
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-/*
- * @unimplemented
- */
-XFORMOBJ*
-APIENTRY
-FONTOBJ_pxoGetXform ( IN FONTOBJ *FontObj )
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-/*
- * @unimplemented
- */
-VOID
-APIENTRY
-FONTOBJ_vGetInfo (
- IN FONTOBJ *FontObj,
- IN ULONG InfoSize,
- OUT PFONTINFO FontInfo)
-{
- UNIMPLEMENTED;
-}
LONG
APIENTRY
@@ -736,53 +633,6 @@
return FileTime;
}
-/*
- * @unimplemented
- */
-FD_GLYPHSET * APIENTRY
-FONTOBJ_pfdg(
- IN FONTOBJ *FontObj)
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-/*
- * @unimplemented
- */
-PBYTE APIENTRY
-FONTOBJ_pjOpenTypeTablePointer(
- IN FONTOBJ *FontObj,
- IN ULONG Tag,
- OUT ULONG *Table)
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-/*
- * @unimplemented
- */
-PFD_GLYPHATTR APIENTRY
-FONTOBJ_pQueryGlyphAttrs(
- IN FONTOBJ *FontObj,
- IN ULONG Mode)
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-/*
- * @unimplemented
- */
-LPWSTR APIENTRY
-FONTOBJ_pwszFontFilePaths(
- IN FONTOBJ *FontObj,
- OUT ULONG *PathLength)
-{
- UNIMPLEMENTED;
- return NULL;
-}
/*
* @unimplemented
@@ -805,17 +655,6 @@
*/
BOOL
APIENTRY
-NtGdiAnyLinkedFonts()
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
-/*
- * @unimplemented
- */
-BOOL
-APIENTRY
NtGdiEnableEudc(BOOL enable)
{
UNIMPLEMENTED;
@@ -823,76 +662,6 @@
}
/*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiAddRemoteFontToDC(
- IN HDC hdc,
- IN PVOID pvBuffer,
- IN ULONG cjBuffer,
- IN OPTIONAL PUNIVERSAL_FONT_ID pufi)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
-/*
- * @unimplemented
- */
-HANDLE
-APIENTRY
-NtGdiAddFontMemResourceEx(
- IN PVOID pvBuffer,
- IN DWORD cjBuffer,
- IN DESIGNVECTOR *pdv,
- IN ULONG cjDV,
- OUT DWORD *pNumFonts
-)
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-/*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiRemoveMergeFont(
- IN HDC hdc,
- IN UNIVERSAL_FONT_ID *pufi)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
-/*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiAddRemoteMMInstanceToDC(
- IN HDC hdc,
- IN DOWNLOADDESIGNVECTOR *pddv,
- IN ULONG cjDDV)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
-/*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiFontIsLinked(IN HDC hdc)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
* @unimplemented
*/
BOOL
@@ -924,24 +693,7 @@
return NULL;
}
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiGetUFI(
- IN HDC hdc,
- OUT PUNIVERSAL_FONT_ID pufi,
- OUT OPTIONAL DESIGNVECTOR *pdv,
- OUT ULONG *pcjDV,
- OUT ULONG *pulBaseCheckSum,
- OUT FLONG *pfl)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
+/*
* @unimplemented
*/
HBRUSH
@@ -1001,22 +753,7 @@
return FALSE;
}
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiConsoleTextOut(
- IN HDC hdc,
- IN POLYTEXTW *lpto,
- IN UINT nStrings,
- IN RECTL *prclBounds)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
+/*
* @unimplemented
*/
BOOL
@@ -1057,84 +794,7 @@
return FALSE;
}
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiEnumFontChunk(
- IN HDC hdc,
- IN ULONG_PTR idEnum,
- IN ULONG cjEfdw,
- OUT ULONG *pcjEfdw,
- OUT PENUMFONTDATAW pefdw)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiEnumFontClose(
- IN ULONG_PTR idEnum)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-ULONG_PTR
-APIENTRY
-NtGdiEnumFontOpen(
- IN HDC hdc,
- IN ULONG iEnumType,
- IN FLONG flWin31Compat,
- IN ULONG cwchMax,
- IN OPTIONAL LPWSTR pwszFaceName,
- IN ULONG lfCharSet,
- OUT ULONG *pulCount)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiEudcLoadUnloadLink(
- IN OPTIONAL LPCWSTR pBaseFaceName,
- IN UINT cwcBaseFaceName,
- IN LPCWSTR pEudcFontPath,
- IN UINT cwcEudcFontPath,
- IN INT iPriority,
- IN INT iFontLinkType,
- IN BOOL bLoadLin)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiForceUFIMapping(
- IN HDC hdc,
- IN PUNIVERSAL_FONT_ID pufi)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
+/*
* @unimplemented
*/
NTSTATUS
@@ -1150,20 +810,7 @@
return FALSE;
}
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiGetCharWidthInfo(
- IN HDC hdc,
- OUT PCHWIDTHINFO pChWidthInfo)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
+/*
* @unimplemented
*/
ULONG_PTR
@@ -1173,19 +820,6 @@
{
UNIMPLEMENTED;
return 0;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiGetETM(
- IN HDC hdc,
- OUT EXTTEXTMETRIC *petm)
-{
- UNIMPLEMENTED;
- return FALSE;
}
/*
@@ -1218,19 +852,6 @@
*/
INT
APIENTRY
-NtGdiQueryFonts( OUT PUNIVERSAL_FONT_ID pufiFontList,
- IN ULONG nBufferSize,
- OUT PLARGE_INTEGER pTimeStamp)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
- * @unimplemented
- */
-INT
-APIENTRY
NtGdiGetSpoolMessage( DWORD u1,
DWORD u2,
DWORD u3,
@@ -1241,38 +862,7 @@
return 0;
}
- /*
- * @unimplemented
- */
-DWORD
-APIENTRY
-NtGdiGetGlyphIndicesWInternal(
- IN HDC hdc,
- IN OPTIONAL LPWSTR pwc,
- IN INT cwc,
- OUT OPTIONAL LPWORD pgi,
- IN DWORD iMode,
- IN BOOL bSubset)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
- * @unimplemented
- */
-INT
-APIENTRY
-NtGdiGetLinkedUFIs(
- IN HDC hdc,
- OUT OPTIONAL PUNIVERSAL_FONT_ID pufiLinkedUFIs,
- IN INT BufferSize)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
+/*
* @unimplemented
*/
HBITMAP
@@ -1318,77 +908,6 @@
*/
BOOL
NtGdiUpdateTransform(IN HDC hdc)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-ULONG
-APIENTRY
-NtGdiQueryFontAssocInfo(
- IN HDC hdc)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
- * @unimplemented
- */
-UINT
-APIENTRY
-NtGdiGetStringBitmapW(
- IN HDC hdc,
- IN LPWSTR pwsz,
- IN UINT cwc,
- OUT BYTE *lpSB,
- IN UINT cj)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiRemoveFontMemResourceEx(
- IN HANDLE hMMFont)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiRemoveFontResourceW(
- IN WCHAR *pwszFiles,
- IN ULONG cwc,
- IN ULONG cFiles,
- IN ULONG fl,
- IN DWORD dwPidTid,
- IN OPTIONAL DESIGNVECTOR *pdv)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiPolyTextOutW(
- IN HDC hdc,
- IN POLYTEXTW *pptw,
- IN UINT cStr,
- IN DWORD dwCodePage)
{
UNIMPLEMENTED;
return FALSE;
@@ -1410,19 +929,6 @@
return STATUS_NOT_IMPLEMENTED;
}
-/*
- * @unimplemented
- */
-INT
-APIENTRY
-NtGdiSetupPublicCFONT(
- IN HDC hdc,
- IN OPTIONAL HFONT hf,
- IN ULONG ulAve)
-{
- UNIMPLEMENTED;
- return 0;
-}
/*
* @unimplemented
@@ -1435,101 +941,6 @@
{
UNIMPLEMENTED;
return NULL;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiGetEmbUFI(
- IN HDC hdc,
- OUT PUNIVERSAL_FONT_ID pufi,
- OUT OPTIONAL DESIGNVECTOR *pdv,
- OUT ULONG *pcjDV,
- OUT ULONG *pulBaseCheckSum,
- OUT FLONG *pfl,
- OUT KERNEL_PVOID *embFontID)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiGetUFIPathname(
- IN PUNIVERSAL_FONT_ID pufi,
- OUT OPTIONAL ULONG* pcwc,
- OUT OPTIONAL LPWSTR pwszPathname,
- OUT OPTIONAL ULONG* pcNumFiles,
- IN FLONG fl,
- OUT OPTIONAL BOOL *pbMemFont,
- OUT OPTIONAL ULONG *pcjView,
- OUT OPTIONAL PVOID pvView,
- OUT OPTIONAL BOOL *pbTTC,
- OUT OPTIONAL ULONG *piTTC)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-ULONG
-APIENTRY
-NtGdiGetEmbedFonts(
- VOID)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiChangeGhostFont(
- IN KERNEL_PVOID *pfontID,
- IN BOOL bLoad)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiAddEmbFontToDC(
- IN HDC hdc,
- IN VOID **pFontID)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiGetWidthTable(
- IN HDC hdc,
- IN ULONG cSpecial,
- IN WCHAR *pwc,
- IN ULONG cwc,
- OUT USHORT *psWidth,
- OUT OPTIONAL WIDTHDATA *pwd,
- OUT FLONG *pflInfo)
-{
- UNIMPLEMENTED;
- return FALSE;
}
/*
@@ -1561,23 +972,7 @@
return TRUE;
}
- /*
- * @unimplemented
- */
-ULONG
-APIENTRY
-NtGdiMakeFontDir(
- IN FLONG flEmbed,
- OUT PBYTE pjFontDir,
- IN unsigned cjFontDir,
- IN LPWSTR pwszPathname,
- IN unsigned cjPathname)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
+/*
* @unimplemented
*/
BOOL
@@ -1600,46 +995,6 @@
{
UNIMPLEMENTED;
return NULL;
-}
-
- /*
- * @unimplemented
- */
-ULONG
-APIENTRY
-NtGdiSetFontEnumeration(
- IN ULONG ulType)
-{
- UNIMPLEMENTED;
- return 0;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiSetFontXform(
- IN HDC hdc,
- IN DWORD dwxScale,
- IN DWORD dwyScale)
-{
- UNIMPLEMENTED;
- return FALSE;
-}
-
- /*
- * @unimplemented
- */
-BOOL
-APIENTRY
-NtGdiSetLinkedUFIs(
- IN HDC hdc,
- IN PUNIVERSAL_FONT_ID pufiLinks,
- IN ULONG uNumUFIs)
-{
- UNIMPLEMENTED;
- return FALSE;
}
/*
@@ -1669,17 +1024,6 @@
return FALSE;
}
- /*
- * @implemented
- */
-BOOL
-APIENTRY
-NtGdiUnmapMemFont(
- IN PVOID pvView)
-{
- return TRUE;
-}
-
BOOL
APIENTRY
EngControlSprites(
@@ -1688,32 +1032,6 @@
{
UNIMPLEMENTED;
return FALSE;
-}
-
-PVOID
-APIENTRY
-EngFntCacheAlloc(IN ULONG FastCheckSum,
- IN ULONG ulSize)
-{
- UNIMPLEMENTED;
- return NULL;
-}
-
-VOID
-APIENTRY
-EngFntCacheFault(IN ULONG ulFastCheckSum,
- IN ULONG iFaultMode)
-{
- UNIMPLEMENTED;
-}
-
-PVOID
-APIENTRY
-EngFntCacheLookUp(IN ULONG FastCheckSum,
- OUT PULONG pulSize)
-{
- UNIMPLEMENTED;
- return NULL;
}
BOOLEAN