Skip to content

Commit

Permalink
Merge pull request #96 from pra-navi/ui/task-status
Browse files Browse the repository at this point in the history
feat: Update UI for Result Display Box
  • Loading branch information
jiakai-17 authored Oct 25, 2023
2 parents 84f3d3e + 7ff8694 commit d79a756
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 32 deletions.
3 changes: 3 additions & 0 deletions src/main/java/seedu/address/ui/MainWindow.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.scene.control.MenuItem;
import javafx.scene.control.SplitPane;
import javafx.scene.control.TextInputControl;
import javafx.scene.input.KeyCombination;
import javafx.scene.input.KeyEvent;
Expand Down Expand Up @@ -128,6 +129,8 @@ void fillInnerParts() {

CommandBox commandBox = new CommandBox(this::executeCommand);
commandBoxPlaceholder.getChildren().add(commandBox.getRoot());

SplitPane.setResizableWithParent(resultDisplayPlaceholder, false);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/view/DarkTheme.css
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@
.result-display {
-fx-background-color: transparent;
-fx-font-family: "Segoe UI Light";
-fx-font-size: 13pt;
-fx-font-size: 12pt;
-fx-text-fill: white;
}

Expand Down
66 changes: 36 additions & 30 deletions src/main/resources/view/MainWindow.fxml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<URL value="@Extensions.css" />
</stylesheets>

<VBox>
<VBox prefHeight="500">
<MenuBar fx:id="menuBar" VBox.vgrow="NEVER">
<Menu mnemonicParsing="false" text="File">
<MenuItem mnemonicParsing="false" onAction="#handleExit" text="Exit" />
Expand All @@ -40,39 +40,45 @@
</padding>
</StackPane>

<StackPane VBox.vgrow="NEVER" fx:id="resultDisplayPlaceholder" styleClass="pane-with-border"
minHeight="100" prefHeight="100" maxHeight="100">
<padding>
<Insets top="5" right="10" bottom="5" left="10" />
</padding>
</StackPane>
<SplitPane dividerPositions="0.1" prefWidth="700" orientation="VERTICAL" VBox.vgrow="ALWAYS" >
<items>

<SplitPane dividerPositions="0.50" prefHeight="160" prefWidth="700" VBox.vgrow="ALWAYS">
<AnchorPane minHeight="160" minWidth="200">
<children>
<VBox fx:id="personList" styleClass="pane-with-border" minWidth="160" prefWidth="200"
AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0"
AnchorPane.topAnchor="0.0">
<StackPane VBox.vgrow="ALWAYS" fx:id="resultDisplayPlaceholder" styleClass="pane-with-border"
minHeight="100" prefHeight="100" >
<padding>
<Insets top="10" right="10" bottom="10" left="10" />
<Insets top="5" right="10" bottom="5" left="10" />
</padding>
<StackPane fx:id="personListPanelPlaceholder" VBox.vgrow="ALWAYS"/>
</VBox>
</children>
</AnchorPane>
</StackPane>

<AnchorPane minHeight="160" minWidth="200">
<children>
<VBox fx:id="taskList" styleClass="pane-with-border" minWidth="160" prefWidth="200"
AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0"
AnchorPane.topAnchor="0.0">
<padding>
<Insets top="10" right="10" bottom="10" left="10" />
</padding>
<StackPane fx:id="taskListPanelPlaceholder" VBox.vgrow="ALWAYS"/>
</VBox>
</children>
</AnchorPane>

<SplitPane dividerPositions="0.50" prefHeight="160" prefWidth="700" VBox.vgrow="ALWAYS">
<AnchorPane minHeight="160" minWidth="200">
<children>
<VBox fx:id="personList" styleClass="pane-with-border" minWidth="160" prefWidth="200"
AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0"
AnchorPane.topAnchor="0.0">
<padding>
<Insets top="10" right="10" bottom="10" left="10" />
</padding>
<StackPane fx:id="personListPanelPlaceholder" VBox.vgrow="ALWAYS"/>
</VBox>
</children>
</AnchorPane>

<AnchorPane minHeight="160" minWidth="200">
<children>
<VBox fx:id="taskList" styleClass="pane-with-border" minWidth="160" prefWidth="200"
AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0"
AnchorPane.topAnchor="0.0">
<padding>
<Insets top="10" right="10" bottom="10" left="10" />
</padding>
<StackPane fx:id="taskListPanelPlaceholder" VBox.vgrow="ALWAYS"/>
</VBox>
</children>
</AnchorPane>
</SplitPane>
</items>
</SplitPane>

<StackPane fx:id="statusbarPlaceholder" VBox.vgrow="NEVER" />
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/view/ResultDisplay.fxml
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@

<StackPane fx:id="placeHolder" styleClass="pane-with-border" xmlns="http://javafx.com/javafx/17"
xmlns:fx="http://javafx.com/fxml/1">
<TextArea fx:id="resultDisplay" editable="false" styleClass="result-display"/>
<TextArea fx:id="resultDisplay" editable="false" styleClass="result-display" wrapText="true"/>
</StackPane>

0 comments on commit d79a756

Please sign in to comment.