diff --git a/src/main/resources/view/Expenses.fxml b/src/main/resources/view/Expenses.fxml index 0311ce16a0f244f8d9f857479060df084e45edcb..59e22ba3fd63eb3744a69b98499874889be03c56 100644 --- a/src/main/resources/view/Expenses.fxml +++ b/src/main/resources/view/Expenses.fxml @@ -21,9 +21,9 @@ <?import javafx.scene.text.Font?> <?import javafx.scene.text.Text?> -<AnchorPane xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="no.ntnu.idatt1002.demo.controller.ExpensesController"> +<AnchorPane prefHeight="695.0" prefWidth="1100.0" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="no.ntnu.idatt1002.demo.controller.ExpensesController"> <children> - <ImageView fitHeight="400.0" fitWidth="600.0" pickOnBounds="true"> + <ImageView fitHeight="695.0" fitWidth="1100.0" pickOnBounds="true"> <image> <Image url="@../Images/backgroundMini.jpg" /> </image> @@ -33,30 +33,34 @@ </ImageView> <BorderPane prefHeight="400.0" prefWidth="600.0"> <top> - <HBox BorderPane.alignment="CENTER"> - <children> - <Button fx:id="returnBtn" mnemonicParsing="false" onAction="#switchScene" text="Return "> + <BorderPane BorderPane.alignment="CENTER"> + <center> + <HBox> + <children> + <Button fx:id="returnBtn" mnemonicParsing="false" onAction="#switchScene" text="Return "> + <opaqueInsets> + <Insets left="100.0" /> + </opaqueInsets> + <HBox.margin> + <Insets left="10.0" top="10.0" /> + </HBox.margin> + </Button> + <Region prefHeight="70.0" prefWidth="141.0" /> + <Text strokeType="OUTSIDE" strokeWidth="0.0" text="Expenses" textAlignment="CENTER"> + <HBox.margin> + <Insets /> + </HBox.margin> + <font> + <Font size="48.0" /> + </font> + </Text> + </children> <opaqueInsets> - <Insets left="100.0" /> + <Insets bottom="10.0" left="10.0" right="10.0" top="10.0" /> </opaqueInsets> - <HBox.margin> - <Insets left="10.0" top="10.0" /> - </HBox.margin> - </Button> - <Region prefHeight="70.0" prefWidth="141.0" /> - <Text strokeType="OUTSIDE" strokeWidth="0.0" text="Expenses" textAlignment="CENTER"> - <HBox.margin> - <Insets /> - </HBox.margin> - <font> - <Font size="48.0" /> - </font> - </Text> - </children> - <opaqueInsets> - <Insets bottom="10.0" left="10.0" right="10.0" top="10.0" /> - </opaqueInsets> - </HBox> + </HBox> + </center> + </BorderPane> </top> <center> <GridPane BorderPane.alignment="CENTER"> @@ -120,23 +124,6 @@ </ComboBox> </children> </VBox> - <HBox prefHeight="100.0" prefWidth="200.0" GridPane.columnSpan="2" GridPane.rowIndex="3"> - <children> - <Button fx:id="incomeBtn" mnemonicParsing="false" onAction="#switchScene" text="Income" /> - <Button fx:id="budgetBtn" mnemonicParsing="false" onAction="#switchScene" text="Budget" /> - <Button disable="true" mnemonicParsing="false" text="Expenses" /> - <Button mnemonicParsing="false" onAction="#switchScene" text="Next"> - <HBox.margin> - <Insets left="170.0" /> - </HBox.margin></Button> - </children> - <padding> - <Insets top="10.0" /> - </padding> - <GridPane.margin> - <Insets top="5.0" /> - </GridPane.margin> - </HBox> <TableView fx:id="expenseTableView" prefHeight="260.0" prefWidth="485.0" GridPane.columnSpan="2" GridPane.rowIndex="1"> <columns> <TableColumn fx:id="dateColumn" prefWidth="75.0" text="Date" /> diff --git a/src/main/resources/view/IncomeAndExpenses.fxml b/src/main/resources/view/IncomeAndExpenses.fxml index e3a0deb7ef8cef96d8ce25ec29417aae84ce8c2f..0680964f6247787cf8fef0e141b544fe53ed596a 100644 --- a/src/main/resources/view/IncomeAndExpenses.fxml +++ b/src/main/resources/view/IncomeAndExpenses.fxml @@ -157,44 +157,34 @@ <RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" /> </rowConstraints> <children> - <GridPane GridPane.rowIndex="1"> - <columnConstraints> - <ColumnConstraints hgrow="ALWAYS" maxWidth="485.3333231608073" minWidth="10.0" prefWidth="427.33335367838544" /> - </columnConstraints> - <rowConstraints> - <RowConstraints maxHeight="298.66665744781494" minHeight="10.0" prefHeight="214.00004069010413" vgrow="SOMETIMES" /> - </rowConstraints> + <VBox maxWidth="490.0" prefHeight="215.0" prefWidth="490.0" GridPane.rowIndex="1"> <children> - <VBox> - <children> - <TableView fx:id="incomeTableView" maxHeight="175.0" prefHeight="175.0" prefWidth="264.0"> - <columns> - <TableColumn fx:id="inDateCol" prefWidth="75.0" text="Date" /> - <TableColumn fx:id="inAmountCol" prefWidth="75.0" text="Amount" /> - <TableColumn fx:id="inCategoryCol" prefWidth="75.0" text="Category" /> - <TableColumn fx:id="inDescriptionCol" prefWidth="75.0" text="Description" /> - <TableColumn fx:id="inRecurringCol" prefWidth="75.0" text="Recurring" /> - </columns> - <columnResizePolicy> - <TableView fx:constant="CONSTRAINED_RESIZE_POLICY" /> - </columnResizePolicy> - <contextMenu> - <ContextMenu> - <items> - <MenuItem mnemonicParsing="false" text="Unspecified Action" /> - </items> - </ContextMenu> - </contextMenu> - </TableView> - <Label text="Sum: "> - <font> - <Font name="Lucida Console" size="14.0" /> - </font> - </Label> - </children> - </VBox> + <TableView fx:id="incomeTableView" maxHeight="175.0" prefHeight="175.0" prefWidth="264.0"> + <columns> + <TableColumn fx:id="inDateCol" prefWidth="75.0" text="Date" /> + <TableColumn fx:id="inAmountCol" prefWidth="75.0" text="Amount" /> + <TableColumn fx:id="inCategoryCol" prefWidth="75.0" text="Category" /> + <TableColumn fx:id="inDescriptionCol" prefWidth="75.0" text="Description" /> + <TableColumn fx:id="inRecurringCol" prefWidth="75.0" text="Recurring" /> + </columns> + <columnResizePolicy> + <TableView fx:constant="CONSTRAINED_RESIZE_POLICY" /> + </columnResizePolicy> + <contextMenu> + <ContextMenu> + <items> + <MenuItem mnemonicParsing="false" text="Unspecified Action" /> + </items> + </ContextMenu> + </contextMenu> + </TableView> + <Label text="Sum: "> + <font> + <Font name="Lucida Console" size="14.0" /> + </font> + </Label> </children> - </GridPane> + </VBox> <Pane GridPane.columnIndex="1" GridPane.rowIndex="1"> <children> <PieChart fx:id="incomePieChart" layoutX="4.0" layoutY="-41.0" legendSide="RIGHT" maxHeight="244.0" maxWidth="512.0" prefHeight="244.0" prefWidth="350.0" title="Income" />