Initial Commit

This commit is contained in:
FUH22860 2022-04-26 14:33:26 +02:00
commit bf4bac33a9
2 changed files with 54 additions and 0 deletions

23
src/application/Main.java Normal file
View File

@ -0,0 +1,23 @@
package application;
import javafx.application.Application;
import javafx.stage.Stage;
import javafx.scene.Scene;
public class Main extends Application {
public void start(Stage primaryStage) {
try {
RootGridPane root = new RootGridPane();
Scene scene = new Scene(root, 400, 400);
primaryStage.setScene(scene);
primaryStage.show();
primaryStage.setTitle("Erstes Fenster");
} catch (Exception e) {
e.printStackTrace();
}
}
public static void main(String[] args) {
launch(args);
}
}

View File

@ -0,0 +1,31 @@
package application;
import javafx.scene.control.Button;
import javafx.scene.layout.GridPane;
public class RootGridPane extends GridPane {
Button btButton1, btLaden, btSpeichern; // Main Buttons
Button btButton4, btButton5, btButton6, btButtonSieben, btButtonAcht; // FlowPane
public RootGridPane() {
initComponents();
addComponents();
}
public void initComponents() {
btButton1 = new Button("Button1");
btButton1.setPrefSize(200, 200);
btLaden = new Button("Laden-Button");
btLaden.setPrefSize(200, 200);
btSpeichern = new Button("Speichern-Button");
btSpeichern.setPrefSize(200, 200);
}
public void addComponents() {
add(btButton1, 0, 0);
add(btSpeichern, 0, 1);
add(btLaden, 1, 0);
}
}