첨부 실행 코드는 나눔고딕코딩 폰트를 사용합니다.
유용한 소스 코드가 있으면 icodebroker@naver.com으로 보내주시면 감사합니다.
블로그 자료는 자유롭게 사용하세요.

■ Gallery 엘리먼트 사용하기

------------------------------------------------------------------------------------------------------------------------

<Window.Resources>

    <DataTemplate x:Key="ItemDescriptionDataTemplateKey">

        <TextBlock

            Foreground="Gray"

            Text="{Binding}" />

    </DataTemplate>

</Window.Resources>

<Grid>

    <dxb:GalleryControl>

        <dxb:GalleryControl.Gallery>

            <dxb:Gallery

                IsGroupCaptionVisible="True"

                FilterCaption="(click to filter groups)"

                ColCount="2"

                ItemCheckMode="None"

                ItemDescriptionTemplate="{StaticResource ResourceKey=ItemDescriptionDataTemplateKey}"

                IsItemCaptionVisible="True"

                IsItemDescriptionVisible="True"

                ItemContentHorizontalAlignment="Left"

                ItemClick="pGallery_ItemClick">

                <dxb:Gallery.Groups>

                    <dxb:GalleryItemGroup x:Name="galleryItemGroup1"

                        Caption="Misc Group">

                        <dxb:GalleryItemGroup.Items>

                            <dxb:GalleryItem

                                Caption="Schedule"

                                Description="Show schedule"

                                Glyph="pack://application:,,,/Image/address-16x16.png" />

                            <dxb:GalleryItem

                                Caption="Roles"

                                Description="Assign roles"

                                Glyph="pack://application:,,,/Image/role-16x16.png" />

                        </dxb:GalleryItemGroup.Items>

                    </dxb:GalleryItemGroup>

                    <dxb:GalleryItemGroup x:Name="galleryItemGroup2"

                        Caption="Persons">

                        <dxb:GalleryItemGroup.Items>

                            <dxb:GalleryItem

                                Caption="Employees"

                                Glyph="pack://application:,,,/Image/employee-16x16.png" />

                            <dxb:GalleryItem

                                Caption="Persons"

                                Glyph="pack://application:,,,/Image/person-16x16.png" />

                            <dxb:GalleryItem

                                Caption="Users"

                                Glyph="pack://application:,,,/Image/user-16x16.png" />

                        </dxb:GalleryItemGroup.Items>

                    </dxb:GalleryItemGroup>

                </dxb:Gallery.Groups>

            </dxb:Gallery>

        </dxb:GalleryControl.Gallery>

    </dxb:GalleryControl>

</Grid>

------------------------------------------------------------------------------------------------------------------------

xmlns:dxb="http://schemas.devexpress.com/winfx/2008/xaml/bars"

Posted by 사용자 icodebroker

댓글을 달아 주세요