Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

javafx resizable window

scene.widthProperty().addListener(new ChangeListener<Number>() {
    @Override public void changed(ObservableValue<? extends Number> observableValue, Number oldSceneWidth, Number newSceneWidth) {
        System.out.println("Width: " + newSceneWidth);
    }
});
scene.heightProperty().addListener(new ChangeListener<Number>() {
    @Override public void changed(ObservableValue<? extends Number> observableValue, Number oldSceneHeight, Number newSceneHeight) {
        System.out.println("Height: " + newSceneHeight);
    }
});
Comment

javafx resizable window


GraphicsDevice gd = GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice();
int width = gd.getDisplayMode().getWidth();
int height = gd.getDisplayMode().getHeight();

Comment

PREVIOUS NEXT
Code Example
Java :: association in java 
Java :: static int java 
Java :: reverse array java 
Java :: java iso 8601 format 
Java :: why are there no destructors in java? 
Java :: string to bigdecimal 
Java :: how to get int from string java 
Java :: java read keyboard input 
Java :: java home mac 
Java :: how to overwrite a text file in java 
Java :: java random array 
Java :: Validation failed for query for method public abstract java.util.List 
Java :: java scanner string to int 
Java :: java how to make a number 
Java :: java stream distinct by key 
Java :: transformer un string en double java 
Java :: java install in fedora 
Java :: java date to string 
Java :: How to generate all possible IP addresses based on a given set of digits, in Java? 
Java :: 8.1.1. Declaring an Array&para; 
Java :: java while loop example 
Java :: java get random 
Java :: get frequency of letters java 
Java :: java if or 
Java :: random boolean java 
Java :: android application class 
Java :: java regex 
Java :: how to get last element in java 
Java :: how to find some of digits in java 
Java :: dropdown menu with spinner dropdown icon color change in android 
ADD CONTENT
Topic
Content
Source link
Name
4+7 =