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 8910449
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T03:41:33+00:00 2026-06-15T03:41:33+00:00

I am developing application based on Swing. My problem is I use JWebBrowser and

  • 0

I am developing application based on Swing.

My problem is I use JWebBrowser and I put one in a scrollable panel. When I scroll down the panel the web browser overlaps the panel/frame of the application.

What can I do so the browser does not overlap the panel?

  • 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-06-15T03:41:34+00:00Added an answer on June 15, 2026 at 3:41 am

    I don’t see an answer here, so as someone who has been down this bumpy road, I can sympathize with these issues and would like provide some guidance.

    First of all, the JWebBrowser is an AWT heavyweight component, and does not play nicely in Swing (since it uses lightweight components) without some intervention.

    Instantiate JWebBrowser like this for the first step of friendly Swing integration:

    new JWebBrowser(NSComponentOptions.destroyOnFinalization(),
                    NSComponentOptions.constrainVisibility(),
                    NSComponentOptions.proxyComponentHierarchy())
    

    That instantiation alone should prevent the browser from overlapping the Swing lightweight components, however, it will not work as you would expect with transparencies or layers unless you do some additional steps.

    So, during construction, call these:

    webBrowser.setDoubleBuffered(true);
    webBrowser.getNativeComponent().createBackBuffer();
    

    And then, right before the web browser is to be used with any kind of transparency or layers, call these:

    rects[0] = webBrowser.getBounds();
    webBrowser.getNativeComponent().updateBackBuffer(rects);
    

    Those calls will repaint the backbuffer right before the component is to be used and so when being used, it will be displayed with that most recent backbuffer and will look pretty much like a regular Swing component at that point.

    There are some nuances with all of this, but that’s the basics and should be enough to get anyone started with it.

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

Sidebar

Related Questions

I am developing a web application based on JSF technology. I use Eclipse as
Developing a desktop application based on Java + Swing I faced the problem of
I am developing an application based on one library. I am facing problem related
I am developing web based application in Java [GWT] I am facing problem with
I'm currently developing a web application based on jQuery Mobile. I would like to
We are developing a REST based application using Visual Studio 2010, using asp.net web
I have a server application and two Swing-based client applications. We're developing them in
I am developing application based on the NetBeans platform. I use Maven to build
i'm caught in a problem. i'm developing an application based on lbs and referred
I'm developing a web application based on ASP.NET MVC. There are a large database.

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.