CGM Objects Library
Main Page
Namespaces
Classes
Files
File List
All
Classes
Namespaces
Functions
Variables
Typedefs
Enumerations
Enumerator
Pages
FontCacheEntry.h
1
// FontCacheEntry.h: interface for the CFontCacheEntry class.
2
//
5
6
#if !defined(LST_FONTCACHEENTRY_H__INCLUDED_)
7
#define LST_FONTCACHEENTRY_H__INCLUDED_
8
9
#pragma once
10
11
#include <string>
12
#include <vector>
13
#include "FontDesignGroup.h"
14
15
namespace
Larson
16
{
17
#define LST_CACHE_VERSION 1
18
20
class
CFontCacheEntry
21
{
22
public
:
23
enum
Posture {
24
postureNA,
25
postureUpright,
26
postureOblique,
27
postureBackSlantedOblique,
28
postureItalic,
29
postureBackSlantedItalic,
30
postureOther };
31
32
enum
Weight {
33
weightNA,
34
weightUltraLight,
35
weightExtraLight,
36
weightLight,
37
weightSemiLight,
38
weightMedium,
39
weightSemiBold,
40
weightBold,
41
weightExtraBold,
42
weightUltraBold
43
};
44
45
enum
ProportionateWidth {
46
propWidthNA,
47
propWidthUltraCondensed,
48
propWidthExtraCondensed,
49
propWidthCondensed,
50
propWidthSemiCondensed,
51
propWidthMedium,
52
propWidthSemiExpanded,
53
propWidthExpanded,
54
propWidthExtraExpanded,
55
propWidthUltraExpanded
56
};
57
58
enum
Structure {
59
structureUndefined,
60
structureSolid,
61
structureOutline
62
};
63
64
CFontCacheEntry
() {
65
m_posture = postureNA;
66
m_weight = weightNA;
67
m_width = propWidthNA;
68
m_structure = structureUndefined;
69
m_numFullNames = 0;
70
m_numFamilyNames = 0;
71
m_faceIndex = 0;
72
m_inValid =
false
;
73
m_faceID = NULL;
74
};
75
76
void
serialize(std::ofstream& stream);
77
void
readstr(std::ifstream& stream, std::wstring& str,
unsigned
long
len);
78
bool
restore(std::ifstream& stream);
79
80
std::wstring m_path;
81
long
m_faceIndex;
82
std::wstring m_familyName;
83
std::wstring m_styleName;
84
unsigned
int
m_numFullNames;
85
unsigned
int
m_numFamilyNames;
86
std::vector<std::wstring> m_fullNames;
87
std::vector<std::wstring> m_familyNames;
88
89
Posture m_posture;
90
Weight m_weight;
91
ProportionateWidth m_width;
92
CFontDesignGroup
m_designGroup;
93
Structure m_structure;
94
bool
m_inValid;
95
96
void
* m_faceID;
97
};
98
}
99
100
#endif // LST_FONTCACHEENTRY_H__INCLUDED_
101
Larson::CFontCacheEntry
CFontCacheEntry – defines the data in a font cache entry.
Definition:
FontCacheEntry.h:20
Larson::CFontDesignGroup
CFontDesignGroup – font design attributes.
Definition:
FontDesignGroup.h:21
Generated on Wed Oct 7 2015 15:17:56 for CGM Objects Library by
1.8.6