Widget flicker / text shifting

I am running QNX425G/Photon 1.14D.

I am having a problem where text in my display applications flicker every cycle (updating custom widgets at 500ms) and sometimes the text shifts within the widget. I am using custom widgets, but this occurs also on PtButtons and Text widgets just as much. It is not constant, but enough to be quite noticeable. (by “shift”, I mean it looks like it re-arranges itself in the widget causing it to move to a position other than the position I programmed it to be in – and by re-arranging it some of the text is lost outside the area of the widget is seems. also, i am talking about hard coded text, not dynamic)

The flicker is an update issue associated with the text shift. Since the text has been found to shift, I put it in a DBContainer and there is a key in the USERDATA of the container so that container is specifically damaged (using PtDamageWidget) each loop. This corrects the text shift when it occurs, but it makes all of the widgets in the container flicker.

Can someone offer some advice on how I can try to track down the problem? Can I put some code in to try to watch all the widgets and catch some resource changing when it should not? Should I be “PtHold”-ing and “PtRelease”-ing these widgets (I do not understand what these calls do, or what “flux” is either). Is there a video issue here? is my video not fast enough, or am I using the wrong driver (I am using Pg.chips and I tried Pg.svga)?

I have noticed in PhAB that if the area of a text widget is too small, some of the text gets cut out until you make the widget large enough. Is there anything known to happen to a widget at runtime that could make it think it is not large enough for a short period so that it redraws wrong?

And possibly related, I have PtLists that are randomly “scrunched up” when first realized. The are distorted and the text is compacted until you leave the window and return, which usually corrects it. has anyone seen this either?


Has anyone seen widgets react strangely during runtime when the widget “margin” resources are set too large? I seemed to have stumbled on this as possibly causing the problem and I will be testing to see if it solves it. Has this caused anyone else headaches in the past?

I still don’t have any leads on why the PtList’s are messing up though.

I am still having this problem across multiple systems. I am programming graphical displays in PhAB. I have attempted to use PtHold and PtRelease to try to separate the processing of some larger background callbacks from the Photon processing of the graphics. I thought that maybe there was a lot of processing going on when switching to new displays, but the PtHold and PtRelease calls don’t seem to make a difference. (Plus, I saw somewhere else in this forum that these calls are automatically called for callbacks anyways)

It seems that setting the margins to ZERO reduces the text shifting problem, but it has not completely disappeared. Does anyone know if there is something wrong the PtMultiText widgets that would cause them to shift the text incorrectly? Can I force Photon to not attempt to format these widgets in a way other than how I set them up under PhAB? Is there a problem using PtMultiText widgets together with DBContainer widgets?

Also, I have numerous PtLabel based custom widgets in my applications. When i come to a display with a lot of these widgets, sometimes one of them has no text in it. damaging this widget manually seems to fix it. Am I overloading the font server or something? Is there a way to set up this widget and then have it damage itself to force a correction if one is needed?

I am having a lot of text issues in my PhAB applications and I can’t seem to figure out why. Is there a way to slow down the speed that Photon switches to a new display? Maybe my video hardware can’t keep up. I have a single board computer – 500 Mhz intel chip with 256Meg RAM, onboard video.