Jump to content

  • Log In with Google      Sign In   
  • Create Account

Awesome job so far everyone! Please give us your feedback on how our article efforts are going. We still need more finished articles for our May contest theme: Remake the Classics

#Actualyewbie

Posted 07 September 2012 - 02:51 PM

Determines the width and height of the rectangle. If there are multiple lines of text, DrawText uses the width of the rectangle pointed to by the lpRect parameter and extends the base of the rectangle to bound the last line of text. If the largest word is wider than the rectangle, the width is expanded. If the text is less than the width of the rectangle, the width is reduced. If there is only one line of text, DrawText modifies the right side of the rectangle so that it bounds the last character in the line. In either case, DrawText returns the height of the formatted text but does not draw the text.

http://msdn.microsof...8(v=vs.85).aspx

Ah i forgot using DT_CALCRECT will return the calculated rect but not actually draw anything!

edit: thats not actually the same function you are using but it works the same

#1yewbie

Posted 07 September 2012 - 02:48 PM

Determines the width and height of the rectangle. If there are multiple lines of text, DrawText uses the width of the rectangle pointed to by the lpRect parameter and extends the base of the rectangle to bound the last line of text. If the largest word is wider than the rectangle, the width is expanded. If the text is less than the width of the rectangle, the width is reduced. If there is only one line of text, DrawText modifies the right side of the rectangle so that it bounds the last character in the line. In either case, DrawText returns the height of the formatted text but does not draw the text.

http://msdn.microsoft.com/en-us/library/windows/desktop/dd162498%28v=vs.85%29.aspx

Ah i forgot using DT_CALCRECT will return the calculated rect but not actually draw anything!

PARTNERS