If I run a form with ShowWindow=2 (As Top Level form) and with windowstate = 2 (maximized) the title bar appears misconfigured.
Try run frmribbon sample with this settings.
SO = Windows 7
Paulo Martins
ribbon bar bug
Re: ribbon bar bug
Actually, this is not my library bug, this is VFP bug. Forms (try it without my library) set in the designer as Top-Level and Maximized at run-time do not have semitransparent glass effect in Aero mode, they appear as in Basic mode. I didn't find a way how to fix this issue in my library but I have a solution you can use in the Init event of the form:
Or, one more solution: you can set WindowState to 0 (normal) in the designer, and set it to 2 (maximized) at run-time in the Activate event. Make sure you do that only once (when Activate event fires first time), and not each time the form activates.
Code: Select all
Local lMaximized
lMaximized = .F.
If ThisForm.WindowState = 2
ThisForm.WindowState = 0
lMaximized = .T.
EndIf
... all Init code goes here, including call to InitCommandBars method of CBM
If m.lMaximized
ThisForm.Visible = .T.
ThisForm.WindowState = 2
EndIf
With best regards,
Alex Grigorjev
(ARG-Software Design Lab.)
Alex Grigorjev
(ARG-Software Design Lab.)
-
- Posts: 1
- Joined: Tue Jan 26, 2010 11:32 am
Re: ribbon bar bug
I have the same problem, but I have the CommandBarsManager on the _Screen-object. The solution with the WindowState-property is not working with _Screen. Is there another way to display the ribbon correct in Vista and Windows 7. In Windows XP the ribbon is correct.
Edit: In the .exe the solution with the WindowState-property works well. The ribbin goes wrong when I start my application in the Vfp-IDE. It would be very nice if it is also working well in the IDE.
Edit: In the .exe the solution with the WindowState-property works well. The ribbin goes wrong when I start my application in the Vfp-IDE. It would be very nice if it is also working well in the IDE.