I have a Java application, and in order to find the size of the screen to use, I do the following, for example:
Toolkit.getDefaultToolkit().getScreenSize().width;
Toolkit.getDefaultToolkit().getScreenSize().height;
In my application, I am painting some items on the screen. And to determine the position, I use these values for width and height (because I want a particular item at the very bottom).
But, I'm finding that it is going off the screen, even though it's position doesn't exceed what the value for the height of my screen is.
Then, I realized I'm on a Mac, and the window that pops up for the Java application starts below the little toolbar menu thing at the top of my Mac (you know, the thing that has the time, the battery, etc). Do I need to take the height of that bar into consideration in my application? If so, is there an easy way to say "if I'm on a mac, then subtract something from the height." Also, what is that value of the height of that Menu Bar?