Print Page | Close Window

Scrollbars, themes, and Form Views

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=5205
Printed Date: 11 November 2025 at 4:22pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Scrollbars, themes, and Form Views
Posted By: JohnCrenshaw
Subject: Scrollbars, themes, and Form Views
Date Posted: 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?
 



Replies:
Posted By: Oleg
Date 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


Posted By: ingo
Date 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...




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net