![]() |
Scrollbars, themes, and Form Views |
Post Reply
|
| Author | |
JohnCrenshaw
Groupie
Joined: 08 September 2006 Status: Offline Points: 65 |
Post Options
Thanks(0)
Quote Reply
Topic: Scrollbars, themes, and Form ViewsPosted: 03 October 2006 at 11:40am |
|
I have a basic CXTResizeFormView in my program. I have it set to resize down to 300x200 pixels minimun and then show a scroll bar. The problem I have is that the scrollbar doesn't take the theme when it comes up. Here is what I have observed:
1. If the scrollbar is needed when my formview first comes up, it has the theme.
2. If the scrollbar is painting with the theme and I size the window in a way that affects the scrollbar (I.E. vertical bar, moving bottom edge), it reverts to the basic windows bar.
3. Once the bar looses the theme, switching away and back (thereby forcing a WM_PAINT message) does NOT cause it to paint right.
4. Each of the three pieces of the scrollbar (each arrow and the thumbar) refreshes independantly once it is used. It is therefore possible to have a half-skinned scrollbar (for example an arrow and thumbar painted right, and the remaining arrow painted by windows.)
5. Switching away and back also causes the bar to revert.
First, Could this bug be fixed.
Second, Is there a possible workaround that I can use?
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 04 October 2006 at 12:32am |
|
Hello, yes, it is known bug of OS. as workaround in our samples we removing scrolbars for forms at all:
void CSimpleForm::OnInitialUpdate()
{ CFormView::OnInitialUpdate(); SetScaleToFitSize(CSize(1, 1));
ModifyStyle(0, WS_CLIPCHILDREN|WS_CLIPSIBLINGS); } |
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
ingo
Newbie
Joined: 10 March 2006 Location: Germany Status: Offline Points: 7 |
Post Options
Thanks(0)
Quote Reply
Posted: 31 October 2006 at 10:58am |
|
Hi,
I use a workaround for the scrollbar problem: I place the CXTResizeFormView in a CMDIChildWnd with a CXTSplitterWnd. One splitter view contains the form view and the other splitter view contains a dummy dialog and has a size of 0. The drawback is the gripper that appears as a thicker border at the bottom. However, in version 9.81 resizing worked this way. In version 10.3.1 it's possible to resize the dialog smaller than it's original size. I have a list control sizing in both directions and a list of buttons keeping their positions to the right of it. The list can be resized smaller than the button list. So the list fits the window size, but scrollbars appear to reach the buttons... |
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |