{"id":40561381,"url":"https://github.com/SpicyTaco/SpicyTaco.AutoGrid","last_synced_at":"2026-01-21T01:01:53.705Z","repository":{"id":18053703,"uuid":"21107403","full_name":"SpicyTaco/SpicyTaco.AutoGrid","owner":"SpicyTaco","description":"A magical replacement for the built in WPF Grid and StackPanel","archived":false,"fork":false,"pushed_at":"2023-08-14T07:46:15.000Z","size":185,"stargazers_count":82,"open_issues_count":10,"forks_count":19,"subscribers_count":5,"default_branch":"master","last_synced_at":"2026-01-14T13:39:03.785Z","etag":null,"topics":["autogrid","c-sharp","dotnet","margin","panel","stackpanel","wpf","wpf-grid","wpftoolkit","xaml"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SpicyTaco.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"license","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2014-06-22T22:29:33.000Z","updated_at":"2025-04-08T19:05:06.000Z","dependencies_parsed_at":"2022-07-26T20:32:03.261Z","dependency_job_id":"1be1ac28-9723-4788-93c2-f84acad15533","html_url":"https://github.com/SpicyTaco/SpicyTaco.AutoGrid","commit_stats":null,"previous_names":["kmcginnes/spicytaco.autogrid"],"tags_count":22,"template":false,"template_full_name":null,"purl":"pkg:github/SpicyTaco/SpicyTaco.AutoGrid","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpicyTaco%2FSpicyTaco.AutoGrid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpicyTaco%2FSpicyTaco.AutoGrid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpicyTaco%2FSpicyTaco.AutoGrid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpicyTaco%2FSpicyTaco.AutoGrid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SpicyTaco","download_url":"https://codeload.github.com/SpicyTaco/SpicyTaco.AutoGrid/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpicyTaco%2FSpicyTaco.AutoGrid/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28620572,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T23:49:58.628Z","status":"ssl_error","status_checked_at":"2026-01-20T23:47:29.996Z","response_time":117,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["autogrid","c-sharp","dotnet","margin","panel","stackpanel","wpf","wpf-grid","wpftoolkit","xaml"],"created_at":"2026-01-21T01:00:42.307Z","updated_at":"2026-01-21T01:01:53.669Z","avatar_url":"https://github.com/SpicyTaco.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"SpicyTaco.WpfToolkit\n==================\n\nA magical replacement for the built in WPF Grid and StackPanel.\n\n\u003e **NOTE:** I'm in the process of renaming this project from SpicyTaco.AutoGrid to SpicyTaco.WpfToolkit. This is because I plan to add more useful features to this package beyond just AutoGrid.\n\n## Installation\n\nTo add SpicyTaco.WpfToolkit to your WPF project, all you have to do is install it from NuGet:\n\n```\nInstall-Package SpicyTaco.AutoGrid\n```\n\nUsage Examples\n--------------\n\n**AutoGrid**\n\nIn order to get\n\n![Form Image](v2_gridlayout.png)\u003cbr/\u003e\n[Sourced from the awesome WpfTutorials](http://wpftutorial.net/GridLayout.html)\n\nYou would typically write XAML that looked like\n\n```xml\n\u003cGrid\u003e\n    \u003cGrid.RowDefinitions\u003e\n        \u003cRowDefinition Height=\"Auto\" /\u003e\n        \u003cRowDefinition Height=\"Auto\" /\u003e\n        \u003cRowDefinition Height=\"*\" /\u003e\n        \u003cRowDefinition Height=\"28\" /\u003e\n    \u003c/Grid.RowDefinitions\u003e\n    \u003cGrid.ColumnDefinitions\u003e\n        \u003cColumnDefinition Width=\"Auto\" /\u003e\n        \u003cColumnDefinition Width=\"200\" /\u003e\n    \u003c/Grid.ColumnDefinitions\u003e\n    \u003cLabel Grid.Row=\"0\" Grid.Column=\"0\" Content=\"Name:\"/\u003e\n    \u003cLabel Grid.Row=\"1\" Grid.Column=\"0\" Content=\"E-Mail:\"/\u003e\n    \u003cLabel Grid.Row=\"2\" Grid.Column=\"0\" Content=\"Comment:\"/\u003e\n    \u003cTextBox Grid.Column=\"1\" Grid.Row=\"0\" Margin=\"3\" /\u003e\n    \u003cTextBox Grid.Column=\"1\" Grid.Row=\"1\" Margin=\"3\" /\u003e\n    \u003cTextBox Grid.Column=\"1\" Grid.Row=\"2\" Margin=\"3\" /\u003e\n    \u003cButton Grid.Column=\"1\" Grid.Row=\"3\" HorizontalAlignment=\"Right\" \n            MinWidth=\"80\" Margin=\"3\" Content=\"Send\"  /\u003e\n\u003c/Grid\u003e\n```\n\nYou can simply write\n\n```xml\n\u003cst:AutoGrid Rows=\"Auto,Auto,*,28\" Columns=\"Auto,200\" Orientation=\"Vertical\"\u003e\n    \u003cLabel Content=\"Name:\"/\u003e\n    \u003cLabel Content=\"E-Mail:\"/\u003e\n    \u003cLabel Content=\"Comment:\"/\u003e\n    \u003cLabel /\u003e \u003c!-- Empty placeholder for lower left corner --\u003e\n    \n    \u003cTextBox Margin=\"3\" /\u003e\n    \u003cTextBox Margin=\"3\" /\u003e\n    \u003cTextBox Margin=\"3\" /\u003e\n    \u003cButton HorizontalAlignment=\"Right\" \n            MinWidth=\"80\" Margin=\"3\" Content=\"Send\"  /\u003e\n\u003c/st:AutoGrid\u003e\n```\n\nI personally like to put my `Label`s with the element they are labeling. So just remove the `Orientation` which defaults to `Horizontal` and rearrange the elements. You can also pull the common margin up, defining it only once.\n\n```xml\n\u003cst:AutoGrid Rows=\"Auto,Auto,*,28\" Columns=\"Auto,200\" ChildMargin=\"3\"\u003e\n    \u003cLabel Content=\"Name:\"/\u003e\n    \u003cTextBox/\u003e\n\n    \u003cLabel Content=\"E-Mail:\"/\u003e\n    \u003cTextBox/\u003e\n\n    \u003cLabel Content=\"Comment:\"/\u003e\n    \u003cTextBox/\u003e\n\n    \u003cLabel /\u003e\u003c!-- Empty placeholder for lower left corner --\u003e\n    \u003cButton HorizontalAlignment=\"Right\" \n            MinWidth=\"80\" Content=\"Send\"  /\u003e\n\u003c/st:AutoGrid\u003e\n```\n\n**StackPanel**\n\nThe built in StackPanel control has always been frustrating to use. When you have a `TextBlock` that has a lot of text, it is impossible to wrap that text without setting an explicit width. Also, a StackPanel does not fill its container. \n\nAlso, I've always wanted a simple container which would apply a margin but only between child elements. This allows me to control the margin of the parent and the spacing between each child separately and cleanly.\n\n```xml\n\u003cst:StackPanel Orientation=\"Horizontal\" MarginBetweenChildren=\"10\" Margin=\"10\"\u003e\n    \u003cButton Content=\"Info\" HorizontalAlignment=\"Left\" st:StackPanel.Fill=\"Fill\"/\u003e\n    \u003cButton Content=\"Cancel\"/\u003e\n    \u003cButton Content=\"Save\"/\u003e\n\u003c/st:StackPanel\u003e\n```\n\nCredits\n-------\n\n\u003cimg src=\"icon/icon_61620.png\" alt=\"Icon\" style=\"width: 128px; height: 128px;\"/\u003e\u003cbr/\u003e\n[Furious designed by Matt Brooks from the Noun Project](http://thenounproject.com/Mattebrooks/icon/61620/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSpicyTaco%2FSpicyTaco.AutoGrid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FSpicyTaco%2FSpicyTaco.AutoGrid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSpicyTaco%2FSpicyTaco.AutoGrid/lists"}