This commit is contained in:
Norayr Chilingarian 2014-02-03 20:31:37 +04:00
parent c72709c86e
commit 0571cd7841
32 changed files with 0 additions and 0 deletions

34
src/test/gtk/handlers.Mod Normal file
View file

@ -0,0 +1,34 @@
(***************************************************************************
Project: HelloWorld
Purpose: A libglade-Hello-World with oo2c
Version: 1.0
Predecessor: -
Changes: -
Target: Linux
Compiler: oo2c
Date: Jan. 2009
Author: Frank Hrebabetzky
***************************************************************************)
MODULE handlers;
IMPORT
SYSTEM, Out := Console, G, Gdk, Gtk;
PROCEDURE (*["Hello"]*) Hello* (widget:Gtk.WidgetPtr; data:SYSTEM.PTR);
BEGIN
Out.String("Hello, world!"); Out.Ln;
END Hello;
PROCEDURE (*["Draw"]*) Draw* (widget:Gtk.WidgetPtr;
event:Gdk.EventExposePtr; data:G.pointer): G.boolean;
VAR a: G.int;
BEGIN
a:= widget.allocation.width DIV 2;
Gdk.drawArc (widget.window, widget.style.fgGc[ORD(widget.state)], G.TRUE,
a DIV 2, a DIV 2, a, a, 0, 64*360);
RETURN G.TRUE;
END Draw;
END handlers.