vala test + some build environment
This commit is contained in:
parent
bd86bab978
commit
29cfcd5e7a
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
target/*
|
@ -4,4 +4,4 @@ A free touch screen note taking application. Support for Linux. If this project
|
||||
|
||||
We try to provide a similarly great user experience as stylus write does, but improving the user interface and keeping the project FOSS.
|
||||
|
||||
Though the required features are notetaking and touch gestures, annotating PDFs and other features are planned.
|
||||
Though the required features are notetaking and touch gestures, annotating PDFs and other features are planned.
|
||||
|
3
build.sh
Normal file
3
build.sh
Normal file
@ -0,0 +1,3 @@
|
||||
#!/usr/bin/sh
|
||||
COMMIT=$(git rev-parse HEAD | head --bytes 8)
|
||||
valac --pkg gtk+-3.0 --output target/${COMMIT}_scribble src/scribble.vala
|
27
src/scribble.vala
Normal file
27
src/scribble.vala
Normal file
@ -0,0 +1,27 @@
|
||||
using Gtk;
|
||||
|
||||
int main (string[] args) {
|
||||
Gtk.init (ref args);
|
||||
|
||||
var window = new Window ();
|
||||
window.title = "First GTK+ Program";
|
||||
window.border_width = 10;
|
||||
window.window_position = WindowPosition.CENTER;
|
||||
window.set_default_size (350, 70);
|
||||
window.destroy.connect (Gtk.main_quit);
|
||||
|
||||
var button = new Button.with_label ("Click me!");
|
||||
|
||||
var stylus = new GestureStylus (window);
|
||||
stylus.proximity.connect(callback_a);
|
||||
|
||||
window.add (button);
|
||||
window.show_all ();
|
||||
|
||||
Gtk.main ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
void callback_a () {
|
||||
stdout.printf ("Callback A\n");
|
||||
}
|
Loading…
Reference in New Issue
Block a user