This repository has been archived on 2021-12-05. You can view files and clone it, but cannot push or open issues or pull requests.
envoy/client/src/main/resources/fxml/ChatScene.fxml

338 lines
12 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.geometry.Rectangle2D?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.ContextMenu?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.control.ListView?>
<?import javafx.scene.control.MenuItem?>
<?import javafx.scene.control.Tab?>
<?import javafx.scene.control.TabPane?>
<?import javafx.scene.control.TextArea?>
<?import javafx.scene.control.Tooltip?>
<?import javafx.scene.image.ImageView?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.ColumnConstraints?>
<?import javafx.scene.layout.GridPane?>
<?import javafx.scene.layout.HBox?>
<?import javafx.scene.layout.Region?>
<?import javafx.scene.layout.RowConstraints?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.text.Font?>
<?import javafx.stage.Screen?>
<GridPane maxHeight="-Infinity" maxWidth="-Infinity"
minHeight="400.0" minWidth="500.0"
prefHeight="${screen.visualBounds.height}"
prefWidth="${screen.visualBounds.width}"
xmlns="http://javafx.com/javafx/11.0.1"
xmlns:fx="http://javafx.com/fxml/1"
fx:controller="envoy.client.ui.controller.ChatScene">
<fx:define>
<Screen fx:factory="getPrimary" fx:id="screen" />
</fx:define>
<columnConstraints>
<ColumnConstraints hgrow="NEVER"
maxWidth="327.99997965494794" minWidth="-Infinity" prefWidth="317.0" />
<ColumnConstraints hgrow="ALWAYS"
maxWidth="1.7976931348623157E308" />
</columnConstraints>
<rowConstraints>
<RowConstraints maxHeight="122.00000508626302"
minHeight="-Infinity" prefHeight="96.66666158040364" vgrow="NEVER" />
<RowConstraints maxHeight="1.7976931348623157E308"
minHeight="50.0" prefHeight="949.3333384195963" vgrow="ALWAYS" />
<RowConstraints maxHeight="59.3333740234375"
minHeight="-Infinity" prefHeight="22.666748046875" vgrow="NEVER" />
<RowConstraints maxHeight="120.0" minHeight="-Infinity"
prefHeight="83.333251953125" vgrow="NEVER" />
</rowConstraints>
<children>
<TabPane fx:id="tabPane" prefHeight="200.0" prefWidth="200.0"
tabClosingPolicy="UNAVAILABLE" GridPane.rowIndex="1"
GridPane.rowSpan="2147483647">
<tabs>
<Tab text="">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0">
<children>
<VBox fx:id="contactOperations" prefHeight="3000.0"
prefWidth="316.0">
<children>
<VBox id="search-panel" maxHeight="-Infinity"
minHeight="-Infinity" prefHeight="80.0" prefWidth="316.0">
<children>
<Label id="contact-search-enter-container"
maxHeight="30.0" minHeight="30.0" prefHeight="30.0"
prefWidth="325.0">
<graphic>
<TextArea id="contact-search-input"
fx:id="contactSearch" focusTraversable="false"
maxHeight="30.0" minHeight="30.0"
onInputMethodTextChanged="#searchContacts"
onKeyTyped="#searchContacts" prefHeight="30.0"
prefWidth="200.0" promptText="Search Contacts">
<font>
<Font size="14.0" />
</font>
<padding>
<Insets left="12.0" right="12.0" />
</padding>
</TextArea>
</graphic>
<VBox.margin>
<Insets left="10.0" right="10.0" top="3.0" />
</VBox.margin>
</Label>
<HBox fx:id="contactSpecificOnlineOperations"
id="underline" alignment="TOP_CENTER" prefHeight="41.0"
prefWidth="296.0" spacing="5.0">
<children>
<Button fx:id="newContactButton"
mnemonicParsing="true"
onAction="#addContactButtonClicked" prefWidth="100.0"
text=" Add Contact">
<padding>
<Insets bottom="5.0" left="5.0" right="5.0"
top="5.0" />
</padding>
<HBox.margin>
<Insets />
</HBox.margin>
</Button>
<Button fx:id="newGroupButton"
mnemonicParsing="false"
onAction="#groupCreationButtonClicked" prefWidth="100.0"
text="New Group">
<HBox.margin>
<Insets />
</HBox.margin>
<padding>
<Insets bottom="5.0" left="5.0" right="5.0"
top="5.0" />
</padding>
</Button>
</children>
<VBox.margin>
<Insets left="10.0" right="10.0" top="5.0" />
</VBox.margin>
<padding>
<Insets top="3.0" />
</padding>
</HBox>
</children>
</VBox>
<ListView id="chat-list" fx:id="chatList"
focusTraversable="false" onMouseClicked="#chatListClicked"
prefWidth="316.0" VBox.vgrow="ALWAYS">
<padding>
<Insets bottom="5.0" left="5.0" right="2.0" top="5.0" />
</padding>
</ListView>
</children>
</VBox>
</children>
</AnchorPane>
</content>
</Tab>
<Tab fx:id="contactSearchTab" text="">
<content>
</content>
</Tab>
<Tab fx:id="groupCreationTab" text="" />
</tabs>
<GridPane.margin>
<Insets right="1.0" />
</GridPane.margin>
</TabPane>
<HBox id="top-bar" alignment="CENTER_LEFT" prefHeight="100.0">
<children>
<ImageView id="profile-pic" fx:id="clientProfilePic"
fitHeight="43.0" fitWidth="43.0" pickOnBounds="true"
preserveRatio="true">
<HBox.margin>
<Insets left="15.0" top="5.0" right="10.0" />
</HBox.margin>
</ImageView>
<HBox id="transparent-background" fx:id="ownContactControl">
<children>
<Region id="transparent-background" prefWidth="120"
fx:id="spaceBetweenUserAndSettingsButton" HBox.hgrow="ALWAYS" />
<Button fx:id="settingsButton" mnemonicParsing="false"
onAction="#settingsButtonClicked" prefHeight="30.0"
prefWidth="30.0" text="" alignment="CENTER">
<padding>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</padding>
<HBox.margin>
<Insets bottom="35.0" left="5.0" top="35.0" />
</HBox.margin>
</Button>
</children>
</HBox>
</children>
<GridPane.margin>
<Insets bottom="1.0" right="1.0" />
</GridPane.margin>
</HBox>
<ListView id="message-list" fx:id="messageList"
focusTraversable="false" GridPane.columnIndex="1"
GridPane.columnSpan="2147483647" GridPane.rowIndex="1"
GridPane.rowSpan="2">
<GridPane.margin>
<Insets />
</GridPane.margin>
<padding>
<Insets bottom="5.0" top="5.0" />
</padding>
</ListView>
<HBox alignment="CENTER" GridPane.columnIndex="1"
GridPane.rowIndex="3">
<children>
<Label id="text-enter-container" alignment="CENTER"
minWidth="300.0" prefHeight="100.0" prefWidth="800.0">
<graphic>
<TextArea id="message-enter" fx:id="messageTextArea"
disable="true" onInputMethodTextChanged="#messageTextUpdated"
onKeyPressed="#checkPostConditions"
onKeyTyped="#checkKeyCombination" prefHeight="100.0"
prefWidth="1250.0" promptText="Enter Message" wrapText="true">
<opaqueInsets>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</opaqueInsets>
<padding>
<Insets left="17.0" right="17.0" />
</padding>
</TextArea>
</graphic>
</Label>
<HBox prefHeight="38.0" prefWidth="100.0" spacing="5.0">
<children>
<Button id="round-button" fx:id="postButton"
defaultButton="true" disable="true" minWidth="40.0"
mnemonicParsing="true" onAction="#postMessage" prefHeight="40.0"
prefWidth="40.0" text="Post">
<tooltip>
<Tooltip anchorLocation="WINDOW_TOP_LEFT"
autoHide="true" maxWidth="350.0"
text="Click this button to send the message. If it is disabled, you first have to select a contact to send it to. A message may automatically be sent when you press (Ctrl + ) Enter, according to your preferences. Additionally sends a message when pressing &quot;Alt&quot; + &quot;P&quot;."
wrapText="true" />
</tooltip>
<contextMenu>
<ContextMenu anchorLocation="CONTENT_TOP_LEFT">
<items>
<MenuItem mnemonicParsing="false"
onAction="#copyAndPostMessage" text="Copy and Send" />
</items>
</ContextMenu>
</contextMenu>
<padding>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</padding>
<HBox.margin>
<Insets left="10.0" />
</HBox.margin>
</Button>
<Button id="round-button" fx:id="voiceButton"
disable="true" minWidth="40.0" onAction="#voiceButtonClicked"
prefHeight="40.0" prefWidth="40.0">
<padding>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</padding>
</Button>
<Button id="round-button" fx:id="attachmentButton"
disable="true" minWidth="40.0" mnemonicParsing="false"
onAction="#attachmentButtonClicked" prefHeight="40.0"
prefWidth="40.0">
<padding>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</padding>
</Button>
</children>
<HBox.margin>
<Insets left="5.0" />
</HBox.margin>
</HBox>
</children>
<GridPane.margin>
<Insets bottom="40.0" left="10.0" right="10.0" top="15.0" />
</GridPane.margin>
</HBox>
<HBox prefHeight="100.0" prefWidth="200.0"
GridPane.columnIndex="1" GridPane.rowIndex="2">
<children>
<Label id="remaining-chars-label" fx:id="remainingChars"
ellipsisString="" maxHeight="30.0" maxWidth="180.0"
prefHeight="30.0" prefWidth="180.0" text="remaining chars: 0/x"
textFill="LIME" textOverrun="LEADING_WORD_ELLIPSIS" visible="false">
<padding>
<Insets bottom="5.0" top="5.0" />
</padding>
<opaqueInsets>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</opaqueInsets>
<tooltip>
<Tooltip
text="Shows how many chars you can still enter in this message"
wrapText="true" />
</tooltip>
</Label>
<Label fx:id="infoLabel" text="Something happened"
textFill="#faa007" visible="false" wrapText="true">
<padding>
<Insets bottom="5.0" left="5.0" right="5.0" top="5.0" />
</padding>
</Label>
</children>
</HBox>
<ImageView fx:id="attachmentView" pickOnBounds="true"
preserveRatio="true" visible="false" GridPane.columnIndex="1"
GridPane.columnSpan="2147483647" GridPane.halignment="RIGHT"
GridPane.rowIndex="2">
<viewport>
<Rectangle2D height="20.0" width="20.0" />
</viewport>
<GridPane.margin>
<Insets bottom="5.0" right="10.0" top="5.0" />
</GridPane.margin>
</ImageView>
<HBox id="top-bar" alignment="CENTER_LEFT" prefHeight="100.0"
prefWidth="200.0" GridPane.columnIndex="1">
<children>
<ImageView id="profile-pic" fx:id="recipientProfilePic"
fitHeight="43.0" fitWidth="43.0" pickOnBounds="true"
preserveRatio="true">
<HBox.margin>
<Insets left="20.0" top="5.0" />
</HBox.margin>
</ImageView>
<VBox alignment="CENTER_LEFT" prefHeight="97.0"
prefWidth="316.0">
<children>
<Label fx:id="topBarContactLabel" text="">
<font>
<Font size="18.0" />
</font>
</Label>
<Label fx:id="topBarStatusLabel" text="" />
</children>
<HBox.margin>
<Insets left="15.0" />
</HBox.margin>
</VBox>
<Region prefHeight="200.0" prefWidth="200.0"
HBox.hgrow="ALWAYS" />
<Button id="round-button" fx:id="messageSearchButton"
contentDisplay="CENTER" maxHeight="-Infinity" maxWidth="-Infinity"
minHeight="-Infinity" minWidth="-Infinity" mnemonicParsing="false"
prefHeight="40.0" prefWidth="40.0" visible="false">
<HBox.margin>
<Insets right="20.0" />
</HBox.margin>
</Button>
</children>
</HBox>
</children>
</GridPane>