Questions tagged as 'jframe'

2
answers

Implementing JMenuBar in a JFrame

I'm having trouble trying to insert a JMenuBar component into my main frame. I do not get any problems running the code, but the options bar in the program does not appear. What is missing?! Principal.java public class Principal {...
asked by 24.08.2015 / 21:18
1
answer

How to maintain the aspect ratio of the screen after being resized by the user?

I need to restrict a certain proportion of a JFrame so that the layout of what I want to display on it is not distorted, but I would not want to have to block resize with setRezisable() . The minimum aspect ratio for testing is 350x500 (7:...
asked by 29.09.2017 / 13:06
1
answer

Change title bar and window icon

I want to change the icon of the title bar of the Java window, as shown below: I'mgoingintheinitComponents()methodandleavingitasitisinthecodebelow,butthesetIconImage(iconeTitulo);lineisanerror.publicFrmConfiguracoes(){initComponents();URLcam...
asked by 23.08.2016 / 04:41
0
answers

How to change image of the startup icon of a .jar? [closed]

For example, change that cup of coffee to another icon.     
asked by 07.06.2017 / 22:05
1
answer

Create JFrame with label?

How to create a JFrame , which contains a JLabel with text, and can be positioned anywhere in the frame. I need this label to stay anywhere in the frame area.     
asked by 31.10.2016 / 01:31
2
answers

Confirm form closure

I need to ask if I want to close the window that is open. I made the following form, but in any of the options, it closes. I currently use this event option: private void formWindowClosing(java.awt.event.WindowEvent evt) {...
asked by 26.03.2015 / 21:08
1
answer

Hide tab - Java

I have a program with several tabs, so I will test if the user is ADMIN, based on this I would like to hide / disable some tabs, I already tested these commands and they do not disable the window: private void SetAbasVisiveis( Usuario usuario)...
asked by 04.04.2015 / 18:57
1
answer

Get Frame already started from the "Event Dispatch Thread"

I have a desktop application in swing , and in it, I have a single JFrame that always stays visible while the application is open. There are also some% modal_dependents dependent on this Frame , which open from certain buttons in...
asked by 05.04.2016 / 17:47
1
answer

JFrames Edition

I have the following code that corresponds to the Header Panel but does not give me the desired output in the image. Can anyone help me? publicclassPainelEstadoContactoextendsJPanel{/****/privatestaticfinallongserialVersionUID=1L;privateJane...
asked by 03.12.2015 / 23:33
1
answer

jFrame frozen / hung when opened in a jTable

The idea is to click on the line of the table that is a jFrame1 and open another jFrame2 with the search of the information of the person based on RE, but when I click on it the code until it works but opens the frozen and locked window. The c...
asked by 30.01.2015 / 13:58