Commit ddaacaa0 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

- links can now spread across several elements

- link information is now shared between file & presentation - first try at handling metafiles
parent d1ae0017
......@@ -257,7 +257,8 @@ int main(int argc, char **argv)
if (paragraph->u.text.wFont)
printf(format.end_boldface);
break;
case para_image:
case para_bitmap:
case para_metafile:
break;
}
}
......@@ -332,11 +333,26 @@ HBITMAP WINAPI CreateDIBitmap(HDC hdc, CONST BITMAPINFOHEADER* bih, DWORD a, CON
return 0;
}
HMETAFILE WINAPI SetMetaFileBitsEx(UINT cbBuffer, CONST BYTE *lpbBuffer)
{
return 0;
}
BOOL WINAPI DeleteMetaFile(HMETAFILE h)
{
return 0;
}
HDC WINAPI GetDC(HWND h)
{
return 0;
}
int WINAPI ReleaseDC(HWND h, HDC hdc)
{
return 0;
}
BOOL WINAPI DeleteObject(HGDIOBJ h)
{
return TRUE;
......
......@@ -30,20 +30,21 @@ typedef struct
SIZE size;
int style;
DWORD win_style;
COLORREF sr_color; /* color for scrollable region */
COLORREF sr_color; /* color for scrollable region */
COLORREF nsr_color; /* color for non scrollable region */
} HLPFILE_WINDOWINFO;
typedef struct
{
enum {hlp_link_none, hlp_link_link, hlp_link_popup, hlp_link_macro} cookie;
LPCSTR lpszString;
LONG lHash;
BOOL bClrChange;
unsigned window;
enum {hlp_link_link, hlp_link_popup, hlp_link_macro} cookie;
LPCSTR lpszString; /* name of the file to for the link (NULL if same file) */
LONG lHash; /* topic index */
unsigned bClrChange : 1, /* true if the link is green & underlined */
wRefCount; /* number of internal references to this object */
unsigned window; /* window number for displaying the link (-1 is current) */
} HLPFILE_LINK;
enum para_type {para_normal_text, para_debug_text, para_image};
enum para_type {para_normal_text, para_debug_text, para_bitmap, para_metafile};
typedef struct tagHlpFileParagraph
{
......@@ -61,9 +62,20 @@ typedef struct tagHlpFileParagraph
} text;
struct
{
HBITMAP hBitmap;
unsigned pos; /* 0: center, 1: left, 2: right */
} image;
union
{
struct
{
HBITMAP hBitmap;
} bmp;
struct
{
HMETAFILE hMetaFile;
SIZE mfSize;
} mf;
} u;
} gfx; /* for bitmaps and metafiles */
} u;
HLPFILE_LINK* link;
......@@ -142,4 +154,5 @@ HLPFILE_PAGE* HLPFILE_Contents(HLPFILE* hlpfile);
HLPFILE_PAGE* HLPFILE_PageByHash(HLPFILE* hlpfile, LONG lHash);
HLPFILE_PAGE* HLPFILE_PageByOffset(HLPFILE* hlpfile, LONG offset);
LONG HLPFILE_Hash(LPCSTR lpszContext);
void HLPFILE_FreeLink(HLPFILE_LINK* link);
void HLPFILE_FreeHlpFile(HLPFILE*);
......@@ -40,7 +40,7 @@
typedef struct tagHelpLinePart
{
RECT rect;
enum {hlp_line_part_text, hlp_line_part_image} cookie;
enum {hlp_line_part_text, hlp_line_part_bitmap, hlp_line_part_metafile} cookie;
union
{
struct
......@@ -54,9 +54,13 @@ typedef struct tagHelpLinePart
struct
{
HBITMAP hBitmap;
} image;
} bitmap;
struct
{
HMETAFILE hMetaFile;
} metafile;
} u;
HLPFILE_LINK link;
HLPFILE_LINK* link;
struct tagHelpLinePart *next;
} WINHELP_LINE_PART;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment