<< Return to Main Index

< Return to Class Index

CGXAbstractControlFactory::RegisterAllUserAttributes

virtual void RegisterAllUserAttributes(CGXStylesMap* pStylesMap) = 0;

pStylesMap

Points to the CGXStylesMap object where the user attribute descriptions shall be added.

Remarks

RegisterAllUserAttributes is called to register the user attribute names with the styles map. This is necessary when you want the user attributes to appear in the User attribute-page of the CGXStyleSheet.

You should override this method either if you have added your own user attributes and you want them to appear in the style sheets for all grids in your application or if you only want a specific selection of user attributes to appear in the CGXStyleSheet.

Note: This method registers user attributes only to appear in the CGXStyleSheet. If you don’t want a user attribute to be visible in the CGXStyleSheet, you don’t have to register it here. You will still be able to use the user attribute with CGXStyle::SetUserAttribute in your grid. You only disable the possibility that the user can change the user attribute through the style sheet.

Here is an example of what your override of RegisterAllUserAttributes might look like:

void CGXControlFactory::RegisterAllUserAttributes(CGXStylesMap* pStylesMap)

{

CGXControl::AddUserAttributes(pStylesMap);

CGXSpinEdit::AddUserAttributes(pStylesMap);

CGXCheckBox::AddUserAttributes(pStylesMap);

CGXMaskControl::AddUserAttributes(pStylesMap);

CGXProgressCtrl::AddUserAttributes(pStylesMap);

CGXTabbedComboBox::AddUserAttributes(pStylesMap);

CGXTabbedComboBoxWnd::AddUserAttributes(pStylesMap);

#if _MFC_VER >= 0x0400

CGXDateTimeCtrl::AddUserAttributes(pStylesMap);

#endif

}

See Also

CGXControl::AddUserAttributes CGXStylesMap::RegisterDefaultUserAttributes

CGXAbstractControlFactory

Class Overview | Class Members