ParetSence

This commit is contained in:
Reshad Meher 2023-01-17 22:30:56 +01:00
parent 3bb141fb52
commit 400ffb0e98
3 changed files with 31 additions and 9 deletions

View File

@ -2,6 +2,7 @@ package com.bib.essensbestellungsverwaltung;
import javafx.application.Application; import javafx.application.Application;
import javafx.fxml.FXMLLoader; import javafx.fxml.FXMLLoader;
import javafx.scene.Parent;
import javafx.scene.Scene; import javafx.scene.Scene;
import javafx.stage.Stage; import javafx.stage.Stage;
@ -9,17 +10,17 @@ import java.io.IOException;
public class HelloApplication extends Application { public class HelloApplication extends Application {
@Override @Override
public void start(Stage stage) throws IOException { public void start(Stage primaryStage) throws IOException {
FXMLLoader fxmlLoader = new FXMLLoader(HelloApplication.class.getResource("hello-view.fxml")); Parent fxmlStartSeiteLoader = FXMLLoader.load(HelloApplication.class.getResource("menue-view.fxml"));
/** /**
* @autor: Reshad Meher * @author: Reshad Meher
* Fenstergrößer * Fenstergrößer
* Fenstertitle * Fenstertitle
*/ */
Scene scene = new Scene(fxmlLoader.load(), 480, 280); primaryStage.setTitle("Essen Bestellung im Kindergarten");
stage.setTitle("Essen Bestellung im Kindergarten"); primaryStage.setScene(new Scene(fxmlStartSeiteLoader,950,480));
stage.setScene(scene); primaryStage.show();
stage.show();
} }
public static void main(String[] args) { public static void main(String[] args) {

View File

@ -1,4 +1,25 @@
/**
* Author: Reshad Meher
* Startseite
* fxml: menue-view.fxml
*/
package com.bib.essensbestellungsverwaltung; package com.bib.essensbestellungsverwaltung;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.fxml.FXMLLoader;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.scene.control.Alert;
import javafx.stage.Stage;
import java.io.IOException;
public class MenueController { public class MenueController {
@FXML
private void onBtLoginClick(){
Alert alert = new Alert(Alert.AlertType.ERROR, "Hi");
alert.showAndWait();
}
} }

View File

@ -11,10 +11,10 @@
<children> <children>
<Label alignment="CENTER" layoutX="14.0" layoutY="14.0" prefHeight="35.0" prefWidth="895.0" text="Essenbestellung"> <Label alignment="CENTER" layoutX="14.0" layoutY="14.0" prefHeight="35.0" prefWidth="895.0" text="Essenbestellung">
<font> <font>
<Font size="28.0"/> <Font size="28.0" />
</font> </font>
</Label> </Label>
<Button alignment="CENTER" layoutX="868.0" layoutY="61.0" mnemonicParsing="false" style="-fx-background-color: white;" text="Login" /> <Button alignment="CENTER" layoutX="845.0" layoutY="64.0" mnemonicParsing="false" style="-fx-background-color: white;" text="Login" onAction="#onBtLoginClick"/>
<VBox layoutX="14.0" layoutY="100.0" prefHeight="350.0" prefWidth="180.0" style="-fx-background-color: transparent; -fx-padding: 5;"> <VBox layoutX="14.0" layoutY="100.0" prefHeight="350.0" prefWidth="180.0" style="-fx-background-color: transparent; -fx-padding: 5;">
<children> <children>
<Label alignment="CENTER" contentDisplay="TOP" prefHeight="23.0" prefWidth="196.0" style="-fx-background-color: lightdarkblue;" text="Montag" textAlignment="CENTER"> <Label alignment="CENTER" contentDisplay="TOP" prefHeight="23.0" prefWidth="196.0" style="-fx-background-color: lightdarkblue;" text="Montag" textAlignment="CENTER">