javafx-8

Pane Shape Modification

[亡魂溺海] 提交于 2019-12-08 03:30:47
问题 Ok so to make a long story short I'm trying to create a sort of chat/message system and need a small bit of assistance. I'm trying to create an arrow on my container as the one shown in the image below. The image is taken off of ControlsFX and from their PopOver window. I CANNOT use their popover widget because it behaves a little wonky with what I'm using it for. I went ahead and created my own little chat window popup that positions itself over the parent object that I define but I would

how to paint peak map in javafx

好久不见. 提交于 2019-12-08 03:28:21
问题 I want to paint a peak map in javafx, but there isn't a class to finish my aim. So I modified "LineChart" to be my "peak map", it looks that. But I want to move X axis to 0 scale(y axis), what can I do to achieve it. By the way, if you have a better method to achieve "peak map", please give me some advices. Thanks! public void start(Stage stage) { stage.setTitle("Line Chart Sample"); final NumberAxis xAxis = new NumberAxis(); final NumberAxis yAxis = new NumberAxis(); xAxis.setLabel("X");

Display VlcJ in JavaFX using SwingNode

只谈情不闲聊 提交于 2019-12-08 03:24:17
问题 FXMLController initialize method: @FXML private VBox vbContainer; MediaPlayerVLC m_mediaPlayer; public void initialize(URL url, ResourceBundle rb) { final SwingNode swingNode = new SwingNode(); m_mediaPlayer = new MediaPlayerVLC(); createAndSetSwingContent(swingNode, m_mediaPlayer); vbContainer.getChildren().add(0, swingNode); } And createAndSetSwingContent(): private void createAndSetSwingContent(final SwingNode swingNode, JComponent jComponent) { SwingUtilities.invokeLater(new Runnable() {

How to retrieve the final Slider value when snapToTicks==true?

↘锁芯ラ 提交于 2019-12-08 03:08:12
问题 I have the following JavaFX scene (note the setting of snapToTicks ): package com.example.javafx; import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.control.Slider; import javafx.stage.Stage; public class SliderExample extends Application { public static void main(String[] args) { launch(args); } @Override public void start(Stage primaryStage) { Slider slider = new Slider(0.25, 2.0, 1.0); slider.setShowTickLabels(true); slider.setShowTickMarks(true); slider

Customize ControlsFX Notifications

一曲冷凌霜 提交于 2019-12-08 02:36:12
问题 I want to use ControlsFX Notifications class, as JavaFX seems to doesn't offer anything like it (or does it?). For me to use it I want to be able to customize the color of the notification and some other styles. Does anybody have an idea of how I can do that? Edit: Through setting Notifications.owner(...) the notification is styled the same way as my main application, but it is then shown within the main application as well and not at the bottom right corner of my screen. 回答1: Notifications

JavaFX 3-D Bar chart with Java 8

孤者浪人 提交于 2019-12-08 02:20:46
问题 Is there any example of 3-D Bar chart for the latest Java 8 which uses the modern 3-D API? I would like to use the 3-D API from Java 8. 回答1: Refer to this example, it shows use of 3-D bar chart if it helps you. http://www.jroller.com/dgilbert/entry/creating_3d_charts_in_java 回答2: There was a 3d-Bar-Chart demo in the earlier versions of JavaFX, but that was removed. You can create a bar chart yourself. Just create a grid and some boxes on it. Here's a slight modification of the answer in How

JavaFX BooleanProperty and Hibernate

别等时光非礼了梦想. 提交于 2019-12-08 02:04:26
问题 I'm trying to add JavaFX BooleanPropety to my model which is persisted by Hibernate but I'm getting the following error. Caused by: org.hibernate.MappingException: Could not determine type for: javafx.beans.property.BooleanProperty. JavaFX StringProperty persisting just fine so I'm confused a little bit. My model class is the following @Entity public class Currency { private String uuid; private BooleanProperty isDefault = new SimpleBooleanProperty(); private StringProperty name = new

Creating a control seems to break transparent stages on JFX8

有些话、适合烂在心里 提交于 2019-12-07 21:34:03
问题 The above program should create a transparent stage with some text, but the stage appears opaque: public class Test extends Application { @Override public void start(Stage primaryStage) { new TextArea(); //Comment this out to enable transparency Stage stage = new Stage(); stage.initStyle(StageStyle.TRANSPARENT); Text text = new Text("Is this transparent?"); VBox box = new VBox(); box.getChildren().add(text); final Scene scene = new Scene(box, 300, 250); scene.setFill(null); stage.setScene

Equivalent to JGraph for JavaFX8?

独自空忆成欢 提交于 2019-12-07 20:41:48
问题 I want to port an old swing tool which uses an also old version of JGraph to JavaFX8. However, since JGraph is a Swing-Based library, is thought about replacing it, too. So, is there something equivalent to JGraph, but working with JavaFX8? 回答1: So, is there something equivalent to JGraph, but working with JavaFX8? Following Jonathan Giles Blog, I can't remember having read anything about a JavaFX based graph library yet -> so, most likely, no But you should be able to use Swing controls in

How to reload an Application in JavaFX?

三世轮回 提交于 2019-12-07 18:05:18
问题 I have a small game which has New Game button. There are many variables which need reset when the New Game button is pressed. Is there any method which can easily reload the whole application or any alternative to refresh the scene, stage or variables? I just want to bring the application to it's initial stage when It's first loaded. I went through different topics on internet and read many questions and answers here also, but I there is no easy method to implement it. Most of the answers