Java window size

Asked

Viewed 174 times

2

When I open the project in Javafx in Windows OS, it opens right, but when I open the same project in Mac Retina, it opens with another dimension, the windows are all misaligned and I have to fix in hand.

There’s some way to fix it?

Follow images below to show what is happening.

Windows: inserir a descrição da imagem aqui

Mac:

inserir a descrição da imagem aqui

  • You’re using anchorpane, right? The monitors have the same resolution?

  • Yes, Anchorpane. No, in windows use 1600x900, on Mac the resolution is higher. If I use a Vbox, will this problem solves?

  • More or less, there is no way to get the filter on one side and the menu on the other in Vbox

  • Yes, the filter I can manage later, but the registration windows, are out of order tb, I believe that using a Vbox this problem can be fixed. I’ll try and see what

1 answer

1

As you are using an Anchorpane (and apparently only that part of the filter is out of place) I suggest you change the anchoring of the items right to right, as I realized that you must have put everyone relative to the left, more or less like this:

\>--------|---------|----------|--------------------------------| 

It would have to anchor in relation to the right part of the filters:

\>--------|---------|----------|                      |--------------------<

How to buttons you have to increase the width of them a little more than necessary because the fonts change from system to system.

  • Ahh got it, I’ll give it a try. Thanks for the tip!!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.