I have an AncharPane in which all components are placed/designed using Fxml but the problem is, when the frame resize all components are stick with its current position.
Tag: javafx
how to add an object in java lang to the fxml file
im trying to make a game I have made a grid of cells in a java class and another part of the UI in the fxml file but when I run it ide gives: JavaFX Application Thread” java.lang.RuntimeException: …
JavaFX: TextFields displayed from array, array updated / increased on button click – how to force the scene to redraw the updated array
I have a program that displays animals and their names: The method associated with Add animal button: The code inside addAnimals does execute, but the new text field doesn’t appear. How should I fix it? Answer You forgot to add the text fields to grid, just creating a textfield doesn’t show it you need to add it to your like
JavaFX – move projectiles
First of all, this is my very first post here. Hello everyone! I am a beginner in Java/JavaFX. Currently I wrote some simple “game” to learn some basic stuff in game development, doing that just for fun right now. So far I get a player which moves to the left/right (movement is unrestricted, but never mind that now) and fires
JavaFX: How to make a VBox and it’s contents expand infinitely with window height like they do with width?
Probably a very simple question but I have not been able to figure it out. I have a ScrollPane (feat. Label) inside a VBox, inside a SplitPane: (Full fxml file at the bottom) When you expand the window or the split pane seperator horizontally, the Vbox automatically stretches to fit, the label re-centers appropriatelly, and the scroll pane expands to
Can’t access controller and its methods from another controller
I’m not 100% sure how to best describe this issue but I will try my best. I am developing a music application and have different windows within one and have loaded panes into a little in app window shown below: The bit that changes from a green button to the playlist screen is the window that has FXML files loaded
Display output of two different Threads in two separate JavaFx TextArea’s
Hello guys so i have to make two threads that sell train tickets simultaneously and display there output on two different windows, i have create a class that generates the tickets and a Runnable but i am not sure how to display the output of the two different threads in the two different Text area boxes i have tried to
Can’t make changes to interface in a runnable with JavaFX
In my program, I am running a separate script and I am using concurrency to run the separate script, and therefore using a class implementing Runnable. When the the separate thread is running, I want there to be a different graphic to when the thread is not running so the user can see if something is happening after pressing the
Get Current logged User Id and User Name using JavaFX
I’m trying to create an application using JavaFX. I want to get current logged userid and username, after successful login. I want to display it is in the home page. How can i do this? please help MediaController.java Answer Let me get this straight, you have the user login, then change the scene to a main window, but you want
Adding Spring Dependency Injection in JavaFX (JPA Repo, Service)
I have a java FX basic application which has a simple Scene(a form). I have a Mysql Db and I am using Spring JPA (spring data jpa i.e repository/entities) to interact with the same. Now, since we know that javaFx has some lifecycle hooks namely: init() start() and stop(). Let’s say I want to insert data in Database using JPA