Bug Report T212122
Visible to All Users

cxColorComboBox - The color name displayed by the input field doesn't match the name selected in the drop-down  list

created 10 years ago

Hi,

I have TcxColorComboBox  with NamingConvention=cxncX11 and PrepareList=cxplX11Ordered. When selected value is i.e Yellow when you click combo, popup list shows YellowGreen. It's really confusing, it seems Yellow value is not available any more. Attached screenshot.

Show previous comments (2)
DevExpress Support Team 10 years ago

    Thank you for the clarification. I will forward this issue to our developers for further research.

      Hi,
      I don't know how far your developers are on solving this, of course, but I've also run into this issue. While looking into it, I've noted the following:
      - At some point, while initializing the colorcombobox (in my case inline in a tableview), the text of the colorcombobox is filled with the name of the color, i.e. 'Yellow'.
      - This causes TcxCustomTextEditLookupData.TextChanged to be executed.
      - This method then uses TcxCustomTextEditLookupData.InternalLocate to update the ItemIndex property of the LookupData.
      - However the InternalLocate method seems to have been written to find the first close match, not an actual match. It searches for the first item that starts with the sought name, not the one that exactly matches it. Since 'YellowGreen' has a lower index in the X11 ordered list than 'Yellow' and it starts with 'Yellow', that item is found and set as active item in the lookup data.
      - Note that only the X11Ordered list has this problem. The Delphi list and the HTML list don't have this problem because those lists do not contain names that are also the first part of other names. The "unordered" X11 list is sorted alphabetically, which means that the partials, like 'Yellow' and 'Lime' are always encountered before the longer ones, such as 'YellowGreen' and 'LimeGreen'.
      Hopefully this post will help the developers locate and fix this issue.
      With regards.

      DevExpress Support Team 10 years ago

        Hello Remco,

        Thank you for your comment. We  will consider it.

        Answers approved by DevExpress Support

        created 10 years ago (modified 10 years ago)

        We have fixed the issue described in this ticket and will include the fix in our next maintenance update. To apply this solution before the official update, request a hotfix by clicking the corresponding link for product versions you require.

        Note: Hotfixes may be unavailable for beta versions and updates that are about to be released.

          Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

          Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.