[Ardour-Dev] Clicking on the canvas

John Emmas johne53 at tiscali.co.uk
Wed Apr 28 07:11:56 PDT 2010


----- Original Message ----- 
From: "Carl Hetherington"
>>
>> On Mon, 26 Apr 2010, John Emmas wrote:
>>
>> Do you happen to know which function displays the yellow digits (or
>> even which function starts the process off)?  I can probably trace my way
>> through to the display function if I can find any of the other functions
>> in that chain.
>
> It's shown with Editor::show_verbose_canvas_cursor ().
>
Thanks Carl.  I also discovered that the actual text gets set in
Editor::set_verbose_canvas_cursor().  I added an extra line to
show_verbose_canvas_cursor() so that it now looks like this:-

void
Editor::show_verbose_canvas_cursor ()
{
                    verbose_canvas_cursor->raise_to_top();

/* My line */ Glib::ustring str =
(Glib::ustring)verbose_canvas_cursor->property_text();

                     verbose_canvas_cursor->show();
                     verbose_cursor_visible = true;
}

The extra line proved that the text was still valid at the time it's
about get shown - but all I actually see is a long string of zeros (or maybe
it's a long string of yellow squares - I can't be certain).  Either way, the
cursor text is correct but what gets displayed on screen is wrong.

Can anyone suggest a useful tutorial for someone who wants to find out
about libgnomecanvas?  Anything that has some simple example projects
would be great.

John




More information about the Ardour-Dev mailing list