Skip to content

Add support for footers to ListViewGroup #2653

Closed

Description

@hughbe
  • You can set the LVGF_FOOTER flag on mask and set pszFooter to a valid string and cchFooter to the length of the string
  • You can set the LVGF_ALIGN flag on mask and set the uAlign to a valid LVGA_FOOTER_CENTER value

Proposed API

This would add the following APIs to ListViewGroup:

public class ListViewGroup
{
    ...
    public string Footer { get; set; }
    public HorizontalAlignment FooterAlignment { get; set; }
    ...
}

Example

var group = new ListViewGroup
{
     Footer = "NewFooter",
     FooterAlignment = HorizontalAlign.Center
};

image

Activity

  1. ghost added
    🚧 work in progress
    on Jan 7, 2020
  2. added
    api-ready-for-review
    api-suggestion
    design-discussion
    tenet-compatibility-OS
    on Jan 7, 2020
  3. RussKie commented on Jan 22, 2020

    @RussKie
    Contributor

    The team had some preliminary discussions about enhancing the control.
    Could you spare few minutes and provide answers to the following questions so we can take it to the next level:

    • Will VS Designer need to support the feature? If yes, describe how you expect it to funсtion.
    • What impact will it have on accessibility?
    • Will this feature need to be localized or be localizable?
  4. added
    waiting-author-feedback
    on Jan 22, 2020
  5. added this to the 5.0 milestone on Jan 23, 2020
  6. hughbe commented on Feb 7, 2020

    @hughbe
    ContributorAuthor

    Will VS Designer need to support the feature? If yes, describe how you expect it to function.

    Yes. I would expect "Footer" and "FooterAlignment" to appear in the following editor (same as "Header" and "HeaderAlignment"
    image

    What impact will it have on accessibility?

    I don't think ListViewGroups header is currently accessible at all? So I'm not really sure what we actually expect from accessibility here
    image

    Will this feature need to be localized or be localizable?

    I would expect the user to need to localise the footer string, but I think (?) this is the responsibility of the user. Any documentation will need to be localized.

  7. weltkante commented on Feb 7, 2020

    @weltkante
    Contributor

    I would expect "Footer" and "FooterAlignment" to appear in the following editor (same as "Header" and "HeaderAlignment"

    I would expect the user to need to localise the footer string

    Probably both will just work by itself if the new properties are annotated correctly with metadata attributes. Since there is precedence with existing Header and HeaderAlignment the new properties would basically want the same treatment as the existing properties.

    If VS feels the need to do anything special about the existing properties it would have to do the same for the new properties (ideally it shouldn't need to but you never know if VS designer puts an override onto a TypeDescriptor to implement some workaround or customized experience, like it does for example on Image properties where it overrides the default TypeDescriptor to provide a different selection dialog than someone would get outside VS, you can only know if you have access to the VS designer source).

  8. hughbe commented on Feb 7, 2020

    @hughbe
    ContributorAuthor

    In terms of accessibility, see #1726

  9. removed
    waiting-author-feedback
    on Feb 10, 2020
  10. added
    api-approved
    and removed
    api-ready-for-review
    on Mar 5, 2020
  11. terrajobst commented on Mar 5, 2020

    @terrajobst
    Contributor

    Video

    • Looks good as proposed
    namespace System.Windows.Forms
    {
        public partial class ListViewGroup
        {
            public string Footer { get; set; }
            public HorizontalAlignment FooterAlignment { get; set; }
        }
    }
  12. ghost removed
    🚧 work in progress
    on Mar 10, 2020
  13. removed
    design-discussion
    on Mar 10, 2020
  14. removed this from the 5.0 Preview 1- 4 milestone on Apr 20, 2020
  15. ghost locked as resolved and limited conversation to collaborators on Feb 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    api-approvedapi-suggestiontenet-compatibility-OS

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions