Download and Setup
A natural pre-requisite for Scalqa is the installed Scala 3.1.0 or above. If in doubt, take a look at project Samples, which is SBT configured for Scalqa.
Download
SBT users should add following library dependency:
libraryDependencies += "org.scalqa" % "scalqa_3" % "1.0"
Everyone else can download single JAR file from the latest release.
Note. If GUI is to be used on JDK11 and above, the javaFx has to be provided manually. Take a look at "samplesFx" configuration.
Simple Use
In basic case Scalqa root must always be imported into each program unit. This sounds a lot, but this is the only import to be done. Implicit conversions also must be enabled.
package Foo; import scalqa.{*, given}; import language.implicitConversions
Note. It is suggested to use single line (as above) for package and static definitions, which will repeat in each program.
Project Use
It is possible to set up a project specific Scalqa root, which will be shared by all program units.
To do so, copy the "fx" package root content of SamplesFx project into your root package.
Note, other program units (like Lines, Sorting, etc.) do not need to import Scalqa anymore, but the "fx" package definition must be accessible:
package example.fx; package chart // package 'fx' is accessible
// vs.
package example.fx.chart // Not accessible
Note. import language.implicitConversions
is still required in each file, unless implicits are enabled on configuration level.