I need to add a popup menu to the JFrame, but when I drop that component there it just dissappears. I can see it in code, but there is no way to edit anything about it. Is there a way I can edit it like say menu bar?
I use Netbeans 7.2.1 if that is important.
PS - Yes, I tried googling and found only this, but it is not helping...
Okay, I figured it out by myself.
Open Windows -> Navigation -> Navigator it will show a navigator window with all components currently on jFrame.
In that navigator window then click Other components.
In there all non visual components including jPopopMenu will be listed.
By clicking on any of these components it is possible to edit their properties.
Editing the popup menu visually is possible by double clicking on it. It will then bring up visual menu builder.
Related
I could not use JInternalFrameForm in Netbeans.
I did right click on my package and go new but I did not see JInternalFrameForm option.
The right click New menu only shows you options you have commonly used, or only several default options if you haven't used any.
to find JInternalFrameFrom, select the Other Option on the bottom of the options,
Then type in JInternalFrame in the search box of manually find the component inside the Swing GUI Form folder.
see the image below
What I want to achieve is this:
On Windows platform:
Right click on a window (some context menu will show up)
Capture the screenshot into a bitmap.
Create a window containing the screenshot on top of everything in the screen, including the context window.
Is step 3 possible?
ADD 1
I am going through the Window Styles from the 2 links below:
Extended Windows Styles
Windows Styles
Not sure if they can help me.
I discovered a solution in C# that may be applicable. If you bring the window to the front after the context menu has been created, it will bring it in front of the context menu. You can emulate a window that is always on top of everything on the screen by repeatedly bringing it to the front in a background thread.
Here is the C# implementation:
How to draw on top of the right-click menu in .NET/C#?
This link may also help. I don't know if the same process could be used to display on top of the right-click menu, especially not in Java, but it may be worth a look:
How can I make my own application on top in the start menu?
Right now I am working on a GUI application In java using the GUI builder that comes with NetBeans.
However I have found some kind of strange bug/feature, as I am no longer able to see the window that allows users to change between "source" and "design" (Design is the drag and drop NetBeans gui builder while source is the code where you can add your own methods and so forth).
NOTE: the red is censored information that is not necessary.
When I right click on a component to add event code, then it takes me to the source (without a window for me to change back to design, it goes back to design when i close and reopen it). So I know that NetBeans recognizes that this is indeed a JFrame form with the NetBeans GUI designer, and the source code is indeed availible..
I could not find any answers to this question on this site or on the web, I have tried resetting the windows but it did not work, I also couldn't find the window when I clicked on the window option. I am sure there is some easy question but I am unable to find it. Please forgive me if this was an easy question.
On the menu bar, try clicking View -> Show Editor Toolbar
I've recently installed window builder plug-in on my Eclipse IDE. When I create a New project and add window builder or anything, I'm unable to drag even a button from the palette.I might be dragging it the wrong way or there might have been something missing in the path etc. Does anyone know the solution to it? It'll be highly appreciated. Thanks!
What do you mean by "I'm unable to drag even a button from the palette" - is the palette not responsible to mouse events?
Try creating File->New->Other and selecting Window Builder->Swing Designer->Application Window. Switch to Design tab.
Basically you don't drag components/layouts to the graphical view of your window. You should select for example JButton by clicking it first. Afterwards you click (second time) on the window.
In Eclipse Jigloo plugin you can right click on JTable and choose "surrond with JScrollPane".
But in windowbuilder pro plugin I can't find a way to make JTable with JScrollPane
Add a scroll pane to your UI. Then drag and drop the table onto the scroll pane. During the drag over scroll pane window builder will highlight its areas - make sure you drop onto the central one.
Alteratively the following also works nicely;
Add a JTable
Right click on the JTable in the tree view
Select: Surround With > JScrollPane
Another option would be to use NetBeans to do some of your Swing layout.
I've had limited experience with WindowBuilder, but I use NetBeans for designing prototypes and find it much easier for creating UIs. The resulting code generated from NetBeans will also be viewable using WindowBuilder.
I am using WindowBuilder 1.7.0 and Swing designer 1.7.0 in Eclipse in Mac. At first I was finding similar menu like Jigloo which I did not find. My Jigloo always crash in Mac and show license message, so I discarded it :)
Later with some playing, I found how to do it in WindowBuilder, specially if you have already designed the JTable/JTextArea/JTree and do not want to delete it. After that you need to put them scrollable.
You can use the tree view on the left. Normally you cannot drag a component into the scroll view. However add the scroll view in the frame. Set proper layout to the component where you want to put the scroll view. Usually its BorderLayout, may in a JPanel. Drag the JScrollView into target area. Use the tree view for all these actions. Then finally drag the JTree/JTable into the JScrollPane in the frame design view. To my experience this works better. Play with the Layouting of the parent components.