well as i wrote that theinformation is stored based on the parameters
of CreateFont function.The format is as below:
1. LoByte (Point size for Font)
2. LoByte (Point size for Font)
3. LoByte(LoWord(Height))
4. HiByte(LoWord(Height))
5. LoByte(HiWord(Height))
6. HiByte(HiWord(Height))
7. LoByte(LoWord(Width))
8. HiByte(LoWord(Width))
9. LoByte(HiWord(Width))
10. HiByte(HiWord(Width))
11. LoByte(LoWord(Escapement))
12. HiByte(LoWord(Escapement))
13. LoByte(HiWord(Escapement))
14. HiByte(HiWord(Escapement))
15. LoByte(LoWord(Orientation))
16. HiByte(LoWord(Orientation))
17. LoByte(HiWord(Orientation))
18. HiByte(HiWord(Orientation))
19. LoByte(LoWord(Weight))
20. HiByte(LoWord(Weight))
21. LoByte(HiWord(Weight))
22. HiByte(HiWord(Weight))
23. Italic(byte)
24. Underline(byte)
25. StrikeOut(byte)
26. CharSet(byte)
27. OutPrecision(byte)
28. ClipPrecision(byte)
29. Quality (byte)
30. PitchAndFamily(byte)
31. Length of face name (L)
For Length L following 2 bytes will be repeated
1. LoByte (character of face name)
2. HiByte (character of face name)
Here the first inforation i.e.Point size for Font is the value which we
get from the
CFontDialog::GetSize()
function and the rest of the information are the the parameters of the
CFont::CreateFont( int nHeight, int nWidth, int nEscapement, int
nOrientation, int nWeight, BYTE bItalic, BYTE bUnderline, BYTE
cStrikeOut, BYTE nCharSet, BYTE nOutPrecision, BYTE nClipPrecision,
BYTE nQuality, BYTE nPitchAndFamily, LPCTSTR lpszFacename ).
But i am not able to map all these parameters to their corresponding c#
values and thus cant open the application developed using the previous
version( MFC ) and see the fonts properly.
Can u put some more light on ur first suggestion i.e calling the
CreateFont API function through the P/Invoke layer and then passing the
handle to the static FromHfont method on the Font class???