comp.lang.ada
 help / color / mirror / Atom feed
* Problems with Glade 3, and Ada drawing
@ 2014-01-14  8:33 ldries46
  0 siblings, 0 replies; only message in thread
From: ldries46 @ 2014-01-14  8:33 UTC (permalink / raw)


I am trying to draw a grid on  Gtk_Drawing Area. I want that drawing to 
appear when then program starts before anything is done.
I can draw that grid  and see it but whenever the program redraws the window 
it disappears as a whole or in some cases partly. As various sources I found 
out that I have to act on the draw signal. As I build my GUI with Glade 3 I 
thought I could connect the drawing signal with:

Register_Handler
  (Builder      => Builder,
   Handler_Name => "On_Area_Draw", -- from XML file <signal handler=..>
   Handler      => Sudoku_Callbacks.On_Area_Draw'Access);

Where I coupled  "On_Area_Draw" in Glade with the draw signal in the 
Gtk_Drawing_Area. Although This was carried out case Sensitive the program 
aborted. The most likely reason therefor is that the handler procedure was:

procedure On_Area_Draw (Object : access Gtkada_Builder_Record'Class);

where it should have been

function On_Area_Draw (Object : access Gtkada_Builder_Record'Class; Context 
: Cairo.Cairo_Context) return boolean;

Using the last results in aborting the compilation.

The question now is how should I connect the draw signal to which 
function/procedure to get a correct working program?

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-01-14  8:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-14  8:33 Problems with Glade 3, and Ada drawing ldries46

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox