Skip to content

Commit

Permalink
Add application title and icon
Browse files Browse the repository at this point in the history
  • Loading branch information
NereusWB922 committed Sep 17, 2023
1 parent ac11b52 commit 5aa5944
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/main/java/corgi/Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Scene;
import javafx.scene.image.Image;
import javafx.scene.layout.AnchorPane;
import javafx.stage.Stage;

Expand All @@ -18,6 +19,11 @@ public class Main extends Application {

@Override
public void start(Stage stage) {
stage.setTitle("Corgi - The most intelligent chatbot");

Image icon = new Image(this.getClass().getResourceAsStream("/images/icon.jpg"));
stage.getIcons().add(icon);

try {
FXMLLoader fxmlLoader = new FXMLLoader(Main.class.getResource("/view/MainWindow.fxml"));
AnchorPane ap = fxmlLoader.load();
Expand Down
Binary file added src/main/resources/images/icon.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 5aa5944

Please sign in to comment.