I have a project. This project should be executed in different system with different monitors. 1920*1080 , 1024*728 , ... . This app is coded in javaFX . My Question is what should i do with this ? My app should be flexible in all systems. For example a button's size in 1080 system should be 100*100 and in 728 system should be 50*50 .
Asked
Active
Viewed 47 times
-1
-
Take a look at the [Layout Tutorial](http://docs.oracle.com/javase/8/javafx/layout-tutorial/). – David Yee Feb 03 '16 at 19:55
1 Answers
0
One thing to keep in mind is that the standard sizes (for example buttons) are different on different platforms (Windows7, Windows10, Mac, etc.).
This causes some problems with your layout (i.e. translateX, translateY, etc.) on your pc, versus the layout on others. Perhaps it's good to define:
.button{
width: //something
height: //something
}
in your css beforehand. After that you can detect the platforms, for example:
How do I programmatically determine operating system in Java? (just googled it 1 min ago),
then you can perhaps set different css-files based on different platforms.