Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6817533
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T21:04:02+00:00 2026-05-26T21:04:02+00:00

I got a JViewport correctly scrolling using the default layout manager (using viewport.setViewPosition), but

  • 0

I got a JViewport correctly scrolling using the default layout manager (using viewport.setViewPosition), but when I call setLayout(null) this no longer works.

Any ideas?

I can give code if needs be, but it’s pretty messy at the moment.

Thanks!

Edit: Thanks for the info so far. I’ve been using a null layout so I can absolutely position components I draw later, is there a way I can do with whilst using a layout manager?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T21:04:03+00:00Added an answer on May 26, 2026 at 9:04 pm

    Scroll panes only work when the preferred size of the component added to the scroll pane is greater than the size of the scroll pane.

    When you use a null layout, the preferred size is 0, so the scroll pane doesn’t work. That is why you should use a layout manager. It will determine the preferred size for you.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Got this error when parsing my html page using XPATH.. i am also using
<meta name=viewport content=width=device-width, initial-scale=1> This is not helping at all. I have got 100
Got this error message while trying to load view: The model item passed into
Got a question for some jQuery wizard who might stumble upon this. When I
got a problem, can't get my head around this jquery and would appreciate your
I'd consider myself a reasonable standard CSS/XHTML chap but I'm pretty baffled by this.
I'm writing an isometric game, but unfortunately I've got stuck writing with the algorithm
I've got liquid layout website that displays (8 x 240px) columns on 1920x1080px. There
I have got a html like this: <!doctype html> <html manifest=> <head> <meta charset=utf-8
http://jsfiddle.net/kCMvt/ Hey everyone. I made this jQuery page for a mobile phone, but the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.