Skip to content
Snippets Groups Projects
Commit 4b729484 authored by Kiljala Renne Lauri Olavi's avatar Kiljala Renne Lauri Olavi
Browse files

lisätty käyttöliittymään

parent 2336149f
No related branches found
No related tags found
No related merge requests found
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.TextField?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.ColumnConstraints?>
<?import javafx.scene.layout.GridPane?>
<?import javafx.scene.layout.RowConstraints?>
<?import javafx.scene.text.Font?>
<?import javafx.scene.text.Text?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="fxHarakka.LuoProjekti"
prefHeight="400.0" prefWidth="600.0">
<AnchorPane prefHeight="400.0" prefWidth="600.0" xmlns="http://javafx.com/javafx/23.0.1" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fxHarakka.LuoProjektiController">
<children>
<GridPane layoutX="136.0" layoutY="144.0" prefHeight="400.0" prefWidth="600.0" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<columnConstraints>
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
</rowConstraints>
<children>
<TextField fx:id="projektiNimi" onKeyTyped="#setNimi" promptText="Syötä nimi" GridPane.columnIndex="1" GridPane.rowIndex="1" />
<TextField fx:id="projektiAihe" onKeyTyped="#setAihe" promptText="Syötä aihe" GridPane.columnIndex="1" GridPane.rowIndex="2" />
<Text strokeType="OUTSIDE" strokeWidth="0.0" text="Projektin nimi" textAlignment="RIGHT" GridPane.rowIndex="1">
<font>
<Font size="22.0" />
</font>
</Text>
<Text strokeType="OUTSIDE" strokeWidth="0.0" text="Aihe" GridPane.rowIndex="2">
<font>
<Font size="22.0" />
</font>
</Text>
<Text strokeType="OUTSIDE" strokeWidth="0.0" text="Kesto" GridPane.rowIndex="3">
<font>
<Font size="22.0" />
</font>
</Text>
<TextField fx:id="projektiKesto" onKeyTyped="#setKesto" promptText="Viikoissa (esim 4 tai 5)" GridPane.columnIndex="1" GridPane.rowIndex="3" />
<Button fx:id="luoProjekti" mnemonicParsing="false" onAction="#luoProjekti" text="Luo Projekti" GridPane.columnIndex="2" GridPane.rowIndex="4" />
<Button fx:id="hylkaaProjekti" mnemonicParsing="false" onAction="#HylkaaProjekti" text="Hylkää muutokset" GridPane.columnIndex="1" GridPane.rowIndex="4" />
</children>
</GridPane>
</children>
</AnchorPane>
package fxHarakka;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.scene.control.Button;
import javafx.scene.control.TextField;
import javafx.scene.input.KeyEvent;
public class LuoProjektiController {
}
@FXML
private Button hylkaaProjekti;
@FXML
private Button luoProjekti;
@FXML
private TextField projektiAihe;
@FXML
private TextField projektiKesto;
@FXML
private TextField projektiNimi;
@FXML
void HylkaaProjekti(ActionEvent event) {
}
@FXML
void luoProjekti(ActionEvent event) {
}
@FXML
void setAihe(KeyEvent event) {
}
@FXML
void setKesto(KeyEvent event) {
}
@FXML
void setNimi(KeyEvent event) {
}
}
\ No newline at end of file
......@@ -15,7 +15,7 @@
<?import javafx.scene.layout.Pane?>
<?import javafx.scene.layout.RowConstraints?>
<SplitPane dividerPositions="0.5, 0.510590015128593" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="445.0" prefWidth="663.0" xmlns="http://javafx.com/javafx/23.0.1" xmlns:fx="http://javafx.com/fxml/1">
<SplitPane dividerPositions="0.5, 0.510590015128593" maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="445.0" prefWidth="663.0" xmlns="http://javafx.com/javafx/23.0.1" xmlns:fx="http://javafx.com/fxml/1" fx:controller="fxHarakka.OksaController">
<items>
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="160.0" prefWidth="100.0">
<children>
......
package fxHarakka;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.scene.control.Button;
public class OksaController {
@FXML
private Button Tallenna;
@FXML
void HylkaaTehtava(ActionEvent event) {
}
@FXML
void Tallenna(ActionEvent event) {
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment