aspose file tools*
The moose likes IDEs, Version Control and other tools and the fly likes Netbeans: GUI background color issue, and image Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "Netbeans: GUI background color issue, and image" Watch "Netbeans: GUI background color issue, and image" New topic
Author

Netbeans: GUI background color issue, and image

Jay Orsaw
Ranch Hand

Joined: Jun 14, 2011
Posts: 356

Hello all! I have 2 questions regarding netbeans. 1 is when I save my project containing pictures where do I put the pictures? Originally I had an "external picture" that wasn't shown when I built my Jar file. Now I have "imported to project" but still do not see it. Should I include a folder called images in the dist folder or what?

Also when trying to use the GUI Builder the default color is gray. I have tried to switch itt o all white, but does not work, why is this? Should I try custom code or what? I'm not sure why it doesn't chage... I am using Absolute Layer with a Frame.

Edit: I just added a Panel and can change the color, I'm guessing it's a Frame issue...?
Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5845
    
    7

The answer to number 1 depends on what type of project you're talking about and how you access the picture within your app. How a picture is shown in a web app via a URL is very different from how a picture would be accessed in a Java command line app using a classpath resource to access the picture.


JBoss In Action
Jay Orsaw
Ranch Hand

Joined: Jun 14, 2011
Posts: 356

Peter Johnson wrote:The answer to number 1 depends on what type of project you're talking about and how you access the picture within your app. How a picture is shown in a web app via a URL is very different from how a picture would be accessed in a Java command line app using a classpath resource to access the picture.


The pictures are local, they aren't via a url. I want them to be included in the project.
Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5845
    
    7

I assume that you answer means that you are not creating a web project. In that case place the image file into the proper package under Source Packages. (Exactly which package depends on how your code accesses the picture.) The image will be included in the JAR file.


(By the way. even in a web project the pictures are included in the project.)
Jay Orsaw
Ranch Hand

Joined: Jun 14, 2011
Posts: 356

Yes the "Import to project" places them in the source package. So these images will be included inside the JAR itself and I wont have to worry about including them elsewhere then? Thanks!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Netbeans: GUI background color issue, and image