javafx-2

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

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 - XYChart with Axis Hidden

故事扮演 提交于 2019-12-25 16:44:58
问题 Is it possible to make an XYChart that has its axis hidden? Ideally removed. From looking at source it seems that it must have one due to the limitation that XYChart does not check for null Axis when layoutChartChildren() is called, which is a shame since XYChart provides for multiple data series and the addition of data in a series. IMO a separation of concern from the Axis. Any thoughts on a solution? 回答1: After you have shown a stage displaying the chart, call: for (Node n: chart.lookupAll

JavaFX: How to add serveral series dynimically on Area Chart and delete line(series) from chart?

会有一股神秘感。 提交于 2019-12-25 13:08:48
问题 I am working with Area Chart of JavaFX. I want to add series dynamically after user will enter values in text fields and press Add button. I also want to add delete and undo functionality in it. Delete functionality working would be like for instance if there are several lines on the Area Chart each line represents series, user can delete any line he want by clicking on that line and after clicking on delete button. I also want to add undo functionality so user can undo his actions. The

How to change values in tableview simultaneously whenever i select an corresponding item from comboboxtablecell

孤人 提交于 2019-12-25 07:51:56
问题 I tried but I got stuck at a point where am getting the corresponding values of the selected item from comboboxtablecell but cannot add the values to the corresponding column in the table view Controller.java public class controller { GetConnection gc = new GetConnection(); PreparedStatement pst; ResultSet rs; Statement st; private ObservableList<Users> datas = FXCollections.observableArrayList(); public controller(){} @FXML private TableView<Users> table; @FXML private TableColumn<Users

Is there any SimpleLOngProperty in javafx if not then what to do?

丶灬走出姿态 提交于 2019-12-25 07:29:21
问题 I am working with javafx2.2 . I am creating a table using tableview , my data is of different type. int,string,float,double have SimpleIntegerProperty , SimpleFloatProperty , SimpleDoubleProperty , SimpleStringproperty But what to do for long , char , TimeStamp and float sequence. I need to use these because of sorting performance see this Thank You 回答1: You can just create ObjectProperty like that ObjectProperty<Float> floatObjectProperty = new SimpleObjectProperty<Float>(); ObjectProperty

fxml file not behaving as expected in OS X

扶醉桌前 提交于 2019-12-25 06:47:52
问题 I am using an fxml file to to create my java fx UI. the file is:- <?import java.lang.String?> <?import javafx.collections.FXCollections?> <?import javafx.geometry.Insets?> <?import javafx.scene.control.Button?> <?import javafx.scene.control.ComboBox?> <?import javafx.scene.control.Label?> <?import javafx.scene.control.TableColumn?> <?import javafx.scene.control.TableView?> <?import javafx.scene.layout.AnchorPane?> <?import javafx.scene.layout.ColumnConstraints?> <?import javafx.scene.layout

Why JavaFX WebView failed to load [Status : FAILED]

那年仲夏 提交于 2019-12-25 06:33:14
问题 Im really confused why WebView failed to load the following URL: http://docs.oracle.com/javafx/2/webview/jfxpub-webview.htm http://www.java2s.com/Code/Java/JavaFX/WebEngineLoadListener.htm After running my code WebEngine's State returns FAILED . But when I tried to run this URL : https://www.google.com.ph/, WebEngine's State returns SUCCEEDED , and it loaded SUCCESSFULLY! WHY ???? Is there some kind of CONFIGURATION that I needed to set in order for those sites to load successfully? Here's

Are there any pre-made skins for JavaFX2?

房东的猫 提交于 2019-12-25 06:32:10
问题 From what I'm reading it's possible to write JavaFX2 skins via CSS. But I can't seem to find any complete examples of this, a few tutorials here and there, but that's it. Specifically I'm looking for a "dark" skin for JavaFX2. Any ideas of where to find pre-made skins? 回答1: If you read modena.css you'll see an explanation where colors values are derived from * -fx-text-base-color for text on top of -fx-base, -fx-color, and -fx-body-color * -fx-text-background-color for text on top of -fx

JavaFX Adding Rows to TableView on Different Page

僤鯓⒐⒋嵵緔 提交于 2019-12-25 06:09:36
问题 Okay, I've been working through some issues with this program and I think I've finally gotten it to a point where I understand what is wrong. I'm trying to follow this tutorial a bit: http://docs.oracle.com/javafx/2/fxml_get_started/fxml_tutorial_intermediate.htm But my program has the add a row on a different FXML page than the Table View is on. I think the program is having trouble connecting the two. I've looked in to trying to find ways to make them talk to each other (put everything in