Precision cursor for histogram manipulation

Hi all,
attached to this post you will find a small macro (just an idea) that allows a “precision” modification of some histogram data using the keyboard.
From my point of view the weak point of this macro (apart from some optimizations :wink: ) is the “gPad->Update()” line: this call can slow down cursor movement a lot, expecially if you have a slow machine or many histograms (try to keep left or right arrows pressed…).
I was just wondering if there is a better method to do the job (maybe using XOR drawing or similar): any ideas?

Thank you
Luigi
test_precisioncursor.C (2.82 KB)

Have you tried usinf ACLiC ? … just a guess …

Hi,
I believe that the time consuming job is done by TPad::Update() (that is compiled): AFAIK this function redraws all the objects of the pad, and this is way too much for this case :unamused:
Just wondering if a different approach exists that avoids the use of the Update() methods, maybe using some “low level” calls like bitmap copy or XOR drawing…

Luigi