PlanetSquires Forums

Support Forums => Other Software and Code => Topic started by: Elias Montoya on June 04, 2009, 05:36:19 PM

Title: StatusBar flickers badly. Any ideas?
Post by: Elias Montoya on June 04, 2009, 05:36:19 PM

Im not doing anything special, just setting text to it using FF_StatusBar_SetText()

The text might change up to 5 times per second, and it flickers like controls do when
dialog is resized without the WS_CLIPCHILDREN style.
Title: Re: StatusBar flickers badly. Any ideas?
Post by: TechSupport on June 04, 2009, 06:04:50 PM
Hi Elias,

I don't see any flicker (I'm testing on Vista).

However, you may want to create a second SetText function to test. The original one below should be modified to remove the refresh of the entire statusbar.

Original:

Function FF_StatusBar_SetText (ByVal hStatus As Dword, ByVal iPart As Dword, ByVal sText As String, Opt ByVal uType As Dword) As Dword
   Function = SendMessage (hStatus, %SB_SETTEXT, iPart Or uType, ByVal StrPtr(sText))
   InvalidateRect hStatus, ByVal %Null, %TRUE
   UpdateWindow hStatus
End Function


New test version:

Function FF_StatusBar_SetText (ByVal hStatus As Dword, ByVal iPart As Dword, ByVal sText As String, Opt ByVal uType As Dword) As Dword
   Function = SendMessage (hStatus, %SB_SETTEXT, iPart Or uType, ByVal StrPtr(sText))
End Function

Title: Re: StatusBar flickers badly. Any ideas?
Post by: Elias Montoya on June 04, 2009, 06:41:04 PM
 Flicker was reduced to an acceptable level. Almost completely gone. :)

However, it still flickers when dialog is resized. Im using Windows XP, SP3.

Thanx Paul.