Questions tagged as 'fxml'

2
answers

Get ScrollPane size when set by anchor - JavaFX

I have a ScrollPane anchored on the 4 sides of an AnchorPane so that when I resize the screen, the scroll also resizes. So I do not need to specify a fixed size. That's how it works. The problem is that in this way the methods getPrefWidth...
asked by 20.07.2018 / 03:14
1
answer

Focus event in fxml

In the fxml file of a GUI we can direct the code to a method when a particular event occurs. For action events, it would be something like this: <Button fx:id="btn1" onAction="#actionPause" /> But as to whether the object has been foc...
asked by 18.07.2017 / 06:54
1
answer

Failed to customize the javafx tab, the top edge of the panel does not appear

I would like the TabPanel area that does not have a tab to have a border as the image below. Currently my TabPanel is like this, no border to the right of "Enter" Iwouldlikeittolooklikethis,butIdonotknowwheretoputinstructionfromtheborder,...
asked by 12.08.2017 / 13:14
1
answer

Page JavaFX

I was playing with JavaFX and crashed when I wanted to add paging to my little application. I have listview filled (as can be seen in the image), when I click on an item, your information is shown on the right. Astheapplicationwasm...
asked by 22.11.2016 / 23:33
1
answer

Change Icon JavaFx

I'm trying to change the icon but I'm not getting it. Code: package olamundojavafx; import com.sun.javafx.scene.SceneHelper; import javafx.application.Application; import javafx.fxml.FXMLLoader; import javafx.scene.Parent; import javafx.sc...
asked by 28.01.2018 / 19:29
0
answers

Error Calling Java Fx Screens in Spring

I'm developing a Spring + Java Fx application, when calling the code from the main class screen, it works normally, but if I call another screen, it does not write the information in the model and gives null pointer exception, how I managed the...
asked by 08.10.2018 / 22:53
0
answers

How to call another screen via MenuItem

I'm trying to call another screen (include) through a MenuItem, but it's not working. At first, I can call my Login screen through Main.java, then I can also log in and call the Menu screen with a button. I think the MenuItem method is dif...
asked by 26.02.2018 / 17:44
1
answer

Update label in loop

How do I update a label in a loop on the FXMLDocumentController ? The labels only update after the entire loop is finished and then plays the last information on the screen; package musicaisfx; import java.awt.Font; import java.awt.even...
asked by 30.05.2017 / 07:53
2
answers

ImageView inside HBox in FXML file

I'm trying to insert an image inside a HBox through a ImageView but I'm not getting it. fxml code: <?xml version="1.0" encoding="UTF-8"?> <?import java.lang.*?> <?import java.util.*?> <?import javafx.scen...
asked by 17.07.2017 / 03:43
1
answer

How to create a "new file" .txt in java?

My questions are: is this code correct? how do I clear the screen and open the new created file? menuNovo.setOnAction((ActionEvent e) -> { Stage janela = (Stage) areaTexto.getScene().getWindow(); String nome = JOptio...
asked by 02.07.2017 / 22:53