Tom F 85 Posted April 13, 2020 Is there a VCL component (preferably included in the current Delphi) that shows a grid of items that automatically adds and removes columns as it's resized? I want to show items in alphabetical order across each row, as shown below. (Horizontal snaking) As the grid is resized (when the user resizes its form), I want the grid to automatically add more columns, repopulating as shown below. I know I could populate a TStringGrid, but I'd have to monitor the current width, determine how many columns it can accommodate, resize the grid and then repopulate, etc. Rather than re-inventing the wheel (mine would be wobbly and squeak!) I'd rather just hand a TStringList to a pre-existing visual component and have it handle the details. In case I want to create my own from a TStringGrid, the OnResize event fires multiple times as a user drags the borders of the form. How do I detect that the user has finished resizing so I can repopulate the grid? Three columns A B C D E F G H I When the user widens the form so that it's wide enough for five columns, it would look like this:Five Columns A B C D E F G H I One Column A B C C D F G H I Share this post Link to post
Anders Melander 1815 Posted April 13, 2020 The standard windows List-View control, wrapped by the Delphi TListView component does this. The Tile View style is probably what fits your requirements best but unfortunately that isn't directly supported by TListView. Google Delphi LV_VIEW_TILE to find solutions around that. 1 Share this post Link to post
Tom F 85 Posted April 13, 2020 1 hour ago, Anders Melander said: The standard windows List-View control, wrapped by the Delphi TListView component does this. Thanks, Anders. The List-View control works great for my purposes. THANKS!! Share this post Link to post