Property Sheet : Too Many Tabs... Ahhhh!

Property Sheet : Too Many Tabs... Ahhhh!

Post by Danie » Sat, 21 Mar 1998 04:00:00



Hi,

I've got a situation where I have so many pages on a property sheet that it
wraps the tabs for the pages into rows. Now I don't want this, on the
TabControl there is the flag TCS_MULTILINE which makes a spin button appear
to move to the hidden pages but I'm wondering is there any way to do it
with a PROPERTYSHEET. Now in the VC++ 4.0 documentation there was reference
to the flag PSH_MULTILINETABS but this was not defined anywhere in the
headers ( ?? ) And in any case I'm using VC++ 5.0. Now I realise that one
way to deal with this is shorten the PROPERTYPAGE title names or widen the
actual pages.... but this is not really what I want, so any takers ?

Thanks,
Daniel

 
 
 

Property Sheet : Too Many Tabs... Ahhhh!

Post by John Cousin » Sat, 21 Mar 1998 04:00:00




Quote:>Hi,

>I've got a situation where I have so many pages on a property sheet that it
>wraps the tabs for the pages into rows. Now I don't want this, on the
>TabControl there is the flag TCS_MULTILINE which makes a spin button appear
>to move to the hidden pages but I'm wondering is there any way to do it
>with a PROPERTYSHEET. Now in the VC++ 4.0 documentation there was reference
>to the flag PSH_MULTILINETABS but this was not defined anywhere in the
>headers ( ?? ) And in any case I'm using VC++ 5.0. Now I realise that one
>way to deal with this is shorten the PROPERTYPAGE title names or widen the
>actual pages.... but this is not really what I want, so any takers ?

>Thanks,
>Daniel

Daniel,

EnableStackedTabs( FALSE );

should do it.

John Cousins
Software Engineer


 
 
 

Property Sheet : Too Many Tabs... Ahhhh!

Post by Ken Thoma » Sat, 21 Mar 1998 04:00:00


You appear to not be using MFC. However, MFC source can give you the
clue you need.

MFC has the function CPropertySheet::EnableStackedTabs that you can call
with FALSE before calling DoModal.  Looking through the source, you can
see that in CPropertySheet::OnInitDialog, the following code is
executed:

if (!m_bStacked)
{
   HWND hWndTab = (HWND)SendMessage(PSM_GETTABCONTROL);
   if (hWndTab != NULL)
      CWnd::ModifyStyle(hWndTab, TCS_MULTILINE, TCS_SINGLELINE, 0);

Quote:}

Look at the source for CWnd::ModifyStyle and follow it down to
_AfxModifyStyle and see that MFC uses calls to Get/SetWindowLong. Do
something similar in your non-MFC code by translating the MFC code
appropriately.

Ken

 
 
 

1. How could i get the property sheet tab control with single row tabs?

I have following problem:
My property sheet control has 5 tabs. I've implemented risizing of  he
control(window). As i resize it so that all tabs don't fit to the window
the control changes its look to the multiline one (automatically). I
want prevent it so that the control looks like that one in the Microsoft
Developer Studio in the Build-Settings-Menu (with an horizontal
scrollbar in the right top edge of the tab control)

Has anybody an idea, how i could do it?

Alexander

2. WEB BROWSER STUDIO

3. How to disable property page tab on property sheet?

4. Align Annotation

5. Create a property sheet within a property sheet.

6. Need name & address matching algorithms

7. Device Manager property sheet tab.

8. input string was not in a correct

9. Tab Order backward once a dialog is placed in a Property Sheet

10. How to make the Tab control of a property sheet ownerdraw?

11. How To: Same size tabs on Property Sheets.

12. Tab Controls/Property sheets problem (again)

13. Tab Controls/Property sheets problem