Open a new JavaFX window on a second monitor -
i trying open new window javafx application , set coordinates be inside application doing following:
secondstage.setx(application.getprimarystage().getx() + application.getprimarystage().getwidth()/3); secondstage.sety(application.getprimarystage().gety() + application.getprimarystage().getheight()/3);
it works fine when primary stage on first monitor. when on second monitor, new application opens right left border of second monitor, not inside app. if x coordinate gets rounded 0 respect second monitor when exceeds primary screen's x bounds.
please let me know how can have same functionality/behavior on second monitor on primary 1 using same logic described code.
Comments
Post a Comment