├── .editorconfig ├── .github └── dependabot.yml ├── .gitignore ├── Gu.Wpf.AutoRowGrid.Demo ├── .editorconfig ├── App.xaml ├── App.xaml.cs ├── AssemblyAttributes.cs ├── AutoIncrementColumnsView.xaml ├── AutoIncrementColumnsView.xaml.cs ├── ColumnDefinitionsView.xaml ├── ColumnDefinitionsView.xaml.cs ├── ColumnSpanView.xaml ├── ColumnSpanView.xaml.cs ├── ExplicitColumnsView.xaml ├── ExplicitColumnsView.xaml.cs ├── Gu.Wpf.AutoRowGrid.Demo.csproj ├── Gu.Wpf.AutoRowGrid.Demo.csproj.DotSettings ├── LastRowFillView.xaml ├── LastRowFillView.xaml.cs ├── MainWindow.xaml ├── MainWindow.xaml.cs ├── NestedRowsView.xaml ├── NestedRowsView.xaml.cs ├── RowHeightView.xaml ├── RowHeightView.xaml.cs ├── SandBoxView.xaml ├── SandBoxView.xaml.cs ├── UiTestWindows │ ├── AutoRowsAndColumnsExplicitHeightWindow.xaml │ ├── AutoRowsAndColumnsExplicitHeightWindow.xaml.cs │ ├── AutoRowsAndColumnsExplicitStarHeightWindow.xaml │ ├── AutoRowsAndColumnsExplicitStarHeightWindow.xaml.cs │ ├── AutoRowsAndColumnsWindow.xaml │ ├── AutoRowsAndColumnsWindow.xaml.cs │ ├── AutoRowsLastRowFillWindow.xaml │ ├── AutoRowsLastRowFillWindow.xaml.cs │ ├── ExplicitRowsAndColumnsLastRowWindow.xaml │ ├── ExplicitRowsAndColumnsLastRowWindow.xaml.cs │ ├── ExplicitRowsAndColumnsWindow.xaml │ ├── ExplicitRowsAndColumnsWindow.xaml.cs │ ├── NestedRowsExplicitHeightWindow.xaml │ ├── NestedRowsExplicitHeightWindow.xaml.cs │ ├── NestedRowsWindow.xaml │ ├── NestedRowsWindow.xaml.cs │ ├── TestElement.cs │ ├── TextBoxView.cs │ └── VisualTreeExt.cs └── ViewModel.cs ├── Gu.Wpf.AutoRowGrid.UiTests ├── .editorconfig ├── AssemblyAttributes.cs ├── AutoRowsAndColumnsExplicitHeightTests.cs ├── AutoRowsAndColumnsExplicitStarHeightTests.cs ├── AutoRowsAndColumnsWindowTests.cs ├── AutoRowsLastRowFillTests.cs ├── ExplicitRowsAndColumnsLastRowFillTests.cs ├── ExplicitRowsAndColumnsTests.cs ├── Gu.Wpf.AutoRowGrid.UiTests.csproj ├── Gu.Wpf.AutoRowGrid.UiTests.csproj.DotSettings ├── Helpers │ └── WindowExt.cs ├── NestedRowsExplicitHeightTests.cs └── NestedRowsTests.cs ├── Gu.Wpf.AutoRowGrid.sln ├── Gu.Wpf.AutoRowGrid.sln.DotSettings ├── Gu.Wpf.AutoRowGrid ├── .editorconfig ├── AssemblyAttributes.cs ├── AutoIncrement.cs ├── AutoIncrementation.cs ├── ColumnDefinitions │ ├── ColumnDefinitions.cs │ ├── ColumnDefinitionsConverter.cs │ └── GridLengthsParser.cs ├── GridExtension.cs ├── Gu.Wpf.AutoRowGrid.csproj ├── Gu.Wpf.AutoRowGrid.csproj.DotSettings ├── Gu.Wpf.AutoRowGrid.snk ├── IRow.cs ├── PublicAPI.Shipped.txt ├── PublicAPI.Unshipped.txt ├── Row.cs ├── Rows.cs └── stylecop.json ├── LICENSE ├── README.md ├── RELEASE_NOTES.md ├── appveyor.yml └── azure-pipelines.yml /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*.xaml] 4 | indent_style = space 5 | indent_size = 2 6 | end_of_line = crlf 7 | trim_trailing_spaces = true 8 | insert_final_newline = true 9 | charset = utf-8 10 | 11 | [*.csproj] 12 | indent_style = space 13 | indent_size = 2 14 | end_of_line = crlf 15 | trim_trailing_spaces = true 16 | insert_final_newline = true 17 | charset = utf-8 18 | 19 | [*.cs] 20 | indent_style = space 21 | indent_size = 4 22 | end_of_line = crlf 23 | trim_trailing_spaces = true 24 | insert_final_newline = true 25 | charset = utf-8 26 | 27 | # Sort using and Import directives with System.* appearing first 28 | dotnet_sort_system_directives_first = true 29 | 30 | # Always use "this." and "Me." when applicable; let StyleCop Analyzers provide the warning and fix 31 | dotnet_style_qualification_for_field = true:suggestion 32 | dotnet_style_qualification_for_property = true:suggestion 33 | dotnet_style_qualification_for_method = true:suggestion 34 | dotnet_style_qualification_for_event = true:suggestion 35 | 36 | # Use language keywords where applicable; let StyleCop Analyzers provide the warning and fix 37 | dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion 38 | dotnet_style_predefined_type_for_member_access = true:suggestion 39 | 40 | # Suggest more modern language features when available 41 | dotnet_style_object_initializer = true:suggestion 42 | dotnet_style_collection_initializer = true:suggestion 43 | dotnet_style_coalesce_expression = true:suggestion 44 | dotnet_style_null_propagation = true:suggestion 45 | dotnet_style_explicit_tuple_names = true:suggestion 46 | 47 | # New line preferences 48 | csharp_new_line_before_open_brace = all 49 | csharp_new_line_before_else = true 50 | csharp_new_line_before_catch = true 51 | csharp_new_line_before_finally = true 52 | csharp_new_line_before_members_in_object_initializers = true 53 | csharp_new_line_before_members_in_anonymous_types = true 54 | csharp_new_line_within_query_expression_clauses = true 55 | 56 | # Indentation preferences 57 | csharp_indent_block_contents = true 58 | csharp_indent_braces = false 59 | csharp_indent_case_contents = true 60 | csharp_indent_switch_labels = true 61 | csharp_indent_labels = flush_left 62 | 63 | # Space preferences 64 | csharp_space_after_cast = false 65 | csharp_space_after_colon_in_inheritance_clause = true 66 | csharp_space_after_comma = true 67 | csharp_space_after_dot = false 68 | csharp_space_after_keywords_in_control_flow_statements = true 69 | csharp_space_after_semicolon_in_for_statement = true 70 | csharp_space_around_binary_operators = before_and_after 71 | csharp_space_around_declaration_statements = do_not_ignore 72 | csharp_space_before_colon_in_inheritance_clause = true 73 | csharp_space_before_comma = false 74 | csharp_space_before_dot = false 75 | csharp_space_before_open_square_brackets = false 76 | csharp_space_before_semicolon_in_for_statement = false 77 | csharp_space_between_empty_square_brackets = false 78 | csharp_space_between_method_call_empty_parameter_list_parentheses = false 79 | csharp_space_between_method_call_name_and_opening_parenthesis = false 80 | csharp_space_between_method_call_parameter_list_parentheses = false 81 | csharp_space_between_method_declaration_empty_parameter_list_parentheses = false 82 | csharp_space_between_method_declaration_name_and_open_parenthesis = false 83 | csharp_space_between_method_declaration_parameter_list_parentheses = false 84 | csharp_space_between_parentheses = false 85 | csharp_space_between_square_brackets = false 86 | 87 | # Prefer "var" only where type is obvious; disable diagnostics since no firm policy is in place yet 88 | csharp_style_var_for_built_in_types = false:none 89 | csharp_style_var_when_type_is_apparent = true:none 90 | csharp_style_var_elsewhere = false:none 91 | 92 | # Prefer method-like constructs to have a block body 93 | csharp_style_expression_bodied_methods = false:none 94 | csharp_style_expression_bodied_constructors = false:none 95 | csharp_style_expression_bodied_operators = false:none 96 | 97 | # Prefer property-like constructs to have an expression-body 98 | csharp_style_expression_bodied_properties = true:none 99 | csharp_style_expression_bodied_indexers = true:none 100 | csharp_style_expression_bodied_accessors = true:none 101 | 102 | # Suggest more modern language features when available 103 | csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion 104 | csharp_style_pattern_matching_over_as_with_null_check = true:suggestion 105 | csharp_style_inlined_variable_declaration = true:none 106 | csharp_style_throw_expression = true:none 107 | csharp_style_conditional_delegate_call = true:suggestion -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- 1 | version: 2 2 | updates: 3 | - package-ecosystem: nuget 4 | directory: "/" 5 | schedule: 6 | interval: daily 7 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ###### -- File Created With Git Source Control Provider 2015 -- ###### 2 | ###### -- From https://github.com/github/gitignore -- ###### 3 | ###### -- Warning Regenerating this file will erase all your custom ignores, unless you add them below the Custom Ignore section at the bottom -- ###### 4 | ## Ignore Visual Studio temporary files, build results, and 5 | ## files generated by popular Visual Studio add-ons. 6 | 7 | # User-specific files 8 | *.suo 9 | *.user 10 | *.userosscache 11 | *.sln.docstates 12 | 13 | # User-specific files (MonoDevelop/Xamarin Studio) 14 | *.userprefs 15 | 16 | # Build results 17 | [Dd]ebug/ 18 | [Dd]ebugPublic/ 19 | [Rr]elease/ 20 | [Rr]eleases/ 21 | x64/ 22 | x86/ 23 | bld/ 24 | [Bb]in/ 25 | [Oo]bj/ 26 | [Ll]og/ 27 | 28 | # Visual Studio 2015 cache/options directory 29 | .vs/ 30 | # Uncomment if you have tasks that create the project's static files in wwwroot 31 | #wwwroot/ 32 | 33 | # MSTest test Results 34 | [Tt]est[Rr]esult*/ 35 | [Bb]uild[Ll]og.* 36 | 37 | # NUNIT 38 | *.VisualState.xml 39 | TestResult.xml 40 | 41 | # Build Results of an ATL Project 42 | [Dd]ebugPS/ 43 | [Rr]eleasePS/ 44 | dlldata.c 45 | 46 | # DNX 47 | project.lock.json 48 | project.fragment.lock.json 49 | artifacts/ 50 | 51 | *_i.c 52 | *_p.c 53 | *_i.h 54 | *.ilk 55 | *.meta 56 | *.obj 57 | *.pch 58 | *.pdb 59 | *.pgc 60 | *.pgd 61 | *.rsp 62 | *.sbr 63 | *.tlb 64 | *.tli 65 | *.tlh 66 | *.tmp 67 | *.tmp_proj 68 | *.log 69 | *.vspscc 70 | *.vssscc 71 | .builds 72 | *.pidb 73 | *.svclog 74 | *.scc 75 | 76 | # Chutzpah Test files 77 | _Chutzpah* 78 | 79 | # Visual C++ cache files 80 | ipch/ 81 | *.aps 82 | *.ncb 83 | *.opendb 84 | *.opensdf 85 | *.sdf 86 | *.cachefile 87 | *.VC.db 88 | *.VC.VC.opendb 89 | 90 | # Visual Studio profiler 91 | *.psess 92 | *.vsp 93 | *.vspx 94 | *.sap 95 | 96 | # TFS 2012 Local Workspace 97 | $tf/ 98 | 99 | # Guidance Automation Toolkit 100 | *.gpState 101 | 102 | # ReSharper is a .NET coding add-in 103 | _ReSharper*/ 104 | *.[Rr]e[Ss]harper 105 | *.DotSettings.user 106 | 107 | # JustCode is a .NET coding add-in 108 | .JustCode 109 | 110 | # TeamCity is a build add-in 111 | _TeamCity* 112 | 113 | # DotCover is a Code Coverage Tool 114 | *.dotCover 115 | 116 | # NCrunch 117 | _NCrunch_* 118 | .*crunch*.local.xml 119 | nCrunchTemp_* 120 | 121 | # MightyMoose 122 | *.mm.* 123 | AutoTest.Net/ 124 | 125 | # Web workbench (sass) 126 | .sass-cache/ 127 | 128 | # Installshield output folder 129 | [Ee]xpress/ 130 | 131 | # DocProject is a documentation generator add-in 132 | DocProject/buildhelp/ 133 | DocProject/Help/*.HxT 134 | DocProject/Help/*.HxC 135 | DocProject/Help/*.hhc 136 | DocProject/Help/*.hhk 137 | DocProject/Help/*.hhp 138 | DocProject/Help/Html2 139 | DocProject/Help/html 140 | 141 | # Click-Once directory 142 | publish/ 143 | 144 | # Publish Web Output 145 | *.[Pp]ublish.xml 146 | *.azurePubxml 147 | # TODO: Comment the next line if you want to checkin your web deploy settings 148 | # but database connection strings (with potential passwords) will be unencrypted 149 | *.pubxml 150 | *.publishproj 151 | 152 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 153 | # checkin your Azure Web App publish settings, but sensitive information contained 154 | # in these scripts will be unencrypted 155 | PublishScripts/ 156 | 157 | # NuGet Packages 158 | *.nupkg 159 | # The packages folder can be ignored because of Package Restore 160 | **/packages/* 161 | # except build/, which is used as an MSBuild target. 162 | !**/packages/build/ 163 | # Uncomment if necessary however generally it will be regenerated when needed 164 | #!**/packages/repositories.config 165 | # NuGet v3's project.json files produces more ignoreable files 166 | *.nuget.props 167 | *.nuget.targets 168 | 169 | # Microsoft Azure Build Output 170 | csx/ 171 | *.build.csdef 172 | 173 | # Microsoft Azure Emulator 174 | ecf/ 175 | rcf/ 176 | 177 | # Windows Store app package directories and files 178 | AppPackages/ 179 | BundleArtifacts/ 180 | Package.StoreAssociation.xml 181 | _pkginfo.txt 182 | 183 | # Visual Studio cache files 184 | # files ending in .cache can be ignored 185 | *.[Cc]ache 186 | # but keep track of directories ending in .cache 187 | !*.[Cc]ache/ 188 | 189 | # Others 190 | ClientBin/ 191 | ~$* 192 | *~ 193 | *.dbmdl 194 | *.dbproj.schemaview 195 | *.pfx 196 | *.publishsettings 197 | node_modules/ 198 | orleans.codegen.cs 199 | 200 | # Since there are multiple workflows, uncomment next line to ignore bower_components 201 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 202 | #bower_components/ 203 | 204 | # RIA/Silverlight projects 205 | Generated_Code/ 206 | 207 | # Backup & report files from converting an old project file 208 | # to a newer Visual Studio version. Backup files are not needed, 209 | # because we have git ;-) 210 | _UpgradeReport_Files/ 211 | Backup*/ 212 | UpgradeLog*.XML 213 | UpgradeLog*.htm 214 | 215 | # SQL Server files 216 | *.mdf 217 | *.ldf 218 | 219 | # Business Intelligence projects 220 | *.rdl.data 221 | *.bim.layout 222 | *.bim_*.settings 223 | 224 | # Microsoft Fakes 225 | FakesAssemblies/ 226 | 227 | # GhostDoc plugin setting file 228 | *.GhostDoc.xml 229 | 230 | # Node.js Tools for Visual Studio 231 | .ntvs_analysis.dat 232 | 233 | # Visual Studio 6 build log 234 | *.plg 235 | 236 | # Visual Studio 6 workspace options file 237 | *.opt 238 | 239 | # Visual Studio LightSwitch build output 240 | **/*.HTMLClient/GeneratedArtifacts 241 | **/*.DesktopClient/GeneratedArtifacts 242 | **/*.DesktopClient/ModelManifest.xml 243 | **/*.Server/GeneratedArtifacts 244 | **/*.Server/ModelManifest.xml 245 | _Pvt_Extensions 246 | 247 | # Paket dependency manager 248 | .paket/paket.exe 249 | paket-files/ 250 | 251 | # FAKE - F# Make 252 | .fake/ 253 | 254 | # JetBrains Rider 255 | .idea/ 256 | *.sln.iml 257 | 258 | 259 | 260 | ###### -- Custom Ignore Section, Make sure all files you add to the git repo are below this line -- ###### 261 | 262 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/.editorconfig: -------------------------------------------------------------------------------- 1 | [*.cs] 2 | 3 | # Default severity for analyzer diagnostics with category 'StyleCop.CSharp.DocumentationRules' 4 | dotnet_analyzer_diagnostic.category-StyleCop.CSharp.DocumentationRules.severity = none 5 | # SA0001: XML comment analysis is disabled due to project configuration 6 | dotnet_diagnostic.SA0001.severity = none 7 | 8 | # CA1062: Validate arguments of public methods 9 | dotnet_diagnostic.CA1062.severity = none 10 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/App.xaml: -------------------------------------------------------------------------------- 1 |  5 | UiTestWindows/ExplicitRowsAndColumnsLastRowWindow.xaml 6 | 7 | 8 | 12 | 13 | 22 | 23 | 31 | 32 | 36 | 37 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/App.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace Gu.Wpf.AutoRowGrid.Demo; 2 | 3 | using System; 4 | using System.Windows; 5 | 6 | /// 7 | /// Interaction logic for App.xaml. 8 | /// 9 | public partial class App : Application 10 | { 11 | protected override void OnStartup(StartupEventArgs e) 12 | { 13 | if (e is { Args: { Length: 1 } args }) 14 | { 15 | var window = args[0]; 16 | this.StartupUri = new Uri($"UiTestWindows/{window}.xaml", UriKind.Relative); 17 | } 18 | 19 | base.OnStartup(e); 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/AssemblyAttributes.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Windows; 3 | 4 | [assembly: CLSCompliant(false)] 5 | [assembly: ThemeInfo(ResourceDictionaryLocation.None, ResourceDictionaryLocation.SourceAssembly)] 6 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/AutoIncrementColumnsView.xaml: -------------------------------------------------------------------------------- 1 |  10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/AutoIncrementColumnsView.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace Gu.Wpf.AutoRowGrid.Demo; 2 | 3 | using System.Windows.Controls; 4 | 5 | public partial class AutoIncrementColumnsView : UserControl 6 | { 7 | public AutoIncrementColumnsView() 8 | { 9 | this.InitializeComponent(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/ColumnDefinitionsView.xaml: -------------------------------------------------------------------------------- 1 |  11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/ColumnDefinitionsView.xaml.cs: -------------------------------------------------------------------------------- 1 | namespace Gu.Wpf.AutoRowGrid.Demo; 2 | 3 | using System.Windows.Controls; 4 | 5 | public partial class ColumnDefinitionsView : UserControl 6 | { 7 | public ColumnDefinitionsView() 8 | { 9 | this.InitializeComponent(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Gu.Wpf.AutoRowGrid.Demo/ColumnSpanView.xaml: -------------------------------------------------------------------------------- 1 |  9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |