🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.jbuilder.java.swing
1 messages
1 total messages Started by Aven Fri, 02 Dec 2005 03:22
How to control the viewport of JTextPane?
#59
Author: Aven
Date: Fri, 02 Dec 2005 03:22
15 lines
1302 bytes
Hello,
When I append some strings to the document of a JTextPane, e.g.,

Document doc = textPane.getDocument();
doc.insertString(doc.getLength(),"hello\n");

The scrolling pane that contains JTextPane scrolls automatically.
I don't want this to happen when the viewport is not at the end of
the document.

How can I do that?
Thank you.

Regards,
Aven
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads