Applies to: desktop apps only
Represents a Split Button Gallery control with a gallery-based, drop-down menu.
Usage
<SplitButtonGallery ApplicationModes = "xs:string" CommandName = "xs:positiveInteger or xs:string" HasLargeItems = "Boolean" ItemHeight = "xs:integer" ItemWidth = "xs:integer" TextPosition = "TextPositionType" Type = "xs:string"> child elements </SplitButtonGallery>
Attributes
| Attribute | Type | Required | Description |
|---|---|---|---|
|
ApplicationModes |
xs:string |
No |
Valid only if MenuGroup is the parent element. |
|
CommandName |
xs:positiveInteger or xs:string |
No |
Associates the element with a Command. |
|
HasLargeItems |
Boolean |
No |
Determines whether the large or small image resource of the Command is displayed in the gallery control. Note Applies only to galleries where the value of the Type
attribute is equal to Restricted to one of the following values (0 and 1 are not valid): |
|
ItemHeight |
xs:integer |
No | |
|
ItemWidth |
xs:integer |
No | |
|
TextPosition |
TextPositionType |
No |
Restricted to one of the following values: |
|
Type |
xs:string |
No |
Restricted to one of the following values: |
Child elements
| Element | Description |
|---|---|
|
May occur one or more times | |
|
May occur one or more times | |
|
May occur one or more times | |
|
Must occur exactly once | |
|
May occur at most once | |
|
May occur one or more times |
Parent elements
| Element |
|---|
Remarks
Optional.
May occur one or more times for each ControlGroup, Group, MenuGroup, or SplitButton element.
SplitButtonGallery supports application modes.
If MenuGroup is the parent element, then SplitButtonGallery must have no child elements.
UI_PKEY_BooleanValue is used by an application to query the toggle-state for the button control of a SplitButtonGallery.
The following screen shot illustrates the Ribbon Split Button Gallery control in Microsoft Paint for Windows 7.

Examples
The following example demonstrates the basic markup for the Split Button Gallery.
This section of code shows the SplitButtonGallery Command declarations, with an associated Group that functions as the parent container for the SplitButtonGallery element.
<!-- SplitButtonGallery -->
<Command Name="cmdSplitButtonGalleryGroup"
Symbol="cmdSplitButtonGalleryGroup"
Comment="SplitButtonGallery Group"
LabelTitle="SplitButtonGallery"/>
<Command Name="cmdSplitButtonGallery"
Symbol="cmdSplitButtonGallery"
Comment="SplitButtonGallery"
LabelTitle="SplitButtonGallery"/>
This section of code shows the SplitButtonGallery control declarations.
<!-- SplitButtonGallery -->
<Group CommandName="cmdSplitButtonGalleryGroup">
<SplitButtonGallery CommandName="cmdSplitButtonGallery">
<SplitButtonGallery.MenuLayout>
<FlowMenuLayout Rows="2"
Columns="3"
Gripper="None"/>
</SplitButtonGallery.MenuLayout>
<SplitButtonGallery.MenuGroups>
<MenuGroup>
<Button CommandName="cmdButton1"></Button>
<Button CommandName="cmdButton2"></Button>
</MenuGroup>
<MenuGroup>
<Button CommandName="cmdButton3"></Button>
</MenuGroup>
</SplitButtonGallery.MenuGroups>
</SplitButtonGallery>
</Group>
Element information
|
Minimum supported system | Windows 7 |
|---|---|
| Can be empty | No |
See also
Send comments about this topic to Microsoft
Build date: 2/15/2012