PlanetSquires Forums

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: StatusBar_SetFont (in AfxCtl.inc)  (Read 288 times)

Paul Squires

  • Administrator
  • Guru Member
  • *****
  • Posts: 8824
  • Windows 10
    • PlanetSquires Software
StatusBar_SetFont (in AfxCtl.inc)
« on: March 04, 2019, 06:58:00 PM »

The incoming hFont parameter is defined as a DWORD when it probably should be HFONT. It results in the calling program to have to do an unnecessary cast.

' ========================================================================================
'  Sets the font that the status bar is to use when drawing text.
' ========================================================================================
PRIVATE SUB StatusBar_SetFont (BYVAL hStatusBar AS HWND, BYVAL hFont AS DWORD, BYVAL fRedraw AS LONG = FALSE)
   SendMessageW(hStatusBar, WM_SETFONT, cast(WPARAM, hFont), cast(LPARAM, fRedraw))
END SUB
Logged
Paul Squires
PlanetSquires Software
WinFBE Editor and Visual Designer

Josť Roca

  • Moderator
  • Guru Member
  • *****
  • Posts: 3187
Re: StatusBar_SetFont (in AfxCtl.inc)
« Reply #1 on: March 04, 2019, 07:07:09 PM »

Modified.