Undecorator icon indicating copy to clipboard operation
Undecorator copied to clipboard

Window border size not preserved when nodes are changed

Open andytill opened this issue 12 years ago • 3 comments

Excellent project, many thanks! I am trying to use it in my own project, EstiMate but have run into an issue.

I have my own container FXML called rootView.fxml, I put a login control in rootView and set that as the Undecorated control. When the user logs in I put a main screen in the root view, this replaces the login screen. The undecorator no longer has the correct border size.

Do you know of any issues when switching around nodes inside the Undecorator control? Below is a screen shot.

Thanks!

EstiMateWin8

andytill avatar Mar 03 '13 14:03 andytill

You can recreate this issue using the following program.

import insidefx.undecorator.UndecoratorScene;
import javafx.application.Application;
import javafx.scene.control.Button;
import javafx.stage.Stage;

public class UndecoratorApp extends Application {

    @Override
    public void start(final Stage stage) throws Exception {

        // The Undecorator as a Scene
        UndecoratorScene undecoratorScene = new UndecoratorScene(stage, new Button("Hello"));

        // Set minimum size
        stage.setMinWidth(500);
        stage.setMinHeight(600);

         stage.setScene(undecoratorScene);

         stage.show();
     }

     public static void main(String[] args) {
         launch(args);
    }
}

andytill avatar Mar 03 '13 17:03 andytill

Hi, Indeed, this could lead to a problem... The client area is part of bounds calculation so if it is changed it may produce unexpected results. Do you have to the same issue if you use an intermediate Pane where you load both the login and the second screen into this one? Thanks.

in-sideFX avatar Apr 08 '14 07:04 in-sideFX

Hi! It did use an intermediate pane. I think this is basically the same issue as #3 where the min size of the content area is not used, you can use the sample program to recreate. Thanks

andytill avatar Apr 08 '14 21:04 andytill