Update layout to work on linux

This commit is contained in:
Nathan McRae 2025-02-19 22:31:03 -08:00
parent 5703d9bce4
commit 307620a930
6 changed files with 12 additions and 7 deletions

View File

@ -5,6 +5,7 @@
<?import javafx.scene.control.TextField?> <?import javafx.scene.control.TextField?>
<?import javafx.scene.layout.AnchorPane?> <?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.VBox?> <?import javafx.scene.layout.VBox?>
<?import javafx.scene.text.Font?>
<VBox maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="92.0" prefWidth="367.0" stylesheets="@css/application.css" xmlns="http://javafx.com/javafx/23.0.1" xmlns:fx="http://javafx.com/fxml/1" fx:controller="name.nathanmcrae.numbersstation.AddPrefixController"> <VBox maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="92.0" prefWidth="367.0" stylesheets="@css/application.css" xmlns="http://javafx.com/javafx/23.0.1" xmlns:fx="http://javafx.com/fxml/1" fx:controller="name.nathanmcrae.numbersstation.AddPrefixController">
<children> <children>
@ -12,8 +13,11 @@
<children> <children>
<Button fx:id="okButton" layoutX="89.0" layoutY="67.0" mnemonicParsing="false" prefHeight="25.0" prefWidth="65.0" text="OK" AnchorPane.bottomAnchor="15.0" AnchorPane.rightAnchor="89.0" /> <Button fx:id="okButton" layoutX="89.0" layoutY="67.0" mnemonicParsing="false" prefHeight="25.0" prefWidth="65.0" text="OK" AnchorPane.bottomAnchor="15.0" AnchorPane.rightAnchor="89.0" />
<Button fx:id="cancelButton" layoutX="169.0" layoutY="67.0" mnemonicParsing="false" prefHeight="25.0" prefWidth="65.0" text="Cancel" AnchorPane.bottomAnchor="15.0" AnchorPane.rightAnchor="9.0" /> <Button fx:id="cancelButton" layoutX="169.0" layoutY="67.0" mnemonicParsing="false" prefHeight="25.0" prefWidth="65.0" text="Cancel" AnchorPane.bottomAnchor="15.0" AnchorPane.rightAnchor="9.0" />
<Label layoutX="14.0" layoutY="14.0" text="Enter a message prefix / identifier:" /> <Label layoutX="14.0" layoutY="14.0" text="Enter a message prefix / identifier:">
<TextField fx:id="prefixField" layoutX="203.0" layoutY="10.0" prefHeight="25.0" prefWidth="105.0" AnchorPane.leftAnchor="203.0" AnchorPane.rightAnchor="10.0" /> <font>
<Font name="Liberation Sans" size="13.0" />
</font></Label>
<TextField fx:id="prefixField" layoutX="216.0" layoutY="10.0" prefHeight="25.0" prefWidth="86.0" AnchorPane.leftAnchor="216.0" AnchorPane.rightAnchor="10.0" />
</children> </children>
</AnchorPane> </AnchorPane>
</children> </children>

View File

@ -76,7 +76,7 @@
</font> </font>
</Label> </Label>
<Button layoutX="554.0" layoutY="14.0" mnemonicParsing="false" text="Staton Settings" AnchorPane.rightAnchor="14.0" AnchorPane.topAnchor="14.0" /> <Button layoutX="554.0" layoutY="14.0" mnemonicParsing="false" text="Staton Settings" AnchorPane.rightAnchor="14.0" AnchorPane.topAnchor="14.0" />
<Button layoutX="414.0" layoutY="14.0" mnemonicParsing="false" text="Retrieve now" AnchorPane.rightAnchor="121.0" AnchorPane.topAnchor="14.0" /> <Button layoutX="403.0" layoutY="14.0" mnemonicParsing="false" text="Retrieve now" AnchorPane.rightAnchor="123.0" AnchorPane.topAnchor="14.0" />
</children> </children>
</AnchorPane> </AnchorPane>
<Label text="Messages"> <Label text="Messages">

View File

@ -42,6 +42,7 @@
<?import javafx.scene.layout.FlowPane?> <?import javafx.scene.layout.FlowPane?>
<?import javafx.scene.layout.VBox?> <?import javafx.scene.layout.VBox?>
<?import javafx.scene.text.Font?> <?import javafx.scene.text.Font?>
<?scenebuilder-stylesheet css/application.css?>
<AnchorPane stylesheets="@css/application.css" xmlns="http://javafx.com/javafx/23.0.1" xmlns:fx="http://javafx.com/fxml/1" fx:controller="name.nathanmcrae.numbersstation.MainController"> <AnchorPane stylesheets="@css/application.css" xmlns="http://javafx.com/javafx/23.0.1" xmlns:fx="http://javafx.com/fxml/1" fx:controller="name.nathanmcrae.numbersstation.MainController">
<children> <children>
@ -54,7 +55,7 @@
<children> <children>
<Button layoutX="209.0" layoutY="1.0" mnemonicParsing="false" onAction="#handleSelectStationButtonPress" text="Select Station" /> <Button layoutX="209.0" layoutY="1.0" mnemonicParsing="false" onAction="#handleSelectStationButtonPress" text="Select Station" />
<Label layoutY="5.0" prefHeight="17.0" prefWidth="49.0" text="Station: " /> <Label layoutY="5.0" prefHeight="17.0" prefWidth="49.0" text="Station: " />
<TextField fx:id="stationNameField" editable="false" layoutX="49.0" style="-fx-background-color: #EEEEEE; -fx-border-color: #AAAAAA;" text="My Station" /> <TextField fx:id="stationNameField" editable="false" layoutX="49.0" prefHeight="25.0" prefWidth="153.0" style="-fx-background-color: #EEEEEE; -fx-border-color: #AAAAAA;" text="My Station" />
<Button layoutX="602.0" layoutY="1.0" mnemonicParsing="false" text="Help" AnchorPane.rightAnchor="0.0" /> <Button layoutX="602.0" layoutY="1.0" mnemonicParsing="false" text="Help" AnchorPane.rightAnchor="0.0" />
<Button layoutX="532.0" layoutY="1.0" mnemonicParsing="false" text="Settings" AnchorPane.rightAnchor="49.0" /> <Button layoutX="532.0" layoutY="1.0" mnemonicParsing="false" text="Settings" AnchorPane.rightAnchor="49.0" />
</children> </children>

View File

@ -42,7 +42,7 @@
<children> <children>
<Label fx:id="titleLabel" layoutX="86.0" layoutY="24.0" text="Notification title (this sure is a title)"> <Label fx:id="titleLabel" layoutX="86.0" layoutY="24.0" text="Notification title (this sure is a title)">
<font> <font>
<Font name="System Bold" size="16.0" /> <Font name="Liberation Sans Bold" size="16.0" />
</font> </font>
</Label> </Label>
<Button fx:id="dismissButton" layoutX="325.0" layoutY="139.0" mnemonicParsing="false" onMousePressed="#handleDismissButtonPressed" text="Dismiss" AnchorPane.bottomAnchor="14.0" AnchorPane.rightAnchor="14.0" /> <Button fx:id="dismissButton" layoutX="325.0" layoutY="139.0" mnemonicParsing="false" onMousePressed="#handleDismissButtonPressed" text="Dismiss" AnchorPane.bottomAnchor="14.0" AnchorPane.rightAnchor="14.0" />

View File

@ -13,7 +13,7 @@
<Font size="20.0" /> <Font size="20.0" />
</font> </font>
</Label> </Label>
<Button layoutX="358.0" layoutY="17.0" mnemonicParsing="false" onAction="#handleAddButtonPress" text="+" AnchorPane.rightAnchor="54.5" AnchorPane.topAnchor="17.0" /> <Button layoutX="358.0" layoutY="17.0" mnemonicParsing="false" onAction="#handleAddButtonPress" prefHeight="25.0" prefWidth="26.0" text="+" AnchorPane.rightAnchor="55.0" AnchorPane.topAnchor="17.0" />
<Button layoutX="391.0" layoutY="17.0" mnemonicParsing="false" onAction="#handleRemoveButtonPress" prefHeight="25.0" prefWidth="25.0" text="-" AnchorPane.rightAnchor="21.0" AnchorPane.topAnchor="17.0" /> <Button layoutX="391.0" layoutY="17.0" mnemonicParsing="false" onAction="#handleRemoveButtonPress" prefHeight="25.0" prefWidth="25.0" text="-" AnchorPane.rightAnchor="21.0" AnchorPane.topAnchor="17.0" />
<ListView fx:id="stationListView" layoutX="14.0" layoutY="57.0" prefHeight="301.0" prefWidth="409.0" AnchorPane.bottomAnchor="42.0" AnchorPane.leftAnchor="14.0" AnchorPane.rightAnchor="14.0" AnchorPane.topAnchor="57.0" /> <ListView fx:id="stationListView" layoutX="14.0" layoutY="57.0" prefHeight="301.0" prefWidth="409.0" AnchorPane.bottomAnchor="42.0" AnchorPane.leftAnchor="14.0" AnchorPane.rightAnchor="14.0" AnchorPane.topAnchor="57.0" />
<Button layoutX="313.0" layoutY="365.0" mnemonicParsing="false" onMousePressed="#handleSelectButtonPress" text="Select" AnchorPane.bottomAnchor="10.0" AnchorPane.rightAnchor="76.5" /> <Button layoutX="313.0" layoutY="365.0" mnemonicParsing="false" onMousePressed="#handleSelectButtonPress" text="Select" AnchorPane.bottomAnchor="10.0" AnchorPane.rightAnchor="76.5" />

View File

@ -89,7 +89,7 @@
</RadioButton> </RadioButton>
<Label layoutX="182.0" layoutY="99.0" text="Username:" AnchorPane.rightAnchor="340.0" /> <Label layoutX="182.0" layoutY="99.0" text="Username:" AnchorPane.rightAnchor="340.0" />
<Label layoutX="380.0" layoutY="99.0" text="Password:" AnchorPane.rightAnchor="142.0" /> <Label layoutX="380.0" layoutY="99.0" text="Password:" AnchorPane.rightAnchor="142.0" />
<TextField fx:id="usernameField" layoutX="245.0" layoutY="95.0" prefHeight="25.0" prefWidth="135.0" AnchorPane.rightAnchor="198.0" /> <TextField fx:id="usernameField" layoutX="245.0" layoutY="95.0" prefHeight="25.0" prefWidth="124.0" AnchorPane.rightAnchor="209.0" />
<PasswordField fx:id="passwordField" layoutX="444.0" layoutY="95.0" prefHeight="25.0" prefWidth="135.0" AnchorPane.rightAnchor="0.0" /> <PasswordField fx:id="passwordField" layoutX="444.0" layoutY="95.0" prefHeight="25.0" prefWidth="135.0" AnchorPane.rightAnchor="0.0" />
<TextField fx:id="externalProgramCommandField" layoutX="-2.0" layoutY="131.0" prefHeight="25.0" prefWidth="580.0" AnchorPane.leftAnchor="-2.0" AnchorPane.rightAnchor="0.0" /> <TextField fx:id="externalProgramCommandField" layoutX="-2.0" layoutY="131.0" prefHeight="25.0" prefWidth="580.0" AnchorPane.leftAnchor="-2.0" AnchorPane.rightAnchor="0.0" />
<Button fx:id="testConnectionButton" layoutX="464.0" layoutY="7.0" mnemonicParsing="false" onMousePressed="#handleTestConnectionButtonPress" text="Test connection" /> <Button fx:id="testConnectionButton" layoutX="464.0" layoutY="7.0" mnemonicParsing="false" onMousePressed="#handleTestConnectionButtonPress" text="Test connection" />