Re: GetFontUnicodeRanges() will not compile
- From: "Peter Olcott" <NoSpam@xxxxxxxxxxxxx>
- Date: Mon, 19 Nov 2007 15:37:51 -0600
I tried forcing it another way
#define _WIN32_WINNT 0X500
This compiles and runs, but, it seems to tell me that every
font has 224 glyphs and 22 unicode ranges.
"Joseph M. Newcomer" <newcomer@xxxxxxxxxxxx> wrote in
message news:qtu3k3dk6hnem679buolrrifld284l57f8@xxxxxxxxxx
You probably have the wrong platform SDK. Cutting and
pasting is usually considered a bad
idea, because it is supposed to work "out of the box".
For example, by cutting and
pasting, you caused the C++ compiler to think this was a
C++ method. You can tell this
instantly by looking at the name of the method; it has C++
name decoration on it. If it
were trying to link to the API and got an undefined
symbol, it would have said that the
symbol GetFontUnicodeRanges was undefined. Show the
declaration; it is almost certain you
did not copy it precisely as in the SDK. Or by the time
your copied-and-pasted definition
was seen, key macros required for correct compilation were
no longer defined.
If you ever find a definition in a header file and you get
an undefined symbol when trying
to use it, it means you have the wrong conditionals set.
joe
On Mon, 19 Nov 2007 13:40:01 -0600, "Peter Olcott"
<NoSpam@xxxxxxxxxxxxx> wrote:
I am using MS Visual C++ 6.0 on a Windows XP Pro platform.Joseph M. Newcomer [MVP]
I forced the code to almost compile by cutting and pasting
the declarations from the wingdi.h include file. Now I am
getting this linker error:
--------------------Configuration: UnicodeTest - Win32
Debug--------------------
Linking...
UnicodeTestDlg.obj : error LNK2001: unresolved external
symbol "__declspec(dllimport) unsigned long __stdcall
GetFontUnicodeRanges(struct HDC__ *,struct tagGLYPHSET *)"
(__imp_?GetFontUnicodeRanges@@YGKPAUHDC__@@PAUtagGLYPHSET@@@Z)
Debug/UnicodeTest.exe : fatal error LNK1120: 1 unresolved
externals
Error executing link.exe.
UnicodeTest.exe - 2 error(s), 0 warning(s)
"Joseph M. Newcomer" <newcomer@xxxxxxxxxxxx> wrote in
message news:v3o3k35vutqof6uu5c763ligj3o6kj072d@xxxxxxxxxx
What are the various constants sent in your stdafx.h,
and
are you using a Win2K or higher
platform SDK?
joe
On Mon, 19 Nov 2007 11:08:17 -0600, "Peter Olcott"
<NoSpam@xxxxxxxxxxxxx> wrote:
LPGLYPHSET lpgs; // pointer to the glyph setJoseph M. Newcomer [MVP]
structure
::GetFontUnicodeRanges(this->GetDC(), lpgs); // HDC
hdc,
LPGLYPHSET lpgs
--------------------Configuration: UnicodeTest - Win32
Debug--------------------
Compiling...
UnicodeTestDlg.cpp
O:\cpp\DFA\UnicodeTest\UnicodeTestDlg.cpp(179) : error
C2065: 'LPGLYPHSET' : undeclared identifier
O:\cpp\DFA\UnicodeTest\UnicodeTestDlg.cpp(179) : error
C2146: syntax error : missing ';' before identifier
'lpgs'
O:\cpp\DFA\UnicodeTest\UnicodeTestDlg.cpp(179) : error
C2065: 'lpgs' : undeclared identifier
O:\cpp\DFA\UnicodeTest\UnicodeTestDlg.cpp(180) : error
C2039: 'GetFontUnicodeRanges' : is not a member of
'`global
namespace''
O:\cpp\DFA\UnicodeTest\UnicodeTestDlg.cpp(180) : error
C2065: 'GetFontUnicodeRanges' : undeclared identifier
Error executing cl.exe.
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
.
- References:
- GetFontUnicodeRanges() will not compile
- From: Peter Olcott
- Re: GetFontUnicodeRanges() will not compile
- From: Joseph M . Newcomer
- Re: GetFontUnicodeRanges() will not compile
- From: Peter Olcott
- Re: GetFontUnicodeRanges() will not compile
- From: Joseph M . Newcomer
- GetFontUnicodeRanges() will not compile
- Prev by Date: Re: Why INFINITE loop in a thread occupy so much CPU time??
- Next by Date: Re: Multilanguage support for CEdit
- Previous by thread: Re: GetFontUnicodeRanges() will not compile
- Next by thread: Re: GetFontUnicodeRanges() will not compile
- Index(es):
Relevant Pages
|