Displaying long text

Discussion and support for general JUCE issues

Displaying long text

Postby Mike » Fri Aug 10, 2012 3:47 pm

Hey,
What's the best component to display large amounts of text? I intend to load text from a file and display it in a Viewport,
but the component where I lay it must be able to resize itself to fit the text. Am I overlooking something obvious?
[Insert signature here]
User avatar
Mike
JUCE UberWeenie
 
Posts: 164
Joined: Thu Jan 27, 2011 11:34 pm

Re: Displaying long text

Postby millenliam » Fri Aug 10, 2012 4:59 pm

I usually use the TextEditor component to display large amounts of text, and just set to it to be read-only. If the amount of text won't fit into the bounds of the component, a scrollbar will automatically be added.
User avatar
millenliam
JUCE UberWeenie
 
Posts: 109
Joined: Thu Aug 11, 2011 4:23 pm
Location: Bristol, UK

Re: Displaying long text

Postby Mike » Fri Aug 10, 2012 9:01 pm

millenliam wrote:I usually use the TextEditor component to display large amounts of text, and just set to it to be read-only. If the amount of text won't fit into the bounds of the component, a scrollbar will automatically be added.

Ah. That sounds simple enough. Thanks!
[Insert signature here]
User avatar
Mike
JUCE UberWeenie
 
Posts: 164
Joined: Thu Jan 27, 2011 11:34 pm


Return to General JUCE discussion

Who is online

Users browsing this forum: No registered users and 3 guests