NetBeans Platform Main Frame - java

I am looking into the NetBeans platform for developing desktop applications. I am a complete newbie in it. I understood till now the module architecture. Now I want to do some GUI work. My question is very simple and feel embarrassed to ask it, but how can I edit the main frame of the application? I mean the one generated automatically by NetBeans. I looked around but for god's sake, I can't see it in the IDE:(
Edit: It seems there is a misunderstanding. I know how to create a JFrame:) I am talking about the NetBeans platform, when your application is built on top of the NetBeans core. Here is a short article. At the bottom there are two screenshots. The IDE generates a Main frame looking like the real NetBeans IDE. I can create new modules and so on. But I want to edit this Main frame, but I don't see it in the IDE. Hope my question is clear now.
Thanks in advance:)
Regards,
Petar

As I learned more things of the NetBeans platform, I understood that there is a virtual FileSystem which is build from combining layer.xml files from all modules. This FileSystem is the configuration of the application. It includes things as which menu items to be shown on the main frame, etc. So I guess the main frame is edited this way:)

Yes, is like Petar says, but to be more specific, one way to do this is from the Netbeans GUI is described here. http://platform.netbeans.org/tutorials/70/nbm-htmleditor.html#tweakingthemenuitems. This is for 7.0 version of netbeans.
I found useful this question also How to remove items from menu in netBeans platform?.

Related

How to install and use NatTable?

I have developed some web applications before and everything is well documented and there is a framework for anything. I am new to Swing and desktop application development and I found that documentation is sparse and you have to figure out a lot of things by experimenting.
I've been googling for a few hours on how to setup NatTable and I couldn't find anything. I was surprised no one asked the question before. I just want some instructions on how to get the basics working on Eclipse and NetBeans. I was using Eclipse in the past but I think I will use NetBeans for this project as the Swing GUI editor is better.
Is NatTable exclusive to Eclipse or will it also work with NetBeans? If someone can post screenshots of the setup procedure, that would be awesome.
Any help is appreciated.
Thanks in advance.
The NatTable project has a website that contains some information. It doesn't cover everything, but how to install and use it is explained:
https://www.eclipse.org/nattable/documentation.php?page=getting_started
Currently NatTable is building a SWT control. Swing is not supported. That might change in the future.

What do I need to change in Netbeans so that it builds a hybrid JavaFX application?

I've written a simulation with animations in Swing (and awt components) and graphing in JavaFX. However, I would like to build this in Netbeans so that all components are build correctly. I read on Oracle's site that I need to build with certain parameters to enable e.g. Swing functionality in a JavaFX application, but as I don't have any experience with packaging, I have no idea how to do this. I created my project in Netbeans as a "Java Application", but added the JavaFX functionality much later.
I recommend that you start looking here:
http://docs.oracle.com/javafx/2/installation_2-2/javafx-installation-mac.htm
Eventually you will find this:
https://netbeans.org/kb/72/java/javafx-setup.html
Projects done in a IDE can be confusing for those who do not know very well how to manipulate them. What you can do now is take a look at the link I gave you so you can learn to create and manipulate a JavaFX project. Then what you can do is create a new JavaFX project and import the classes you were using in the previous project. To copy the classes, you can simply import your class files with NetBeans, or you can copy and paste the files from your computer into Netbeans project that Netbeans will recognize your files.
Remember that at the end of all, the projects reflect the existing files on your computer. What an IDE primarily does for you is just to help you manipulate these files.
OBS: To learn how to use Netbeans with scene builder, look at the following link:
http://docs.oracle.com/javafx/scenebuilder/1/use_java_ides/sb-with-nb.htm
Hope this helps. As always, we're here. Good luck! :)

Netbeans Platform: Hide Tabs for just one TopComponent

netbeans platform has proved to be most useful for large applications. But what about small applications?
I'm building a small Price-List making software which only has one TopComponent which contains a JTable and a few buttons.
This component I've set to have closing/sliding etc disabled as this is mandatory to be there. I also DO NOT want to have ANY more top components.
Is there a way to remove the tabs? It seems pointles to show just one tab with the name of the TopComponent.
I hope you get what I mean!
Thanks in advance.
Molten Ice,
Geertjan Wielenga's blog is an invaluable source of information for the NetBeans Platform. He's written a post especially for this task:
http://blogs.oracle.com/geertjan/entry/farewell_to_space_consuming_weird
I've used this technique before and it works fine.
If you have any other questions related to the NetBeans Platform I would suggest that you try the Plaform Users section of the NetBeans forums.

Can't Edit JFrame Form after NetBeansUpdate

Lately, I've been working on a project in NetBeans using the GUI editor that's built in. Before I noticed that it generated an XML ".form" file that didn't appear in the Project Explorer Pane which makes sense. Earlier I was working on the form in the "Design" tab when it notified me about 15 updates. I just updated without reading anything which was probably a bad idea but when I restarted the IDE, it showed my GUI ".class" file and ".form" file separately in the Project Explorer and I couldn't switch between "Source" and "Design". I also noticed that the generated code that was usually not editable was now editable.
P.S. I'm able to create a new frame just fine and the design editor still works with new frame
I have encounter the same problem and I have solved it.
The key in this problem, I think, is particular plugins for JFrame in Netbeans are not active after updating, so we only need to activate them. The easiest way to achieve this is create a new JFrame class, so in this progress, NetBeans can activate all relevant plugins for us. Finally, restart NetBeans, then everything would be fine.
Thank you very much for all of you that you give me some idea and clues in this situation:)
Work on a similar problem led me to this discussion concerning Guarded blocks inside form Java source file. I'm not sure it's related to your situation, but it may help you recover.
If you are trying to recover the lost state of the backing xml for the form I don't know what to tell you.
This has happened to me, but I tend to highly componentize the forms (break up the forms into little pieces), which makes this not such a big deal. Have you tried the NetBeans forums? You might get better luck there:
http://forums.netbeans.org/
Nevermind, simple solution.
I finally decided that, after plenty of tinkering, to restart the IDE which I should have though of first. The Java SE Plugin must have crashed or something, anyway it's fixed.
Thanks for the help!
Or just right click on the corresponding .form file and select open. The Design tab/editor reestablishes.

where is the eclipse desktop framework

i'm new for java how can i add a button or others like Microsoft visual studio?
If you mean that you want a GUI builder, you'd better consider NetBeans with its Matisse. I think it is the most popular now for Swing apps.
This Google search shows a number of GUI builders for Eclipse
Many people prefer building GUI in Swing manually (just writing code) because it is by far not that difficult as in MSVC++ applications.
If you are looking for the Eclipse IDE to help with the development of Java applications, this can be found on eclipse.org.
Though I'm not sure I understood your question correctly.
What you are looking for is Eclipse Visual Editor. However, as pointed out by others, the GUI Builder from NetBeans (formerly known as Matisse) is more popular for Swing development.
Download Netbeans, its visual editor is very good, and will give you a the perfect Swing User Interface. Its also very easy to use.
When making desktop applications, i always do it with Netbeans, if i know the application will be more complicated later, then i do only one or two JFrame classes with Netbeans, and use them in a new project in Eclipse :)

Categories

Resources