Jacek,Originally Posted by jacek
I call QCanvasItem.update(). Well, it is a subclass where I implement the drawing of the item. Whenever a data even occurs in my system I have to go through a lengthy formatting procedure and prepare the output, then I call update() to get the data rendered. I would like to not have to go through the formatting if the item is not being displayed anyway. So what I want is:
Qt Code:
fOnData(char* szData) { if !isObscured() { fFormatData(szData); update(); } // Ignore data as it is not rendered anyway else { } }To copy to clipboard, switch view to plain text mode
If the items gets uncovered and a paint even issued I can recover the data and do the formatting then. The data events occur with a 100ms frequency and there can be thousands of them, so it is important to not incur this overhead until it is really needed.
Thanks,
Tom
Bookmarks