GUI component interaction: Difference between revisions

Updated to compile with Nim 1.4.
(Updated to compile with Nim 1.4.)
Line 2,195:
{{libheader|Gtk2}}
<lang nim>import
gtk2, gdk2, glib2, strutils, mathrandom
 
import
gtk2, gdk2, glib2, strutils, math
var valu: int = 0
Line 2,244 ⟶ 2,241:
proc thisRnd(widget: PWidget, data: Pgpointer){.cdecl.} =
if on_question_clicked():
valu = randomrand(20)
entry_fld.set_text($valu)
Anonymous user