Tooltips in Layout in ScrolledWindow
- From: Tomi <nappii gmail com>
- To: gtkmm-list gnome org
- Subject: Tooltips in Layout in ScrolledWindow
- Date: Sun, 16 Nov 2008 12:58:00 +0200
Hi,
I am trying to draw points of data using a custom PlotArea class that
inherits Gtk::Layout and Cairo::Context. I have placed it inside a
Gtk::ScrolledWindow so that I can scroll when the PlotArea's size (set
with Gtk::Layout's set_size() ) is bigger than the visible area. This
I have been able to do with no problems.
However, I also want to show tooltips when the mouse cursor is on top
of a data point. I have been unable to achieve this because of the
scroll capability as the rectangle coordinates used for a tooltip seem
to be counted from the corner of the widget no matter which part of it
is visible. Is there a way to determine the corner of the visible area
when the Layout is inside a ScrolledWindow, for example, so that I
could figure out where the tooltips are supposed to be? Or is there an
another approach that I could use? I only need to be able to show
different coloured points with tooltips and be able to zoom and scroll
the area?
Thanks beforehand,
Tomi
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]