[ROOT] GUI classes with TThread

From: LEE, KERRY T. (JSC-SR) (UHCL) (kerry.t.lee1@jsc.nasa.gov)
Date: Fri Jan 16 2004 - 23:46:22 MET


Dear ROOTers,

I am attempting to create an online histogram monitoring GUI, in which many
histograms are filled , but only displaying a few at a time.  I currently
have a TListBox containing a list that selects which histograms are to be
displayed, and a TROOTEnbededCanvas to display the histograms in.  This
worked perfectly as long as the histograms were finished being filled (after
my simulated online run).  While the run was in progress I could not
interact with the GUI and change the histogram display.  My next step was to
introduce TThreads via the TThreadframe example.  Unfortunately I did this
before coming across the previous message

http://atlassw1.phy.bnl.gov/doc/root/RootHtmlDoc/roottalk/roottalk99/1619.ht
ml

which states that "Access to TCanvas, TPad and other graphics from threads.
Does not work, even if access is locked explicitly.
It seems that the errors occur in the X event handling
outside root. Moving the mouse accelerates the crashes considerably."  Prior
to reading this I concluded (from stack dump) that there was probably
something wrong with X event handling.  My program ran fine as long as I
didn't select a different set of histograms to be displayed, and
occasionally I could display different histogram sets but a crash was
inevitable if I did that.  Further in the above mail it was stated that this
problem was not likely to ever be fixed.

Therefore, if anyone has similar monitoring requirements I'd like to hear
how you overcame these problems.  Any help is appreciated.

Thanks
Kerry



This archive was generated by hypermail 2b29 : Sun Jan 02 2005 - 05:50:05 MET