Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Other Java > Java GUI
| Search | Today's Posts | Mark Forums Read
Java GUI Discussions specific to programming Java GUI.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java GUI section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 27th, 2004, 01:38 PM
Registered User
 
Join Date: Jun 2003
Location: , , United Kingdom.
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default scrolling scrollpane

ive got the opposite problem to natmaster.
i am using a JEditorPane inside a JScrollPane.
When i load a URL into it using setPage(URL url), the top of the page stays in view. this is how i want it.

However, I also call setText(String text) in a different function.
in this case, the pane scrolls to the bottom, instead of remaining at the top, as i would like.

I tried cheating and calling scrollRectToVisible(Rectangle contentRect) on the scrollpane viewport using a rectangle with coordinates at (0,0), but this did not make a difference.

Does anyone have any other ideas how I could keep the scrollbar at the top of the page?

Thanks

Philip
-------------------------
dhtml_phil@programmer.net
 
Old May 16th, 2004, 05:39 AM
Registered User
 
Join Date: May 2004
Location: , , .
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i think me and u remain the same...as do read ma posts and try to answer it if possible..thanxxx





Similar Threads
Thread Thread Starter Forum Replies Last Post
scrolling red_fiesta Classic ASP Professional 5 November 2nd, 2006 12:35 PM
Unlimited scrolling dartcoach VB How-To 3 January 19th, 2006 12:15 AM
scrolling carro123 Javascript How-To 0 June 6th, 2005 12:29 PM
scrolling smn2 Classic ASP Professional 1 August 28th, 2003 06:57 AM
Scrolling smn2 Classic ASP Basics 0 August 28th, 2003 05:00 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.