Improve demos for better screenshots, cleanup

This commit is contained in:
Abe Pazos
2020-05-20 14:08:31 +02:00
committed by Edwin Jakobs
parent d52875769e
commit 677f821ca8
10 changed files with 61 additions and 35 deletions

View File

@@ -15,6 +15,13 @@ fun main() = application {
}
program {
// -- this block is for automation purposes only
if (System.getProperty("takeScreenshot") == "true") {
extend(SingleScreenshot()) {
this.outputFile = System.getProperty("screenshotPath")
}
}
val rabbit = RabbitControlServer()
val font= loadFont("orx-rabbit-control/src/demo/resources/fonts/Roboto-Regular.ttf", 20.0)
val settings = object {
@@ -49,11 +56,6 @@ fun main() = application {
}
rabbit.add(settings)
if (System.getProperty("takeScreenshot") == "true") {
extend(SingleScreenshot()) {
this.outputFile = System.getProperty("screenshotPath")
}
}
extend(rabbit)
extend {
drawer.clear(if (settings.b) ColorRGBa.BLUE else ColorRGBa.BLACK)

View File

@@ -12,6 +12,13 @@ fun main() = application {
}
program {
// -- this block is for automation purposes only
if (System.getProperty("takeScreenshot") == "true") {
extend(SingleScreenshot()) {
this.outputFile = System.getProperty("screenshotPath")
}
}
val rabbit = RabbitControlServer(showQRUntilClientConnects = false)
val settings = object {
@@ -20,11 +27,6 @@ fun main() = application {
}
rabbit.add(settings)
if (System.getProperty("takeScreenshot") == "true") {
extend(SingleScreenshot()) {
this.outputFile = System.getProperty("screenshotPath")
}
}
extend(rabbit)
/**