An image says more ;-). I would like to have a custom image and make it larger. (for the Column Chooser Icon).
Is this possible?
Maybe with a creationfilter? Or setting a property?
Can you provide me with an example?
Kind regards, Lieven Cardoen
Hi Mike,
As you can see, the Image size just remains the same.
Is there also a way to enlarge the right arrow in the Row? (I can create a different thread for that one if you want, but maybe it can be done with the same CreationFilter....).
Lieven
Don't i also need a drawfilter? Could you try it out in a little example (solution)?
Thx, Lieven
Tried this and the image doesn't increase... The code is triggered. The parent rect has the correct values. But the imageElement doesn't seem to do anything with its new Rect.
Hi Lieven,
You can increase the size of the column chooser button by setting the following properties:
ultraGrid1.DisplayLayout.Override.RowSelectorWidth = 100;ultraGrid1.DisplayLayout.Bands[0].ColHeaderLines = 5;
You can use this creation filter to increase the size of the image once the button is larger:
public class ColumnChooserButtonCreationFilter : IUIElementCreationFilter{ public void AfterCreateChildElements(UIElement parent) { if (parent is ImageAndTextUIElement && parent.Parent is ColumnChooserButtonUIElement) { UIElement imageElement = parent.GetDescendant(typeof(ImageAndTextDependentImageUIElement)); imageElement.Rect = parent.Rect; } } public bool BeforeCreateChildElements(UIElement parent) { return false; }}
public bool BeforeCreateChildElements(UIElement parent) { return false; }}
That would be great! Thx!