javafx

How to perform big numbers on axis (for example, 10^3 format) in chart?

℡╲_俬逩灬. 提交于 2019-12-25 17:36:36
问题 Using a big space performing long numbers is not a good decision. If I have a graph with a medium scale about 50 000, on the Y axis will be written "50 000, 60 000, 10 000". Can I perform it there like 50 * 10^3 or something else? It's necessary for charts with several scales like here 回答1: Use a tickLabelFormatter on the axis. For example: NumberFormat format = new DecimalFormat("#.#E0"); yAxis.setTickLabelFormatter(new StringConverter<Number>() { @Override public String toString(Number

Javafx TabPane with StackPane and custom Controls

拥有回忆 提交于 2019-12-25 17:26:06
问题 I'm developing an app in JAVAFX. Mainly, the app is using a TabPane controller. In the first tab, i'm loading a controller for a StackPane . In the StackPane i'm loading as a default, one list view with custom cells. In each cell i'm having some buttons. I want to add a new pane in the stack pane and bring it to front when a button is clicked. I tried with the toFront() and toBack() but i can't get anything working. I've check, and both panes are loaded and their content is the right one. I

Jar file does not execute with DB connection

情到浓时终转凉″ 提交于 2019-12-25 17:01:34
问题 I'm building a project with Derby DB It works just fine when I run it in Netbeans and also as jar file when I use DB as Network Client with derbyclient.jar . But the problem is I have to distribute it so I use Embedded mode of Derby DB , As I provide derby.jar . And followed the instructions Provided Here. The only deference between Embedded & Network is we have to use this DB path (short DB name path) dbPath = "jdbc:derby:Mail_Client_Ref_Fiverr"; Instead of (full with localhost and port)

Jar file does not execute with DB connection

醉酒当歌 提交于 2019-12-25 17:01:27
问题 I'm building a project with Derby DB It works just fine when I run it in Netbeans and also as jar file when I use DB as Network Client with derbyclient.jar . But the problem is I have to distribute it so I use Embedded mode of Derby DB , As I provide derby.jar . And followed the instructions Provided Here. The only deference between Embedded & Network is we have to use this DB path (short DB name path) dbPath = "jdbc:derby:Mail_Client_Ref_Fiverr"; Instead of (full with localhost and port)

How to control the JavaFX TextArea auto scroll?

二次信任 提交于 2019-12-25 16:46:24
问题 In my application I am appending the text to TextArea every 2 minutes. When ever I append new line to TextArea the auto scroll automatically going to down. But I want to stay the scroll where i am keep the scroll button. How to do it in JavaFX. logTextArea.appendText("Here i am appending text to text area"+"\n"); logTextArea.setScrollTop(Double.MIN_VALUE); I tried this but scroll automatically going to down , but I need to keep my scroll chosen position I don't want to go automatically down.

JavaFX: how to keep the XYChart ticks constant

99封情书 提交于 2019-12-25 16:42:31
问题 I have a XYChart whose ticks unit is set to 25 for X axis. The chart has a sliding functionality. Each time I slide left or right, I want the ticks to stay constant. So far, I have 10 or 11 ticks, set at 25 distance one to another, and they change their values -- I want that constant. For example: lowerBound = 480 upperBound = 600 Ticks: 480, 505, 530, 555, 580, 600. I slide right: I still want to see 480, 505, 530, 555, 580, 600 at different positions though, and possible get rid of 480 and

Filtering JFX TableView with multiple values

别来无恙 提交于 2019-12-25 16:08:38
问题 I am currently trying to filter data in my TableView using FilteredList with predicate . I have 2 ComboBoxes to filter the values. My table contains Result . Each Result has a Student , that Student has a Classroom he belongs in. Those are the values I want to filter them by. I have no issues when I filter data using only 1 ComboBox . However, I don't know how to filter it based on both at the same time. The only real solution I could come up with would be a lot of if statements in both

Combine chart data if category name is the same - JavaFX

≯℡__Kan透↙ 提交于 2019-12-25 16:03:20
问题 I have an observable list of chart data which is created automatically. Is there any way to automatically combine the data which has the same category name in to one category? The reason I need this is since the observable list of data is created directly form a table in a SQL database, I can not know if the user actually wants to show a combined view or each category and value separately in the chart. Say I have the following data: Instead of Bordeau-1 appearing this many times, I want all

Combine chart data if category name is the same - JavaFX

一个人想着一个人 提交于 2019-12-25 16:00:15
问题 I have an observable list of chart data which is created automatically. Is there any way to automatically combine the data which has the same category name in to one category? The reason I need this is since the observable list of data is created directly form a table in a SQL database, I can not know if the user actually wants to show a combined view or each category and value separately in the chart. Say I have the following data: Instead of Bordeau-1 appearing this many times, I want all

How To Convert JSON to Java object, and vise-versa

早过忘川 提交于 2019-12-25 14:12:05
问题 I would like to populate my FullCalendar, which I have drawn on a webview, with data/ event dates stored in a database. I know that I'll have to do this via JSON. The problem is that practically all documentation I've come accross online only stop at "How To Convert JSON to Java object", and vise-versa. How about making the converted JSON/ Java object visible in the HTML/ Java class? For example, say I have a List of event/ appointment objects retrieved from a database. List<FullCalendarData>