This repository has been archived by the owner on Oct 8, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
Home
Vladde Nordholm edited this page Jun 18, 2018
·
9 revisions
scone acts as a gateway to the console/terminal. Setting up a project with scone is easy! Take a look at the following example
import scone;
void main()
{
window.title("example");
window.resize(33, 20);
bool run = true;
while(run)
{
foreach(input; window.getInputs())
{
// if CTRL+C is pressed
if(input.key == SK.c && input.hasControlKey(SCK.ctrl))
{
run = false;
}
}
window.clear();
window.write
(
12, 9,
Color.yellow.fg, "Hello ",
Color.red.fg, Color.white.bg, "World"
);
window.print();
}
}