我正在创建一个GalleryItem并将图像附加到GalleryControl。
顺便说一句,描述位置始终是正确的形象。
我想将位置更改为图像的底部。
我该怎么移动它?
List<GalleryItem> galleryItemList = new List<GalleryItem>();
GalleryItem gi = new GalleryItem();
BitmapImage bmpImg = new BitmapImage();
bmpImg.BeginInit();
bmpImg.UriSource = newUri(@"C:\temp\2.jpg");
bmpImg.EndInit();
gi.Glyph = bmpImg;
gi.Description = Path.GetFileName(bmpImg.UriSource.LocalPath);
galleryItemList.Add(gi);
myGalleryItemGroup.ItemSource = galleryItemList;
这是我的代码。
将Gallery.ItemGlyphLocation
设为Top
。
xmlns:dxb="http://schemas.devexpress.com/winfx/2008/xaml/bars"
<dxb:GalleryControl>
<dxb:Gallery ItemGlyphLocation="Top">
<dxb:GalleryItemGroup x:Name="myGalleryItemGroup">
<!--...-->
</dxb:GalleryItemGroup>
</dxb:Gallery>
</dxb:GalleryControl>
此外,最好在下次使用DevExpress时将问题转发给DevExpress。他们的客户支持非常棒。