Questions tagged [scalafx]

ScalaFX is a Scala user interface (UI) domain-specific language (DSL) built on top of JavaFX. This means that every ScalaFX application is also a valid Scala application. By extension it supports full interoperability with Java and can run anywhere the Java Virtual Machine (JVM) and JavaFX are supported.

ScalaFX is a Scala user interface (UI) domain-specific language (DSL) built on top of JavaFX. This means that every ScalaFX application is also a valid Scala application. By extension it supports full interoperability with Java and can run anywhere the Java Virtual Machine (JVM) and JavaFX are supported.

214 questions
0
votes
1 answer

ScalaFX and Akka (View message Actor)

Taking from Mucaho's Scalatrix example I'd like to send messages from the View (ScalaFX) to the controller actor, how can I abstract/expose the actor to be able to do this? object Ops extends App { override def main(args: Array[String]): Unit…
0
votes
1 answer

ScalaFx Bind ImageView to custom Enumeration

I just started to write scalafx application and have a question about bindings. I have an Enumeration with connection status in my presenter class and I want to select appropriate icon in label in view class. I basically can create binding in javafx…
rtgbnm
  • 33
  • 6
0
votes
1 answer

Pass data to a ScalaFX JFXApp

I wrote a GUI in ScalaFX whichs works quite well when testing it isolated. Things to mention: The "real" application itself already has a main method, and only that one should be used to start the application, not the one I get when extending…
ceran
  • 1,392
  • 1
  • 17
  • 43
0
votes
0 answers

Is it possible to veto user row selection in a JavaFX TableView?

The user might click with the mouse on a different TableView row or use the up/down arrow keys to go to a different row. However the current row may be 'invalid' and I want to effectively stop the row change happening. I'm looking for a 'validate'…
Chris Murphy
  • 6,411
  • 1
  • 24
  • 42
0
votes
0 answers

ScalaFX Window always on top of other windows

I am currently implementing an ScalaFX application which needs to get on top of all other (non related applications, arbitrary OS windows) windows when a specific event occurs. I searched the Internet and found some answers which are kind of a hack…
smoes
  • 591
  • 2
  • 17
0
votes
1 answer

ClassNotFoundException: HelloStageDemo

The code I'm running is from the homepage of http://www.scalafx.org. There are no compiler warnings but when it runs I get the exception. I first tried using jdk 1.7 with Scala 2.11 and ScalaFX 2.9.3-2.2.67 and got the equivalent error. I still get…
Bob Hoeppner
  • 95
  • 3
  • 9
0
votes
1 answer

Get text values from HBox

Say I have an HBox like this: val texts = new HBox { content = Seq(new TextArea, new TextArea) } Now I'd like to get TextAreas' text values in a collection. How can I get to these TextAreas? texts.content is an…
src091
  • 2,807
  • 7
  • 44
  • 74
0
votes
1 answer

Exception during macro expansion with sbt-native-packager and ScalaFXML

I have a small project on github that I created to explore ScalaFx and a few other things I want to use on a bigger project. For now, it includes a single sub-project, which is a simple calculator written using ScalaFX and ScalaFXML. The project…
Cyäegha
  • 4,191
  • 2
  • 20
  • 36
0
votes
0 answers

How to access an FXML-defined element from a dynamically created element event handler in ScalaFX?

I am trying to write an event handler for a dynamically created button in a FXML-defined form controller and it seems to work ok but as soon as I try accessing another element it fails. For example this code works fine: import java.util import…
Ivan
  • 63,011
  • 101
  • 250
  • 382
0
votes
2 answers

Different errors during 'sbt' and 'sbt run' in scalafx-ensemble

I downloaded the scalafx-ensemble project. When I run sbt in the project's folder I'm facing the following error: [info] Set current project to scalafxEnsemble (in build file:/C:/dev/sample/scalafx-ensemble-master/) [ERROR] Terminal initialization…
falcon
  • 372
  • 3
  • 19
0
votes
1 answer

Type mismatch error upon compiling project with ScalaFX in SBT

I'm developing a project with ScalaFX and MySQL database. SBT successfully added MySQL connector via build.sbt file. When it compiles the project, it stops with a type mismatch error: [error] found : com.aitrich.scalafx.test.DbConnection.type…
jijesh Aj
  • 614
  • 4
  • 10
  • 25
0
votes
0 answers

How to play the drop failed animation in ScalaFX/JavaFX 2?

In ScalaFX if I drop a TreeCell onto a control other than the containing TreeView then a short animation is played showing the dragged item returning to its original position. The same happens if I drop the TreeCell outside of the application - e.g.…
richj
  • 7,499
  • 3
  • 32
  • 50
0
votes
1 answer

How do I solve drawing XOR artefact problems in ScalaFX/JavaFX with BlendMode.Difference?

I'm porting some code from Java to Scala and having problems with drawing artefacts when attempting "rubber banding" - i.e. drawing a rectangle that moves with the mouse pointer. This was relatively simple to do in Java2D, but I'm having problems…
richj
  • 7,499
  • 3
  • 32
  • 50
-1
votes
1 answer

How to fix this code? Enable the java parseDouble in scalafx program

I am a new learner of scala and I am coding a simple scalafx calculator and now I face a problem. I cannot find another suitable code to replace the parseDouble. I know the parseDouble is the member of java double, not scala double. I just put the…
kxaio1117
  • 11
  • 2
-1
votes
1 answer

How do I run a basic ScalaFX application?

I'm trying to run a simple ScalaFX program that displays a window with nothing on it. I can run the program as a script file with the desired result, but the moment I add a main object to the program it still runs but doesn't produce a window. I…
1 2 3
14
15