{"id":19742623,"url":"https://github.com/angrycarrot789/wpf-codegen-converter","last_synced_at":"2026-05-15T10:01:55.281Z","repository":{"id":187851313,"uuid":"677693242","full_name":"AngryCarrot789/wpf-codegen-converter","owner":"AngryCarrot789","description":"Uses a C# compiler to generate a WPF converter from a script, to save having to create a class for each converter","archived":false,"fork":false,"pushed_at":"2023-08-12T10:31:49.000Z","size":17,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-10T20:19:33.679Z","etag":null,"topics":["csharp","wpf"],"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/AngryCarrot789.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":"2023-08-12T10:14:07.000Z","updated_at":"2023-08-12T12:28:49.000Z","dependencies_parsed_at":"2023-08-12T11:28:05.678Z","dependency_job_id":"680191d4-f80d-4470-b70c-5ea7f24b71ec","html_url":"https://github.com/AngryCarrot789/wpf-codegen-converter","commit_stats":null,"previous_names":["angrycarrot789/wpfcodegenconverter"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngryCarrot789%2Fwpf-codegen-converter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngryCarrot789%2Fwpf-codegen-converter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngryCarrot789%2Fwpf-codegen-converter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngryCarrot789%2Fwpf-codegen-converter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AngryCarrot789","download_url":"https://codeload.github.com/AngryCarrot789/wpf-codegen-converter/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241072628,"owners_count":19904811,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["csharp","wpf"],"created_at":"2024-11-12T01:32:51.663Z","updated_at":"2026-05-15T10:01:50.235Z","avatar_url":"https://github.com/AngryCarrot789.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# WPFCodeGenConverter\nUses a C# compiler to generate a WPF converter from a script, to save having to create a class for each converter\n\nThis is purely just a demo of how to do it. But the added hassle of having to use special character codes like `\u0026quot;` instead of `\"` and not \nbeing able to use `using` statements (and having to directly access all types like `System.Windows.Visibility` directly)\nalmost make it not as convenient to use.\n\nThough 1 good usage I guess could be an invert bool converter, but you could just make a singleton bool inverter converter that you use across your\nentire project\n\n# DynamicCodeConverter\nTo use it in XAML, you just set a binding's converter to `Converter={c:DynamicCodeConverter}`. The class extends `MarkdownExtension`, which means that you \ndon't need to provide a specific instance; it's automatically created by XAML and also the class itself (via the `ProvideValue` method)\n\nAnd then you provide your code in the `ConverterParameter` part of the binding. If the `ConverterParameter` is the last part of the binding expression, you can\nencapsulate the script in single quotes (`'like this'`), and XAML will tolerate it\n\nCurrently, you can't convert back from the value. I was thinking of maybe using a TypeConverter or something along those lines to\nallow more specific properties to be set... but then you lose the luxury of binding AFAIK. I couldn't get binding to work outside of the built in\n`Binding`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangrycarrot789%2Fwpf-codegen-converter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fangrycarrot789%2Fwpf-codegen-converter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangrycarrot789%2Fwpf-codegen-converter/lists"}