If you want to define sizes relatively so that positions are respected regardless of the screen, you need to use the layouts managers . They serve as organizers for components on the screen or inside other components on the screen itself. With this, you will always have the same organization regardless of the screen resolution of the user who is running the application.
As for keeping the size of JFrame
relative to the user's screen size, in this answer there is a solution that can work.
Since you did not submit a Minimum, Full, and Verifiable example , you can not suggest anything specific to the screen that appears , but the solution for sure is the use of one or more managers.
Just to demonstrate the power of layout managers, along with the linked answer hint, see the example below where I made a screen with proportions for half of my screen, and even resizing, the components do not get disorganized, just the table fits thanks to JScrollPane
.:
The netbeans wizard may seem tempting, but use it without knowing the swing API and its operation will get you in this IDE and will hold you to problems like what you face in this question. I suggest that before learning to drag and drop, learn the basics about swing and its components, because it is essential to have notion, how to create screens and organize components without relying on IDEs, no matter how the netbeans or windowbuilder screens builder in eclipse will greatly facilitate this process.