Re: ContextMenus

From: Rene Brun <brun_at_pcroot.cern.ch>
Date: Mon, 27 Jun 2005 13:46:51 +0200 (MEST)


Hi Otto,

    Int_t px = gPad->GetEventX();
    Int_t py = gPad->GetEventY();

see example in TGraph::InsertPoint
http://root.cern.ch/root/htmldoc/src/TGraph.cxx.html#TGraph:InsertPoint

Rene Brun

On
Mon, 27 Jun 2005, Otto Schaile wrote:

> Dear Rooters,
> I have:
> class ControlGraph : public TGraph ...
> ..
> public:
> SetFactor(Int_t point_number, Float_t factor); // *MENU*
>
> If a point on the graph is clicked with the right mouse
> the menu pops up with "SetFactor" being in the list.
>
> Now my question:
> Is there a way to find out (in SetFactor) which point is
> clicked or as an alternative px, py of the point?
>
> Cheers
> Otto
>
>
>
Received on Mon Jun 27 2005 - 13:46:55 MEST

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:09 MET