SVN_SILENT made messages (.desktop file)
[kdepim.git] / ktnef / wmfstruct.h
blob6356e519c9485d7a94de1f351d5d7cd1cc12a443
1 /* This file is part of the Calligra project
2 * Copyright (c) 2003 Stefan Taferner <taferner@kde.org>
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License version 2 as published by the Free Software Foundation.
8 * This library is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * Library General Public License for more details.
13 * You should have received a copy of the GNU Library General Public License
14 * along with this library; see the file COPYING.LIB. If not, write to
15 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16 * Boston, MA 02110-1301, USA.
18 #ifndef wmfstruct_h
19 #define wmfstruct_h
21 typedef short WORD;
22 typedef int DWORD;
23 typedef qint32 LONG;
24 typedef void *_HANDLE;
26 typedef struct _RECT {
27 WORD left;
28 WORD top;
29 WORD right;
30 WORD bottom;
31 } RECT;
33 typedef struct _RECTL {
34 LONG left;
35 LONG top;
36 LONG right;
37 LONG bottom;
38 } RECTL;
40 typedef struct _SIZE {
41 WORD width;
42 WORD height;
43 } SIZE;
45 typedef struct _SIZEL {
46 LONG width;
47 LONG height;
48 } SIZEL;
50 struct WmfEnhMetaHeader {
51 DWORD iType; // Record type EMR_HEADER
52 DWORD nSize; // Record size in bytes. This may be greater
53 // than the sizeof( ENHMETAHEADER ).
54 RECTL rclBounds; // Inclusive-inclusive bounds in device units
55 RECTL rclFrame; // Inclusive-inclusive Picture Frame of metafile
56 // in .01 mm units
57 DWORD dSignature; // Signature. Must be ENHMETA_SIGNATURE.
58 DWORD nVersion; // Version number
59 DWORD nBytes; // Size of the metafile in bytes
60 DWORD nRecords; // Number of records in the metafile
61 WORD nHandles; // Number of handles in the handle table
62 // Handle index zero is reserved.
63 WORD sReserved; // Reserved. Must be zero.
64 DWORD nDescription; // Number of chars in the unicode description string
65 // This is 0 if there is no description string
66 DWORD offDescription; // Offset to the metafile description record.
67 // This is 0 if there is no description string
68 DWORD nPalEntries; // Number of entries in the metafile palette.
69 SIZEL szlDevice; // Size of the reference device in pels
70 SIZEL szlMillimeters; // Size of the reference device in millimeters
72 #define ENHMETA_SIGNATURE 0x464D4520
74 struct WmfMetaHeader {
75 WORD mtType;
76 WORD mtHeaderSize;
77 WORD mtVersion;
78 DWORD mtSize;
79 WORD mtNoObjects;
80 DWORD mtMaxRecord;
81 WORD mtNoParameters;
84 struct WmfPlaceableHeader {
85 DWORD key;
86 WORD hmf;
87 RECT bbox;
88 WORD inch;
89 DWORD reserved;
90 WORD checksum;
92 #define APMHEADER_KEY 0x9AC6CDD7
94 struct WmfMetaRecord {
95 DWORD rdSize; // Record size ( in words ) of the function
96 WORD rdFunction; // Record function number
97 WORD rdParm[ 1 ]; // WORD array of parameters
100 struct WmfEnhMetaRecord {
101 DWORD iType; // Record type EMR_xxx
102 DWORD nSize; // Record size in bytes
103 DWORD dParm[ 1 ]; // DWORD array of parameters
106 #endif /*wmfstruct_h*/