Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Ranthalion

Displaying Text

This topic is 5318 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How can I display more than 256 characters in a static text control? I need a lengthy explanation to show up, but it always gets truncated at 256. Is there a way around this that I can use to display entire paragraphs in a windows app using Win32? [edited by - Ranthalion on February 27, 2004 11:08:45 AM]

Share this post


Link to post
Share on other sites
Advertisement
I've only had one application where this was a problem... I think I may have solved the problem once by setting the text of the control when the window is created in code rather than just setting it to the window before even compiling. Also, you can set as much text as you want in an edit box control, which you can just set to read only. This also has the added advantage of letting users copy and paste from the text if they want to for some reason.

[edit]
To clarify, when I say setting the text of the control when the window is created, I mean using something like SetDlgItemText, CEdit::SetWindowText() or something of that nature.

-Arek the Absolute

[edited by - Arek the Absolute on February 27, 2004 11:46:09 AM]

Share this post


Link to post
Share on other sites
Check out the Windows GDI API docs (on Graphics and Multimedia @ MSDN). The Font and Text reference may be worth a look. With that you can write text anywhere on a window. You won''t need static text boxes or anything.

Using GDI may be harder than just using the boxes and setting their text because now you have to specify the fonts, colors, text position, etc, all by hand. But with GDI you have (almost) no limitations.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!