Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS Tech Support » CExtN* and CExtW* Collapse All
Subject Author Date
John Ritzenthaler Jan 29, 2009 - 5:37 PM

I can’t find any documentation whatsoever on the various templates such as CExtNCSB.


How do I add your scrollbars to my class derived from CWnd?  I already have extensive mouse control.  I just want the Aqua scrollbar look.


Thanks


PS - Sorry to send so many emails.  I REALLY try to find these things in the documentation but it really isn’t oriented toward rookies.

Technical Support Feb 1, 2009 - 11:39 AM

There are two template decorator classes in Prof-UIS for injecting themed CExtScrollBar windows into other windows:

1) The CExtNSB template class adds themed scroll bars into any CExtScrollWnd window like the CExtGridWnd control. The CExtGridWnd class implements plain grid control which uses default Windows scrollbars by default. You can use the CExtNSB < CExtGridWnd > template based type which is the CExtGridWnd control with themed scroll bars. The CExtNSB template class creates two CExtScrollBar windows inside the CExtScrollWnd-based window. If you need to create a completely new scrollable control written from scratch, then we recommend you to use the CExtScrollWnd class as the base class for this control. It’s the extended version of generic CWnd window with scrolling support.

2) The CExtNCSB template class adds themed scrollbars into any window which uses non-client area based scrollbars. This template class creates two CExtScrollBar windows on the same Z-order layer with the window which has default non-client area based scroll bars and places the created scroll bar windows over non-client area scroll bars. The constructor of the CExtNCSB has two flag parameters which allow you to specify whether the CExtScrollBar windows should be created with a delay and whether CExtNCSB template class should work in the middle container mode. The delay is often required to avoid conflicts inside MFC code which not always allows to created one window when handling the WM_CREATE message of other window. The middle container mode needs to be discussed separately. By default, if you have N child controls on some dialog and if you applied the CExtNCSB template class to some of them, then the dialog window will have N+2 child windows because of the CExtNCSB template class creates two CExtScrollBar windows for one of dialog controls. If the CExtNCSB template class uses the middle container window, then it creates one container window between scrollable window and its parent window and this container window has three child windows - scrollable window and two CExtScrollBar windows. The middle container mode is required if you want to skin scroll bars of a window created inside the CExtControlBar resizable control bar window which requires only one child window.