javafx-8

JavaFX Running a large amount of countdown timers at once?

牧云@^-^@ 提交于 2020-06-23 17:31:47
问题 So I can see a couple different ways to do what I need and I've done a bunch of google/stack overflow searching but can't find really what I'm looking for. I need to run multiple "Countdown timers." I need to have about 6 possibly up to 10 countdown timers running at once all at different times. I have a tab pane on my main program that I am including the FXML and injecting the controllers into. The Timers Tab has a different controller than the main program. So the 1st question I have is.

How to drag a JavaFX node and detect a drop event outside the JavaFX Windows?

自闭症网瘾萝莉.ら 提交于 2020-06-13 05:44:05
问题 I'm implementing a TabPane that can be detached from the JavaFX window. When the tab pane is dragged outside of the window where it came from, I would like a new window to be created and the tab to be placed in that window. I already implemented some methods using drag gestures to drag the tab between existing windows. However, I am not able to receive any mouse events or drag events when the mouse is moved outside of JavaFX scenes. Is this something possible? 回答1: You can listen for a mouse

-fx-background-radius and -fx-background-insets in JavaFX

早过忘川 提交于 2020-06-11 11:18:10
问题 I am working with JavaFX and I want to customize a button. I saw several characteristics that can be styled. Among them I found two that are unknown to me. .button { -fx-padding: 5 22 5 22; -fx-border-color: #121212; -fx-border-width: 2; -fx-border-radius: 5; -fx-background-radius: 0; -fx-background-color: #555555; -fx-font-family: "Segoe UI", Helvetica, Arial, sans-serif; -fx-font-size: 11pt; -fx-text-fill: #d8d8d8; -fx-background-insets: 0 0 0 0, 0, 1, 2; } what are these two properties:

How can i get the data which has been generated using load html feature of JavaFx WebView?

百般思念 提交于 2020-05-31 06:17:11
问题 I have a JavaFx Application where I am loading the HTML page. The HTML generates a Base64 which is being written to a file once it is loaded using Javascript bridge. I am trying to get this Base64 data once it is written from the main class. Can anyone please let me know how can i achieve it ? Below is the code Test.java public class Test { public static void main(String[] args) throws InterruptedException { String input = "[{'name': 'sub','description': 'sub','length': 25,'diameter': {'outer

Install openJDK+openJFX 8 on Ubuntu 20

允我心安 提交于 2020-05-16 22:38:31
问题 I'm trying to install OpenJDK 8 and OpenJFX 8 on Ubuntu 20.10. Installing openJFX 8 has always been a little tricky on Ubuntu, but I used to be able to do it using the tip from this SO answer: https://stackoverflow.com/a/56166582/2423283 That used to work fine (I think I was using Ubuntu 19.something), however it appears that recently 8u161-b12-1ubuntu2 was removed. For some more background information, I'm installing this via a docker file in an automated pipeline. Here are the relevant

Install openJDK+openJFX 8 on Ubuntu 20

爱⌒轻易说出口 提交于 2020-05-16 22:38:10
问题 I'm trying to install OpenJDK 8 and OpenJFX 8 on Ubuntu 20.10. Installing openJFX 8 has always been a little tricky on Ubuntu, but I used to be able to do it using the tip from this SO answer: https://stackoverflow.com/a/56166582/2423283 That used to work fine (I think I was using Ubuntu 19.something), however it appears that recently 8u161-b12-1ubuntu2 was removed. For some more background information, I'm installing this via a docker file in an automated pipeline. Here are the relevant

“Error: Could not find or load main class” JavaFX Terminal

一个人想着一个人 提交于 2020-05-15 02:34:47
问题 I'm using the following class from my JavaFX Tutorial: import javafx.application.Application; import javafx.stage.Stage; public class HelloFXApp extends Application { public static void main(String[] args) { // Launch the JavaFX application Application.launch(args); } @Override public void start(Stage stage) { stage.setTitle("Hello JavaFX Application"); stage.show(); } } I'm using Ubuntu and I have the correct path to my .java file in my Terminal.. When I type "javac HelloFXApp.java" it works

JavaFx: Export TableView to excel with name of columns

拈花ヽ惹草 提交于 2020-05-11 01:58:35
问题 I'm trying to export tableView to excel using Apache POI Every thing is well but I need export all my table not just items, I mean with columns names when I use this code: HSSFWorkbook workbook = new HSSFWorkbook(); HSSFSheet spreadsheet = workbook.createSheet("sample"); HSSFRow row = null; for (int i = 0; i < TousEmpSusp.getItems().size(); i++) { row = spreadsheet.createRow(i); for (int j = 0; j < TousEmpSusp.getColumns().size(); j++) { row.createCell(j).setCellValue(TousEmpSusp.getColumns()

JavaFx: Export TableView to excel with name of columns

白昼怎懂夜的黑 提交于 2020-05-11 01:55:48
问题 I'm trying to export tableView to excel using Apache POI Every thing is well but I need export all my table not just items, I mean with columns names when I use this code: HSSFWorkbook workbook = new HSSFWorkbook(); HSSFSheet spreadsheet = workbook.createSheet("sample"); HSSFRow row = null; for (int i = 0; i < TousEmpSusp.getItems().size(); i++) { row = spreadsheet.createRow(i); for (int j = 0; j < TousEmpSusp.getColumns().size(); j++) { row.createCell(j).setCellValue(TousEmpSusp.getColumns()

How to create tabs with icons in JavaFX

亡梦爱人 提交于 2020-05-09 19:43:18
问题 I want to create tabs panel with icons similar to the Firefox configuration panel with JavaFX: Is there any example which I can use to see how to implement this? 回答1: Tabs, like many other elements in JavaFX, have a method called setGraphic(Node value) , in which you can put any JavaFX node. Example: import javafx.application.Application; import javafx.geometry.Pos; import javafx.scene.Group; import javafx.scene.Scene; import javafx.scene.control.Label; import javafx.scene.control.Tab; import