Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting text extents

Status
Not open for further replies.

AmkG

Programmer
May 12, 2001
366
0
0
PH
I'm a old newbie programmer of Windows. I have a book which described programming in the old Windows v.1.1 (yeah, that old). Surprisingly, most of the techniques described there are still applicable in Win32 programming, other than changing the size of 'words' into dwords, and not getting the previous instance's data (which got me a GPF when I tried it).

Now, the book describes an API function called 'GetTextExtents().' This function takes an hDC, a pointer to a string and the string's length. However, I took a look at my include files, and I found that I do NOT have this function in my library. I HAVE found a bunch of other functions (note that they are declared in MASM form):

GetTextExtentExPointA PROTO :DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD
GetTextExtentExPoint equ <GetTextExtentExPointA>

GetTextExtentExPointI PROTO :DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD,:DWORD
GetTextExtentPoint32A PROTO :DWORD,:DWORD,:DWORD,:DWORD
GetTextExtentPoint32 equ <GetTextExtentPoint32A>

GetTextExtentPointA PROTO :DWORD,:DWORD,:DWORD,:DWORD
GetTextExtentPoint equ <GetTextExtentPointA>

GetTextExtentPointI PROTO :DWORD,:DWORD,:DWORD,:DWORD

Now all of the GetTextExtent functions have a 'Point' in their names, and they all have at least four arguments, as opposed to the three arguments of the original GetTextExtents(). Was GetTextExtents removed from the API? Or is my Win library incomplete (after all, the Win library for MASM was kinda reverse-engineered I think by Iczelion and others)?
&quot;Information has a tendency to be free. Which means someone will always tell you something you don't want to know.&quot;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top