parent
49487be991
commit
c90cae7787
@ -0,0 +1,38 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?import javafx.scene.control.*?>
|
||||
<?import javafx.scene.layout.*?>
|
||||
<AnchorPane xmlns:fx="http://javafx.com/fxml"
|
||||
fx:controller="com.example.myapp.controller.LoginController"
|
||||
prefWidth="400" prefHeight="320"
|
||||
style="-fx-padding: 20;">
|
||||
<children>
|
||||
<Label layoutX="20" layoutY="20" text="用户登录" style="-fx-font-size: 18; -fx-font-weight: bold;"/>
|
||||
|
||||
<Label layoutX="20" layoutY="60" text="用户名/邮箱:" style="-fx-font-size: 14;"/> <!-- 修改标签 -->
|
||||
<TextField fx:id="identifierField" layoutX="120" layoutY="56" prefWidth="260"
|
||||
style="-fx-font-size: 14;" promptText="请输入用户名或邮箱"/> <!-- 修改提示文本 -->
|
||||
|
||||
<Label layoutX="20" layoutY="100" text="密码:" style="-fx-font-size: 14;"/>
|
||||
<PasswordField fx:id="passwordField" layoutX="120" layoutY="96" prefWidth="260"
|
||||
style="-fx-font-size: 14;" promptText="请输入密码"/>
|
||||
|
||||
<HBox layoutX="120" layoutY="140" spacing="15">
|
||||
<Button fx:id="loginBtn" text="登录" onAction="#onLogin"
|
||||
prefWidth="70" style="-fx-font-size: 14;"/>
|
||||
<Button fx:id="registerBtn" text="注册" onAction="#onRegister"
|
||||
prefWidth="70" style="-fx-font-size: 14;"/>
|
||||
<Button fx:id="forgotPasswordBtn" text="忘记密码" onAction="#onForgotPassword"
|
||||
prefWidth="80" style="-fx-font-size: 14;"/>
|
||||
<Button text="清空" onAction="#onClear"
|
||||
prefWidth="70" style="-fx-font-size: 14;"/>
|
||||
</HBox>
|
||||
|
||||
<Label fx:id="statusLabel" layoutX="20" layoutY="190" prefWidth="360"
|
||||
style="-fx-font-size: 12; -fx-wrap-text: true;"/>
|
||||
|
||||
<!-- 提示信息 -->
|
||||
<Label layoutX="20" layoutY="230" prefWidth="360"
|
||||
text="提示:可以使用用户名或邮箱登录,忘记密码可通过邮箱重置"
|
||||
style="-fx-font-size: 11; -fx-text-fill: gray; -fx-wrap-text: true;"/>
|
||||
</children>
|
||||
</AnchorPane>
|
||||
Loading…
Reference in new issue