Hello,
When i scroll the filter content, the combo resizes every time during the scroll. Is there a way to fix the width of the drop down to the widest item even it is not initially in view?
Thanks Krasimir-
I fixed up something using the XamComboBox DropDownOpened event that works pretty well. But if there are ever other combo boxes in the grid (we don't have any) then it probably fails. I'll keep a reference to your technique in the code so that if we ever have to revisit this, we can try your approach.
Thanks,
Mike
Hello Mike,
I have been looking into your question and since you are setting the FilterUIType to LabelIcons, the filter items are rendered inside a PopupResizedDecorator. In order to implement the same appearance when you are using LabelIcons, you can handle the Loaded event of the PopupResizerDecorator and in its event handler you can apply logic, similar to the one, that I have used in my original post. Since the PopupResizerDecorator is a Popup, you can add the style for it, in the Resources section of App.xaml. I have modified the sample application that I have previously attached in order to demonstrates how you can implement this approach.
Sincerely,
Krasimir
Developer Support Engineer
Infragistics
www.infragistics.com/support
We're using FilterUIType="LabelIcons". Does anyone know how to modify this to work with LabelIcons? I've tied a bunch of things, but so far no luck.
Hello ,
To prevent such behavior follow the steps below:
1. Create FilterCellValuePresenter style for the XamDataGrid.2. Insert EventSetter for Loaded event in the FilterCellValuePresenter style.3. In the event handler handle DropDownOpen event of the FilterCellValuePresenter sender object.4. In the DropDownOpen handler find the largest element of the underlying ComboBox of the XamComboEditor and set the MaxDropDownWidth and MinDropDownHeight to this value plus 30 pixels for the padding of the scroll bar
I have created and attached a sample application that follows the steps above.
Sincerely,KrasimirDeveloper Support EngineerInfragistics, Inc.www.infragistics.com/support