随笔分类 -  Prism

摘要:这是Prism框架开发者写的一个demo,我觉得有趣,就发出来让大家看看 <StackPanel> <StackPanel Orientation="Horizontal"> <Button x:Name="AnimationButton" Click="AnimationButton_Click" 阅读全文
posted @ 2024-08-04 18:43 孤沉 阅读(17) 评论(0) 推荐(0)
摘要:在WPF的 <Window.Resources>中 可以直接写 <ResourceDictionary Source="../Styles/ContentDemoStyle.xaml"/>, 也可以包裹一层, <ResourceDictionary> <ResourceDictionary.Merg 阅读全文
posted @ 2024-07-09 23:00 孤沉 阅读(31) 评论(0) 推荐(0)
摘要:1、先介绍TriggerParameterPath的AddedItems方法吧 设计场景 点击用户名罗列出用户的详细信息,或者点击配方罗列出配方的详细信息 在WPF的官方例子中,它是这样写的 有上下两层,点击第一行的用户名,第二行罗列对应的信息 <!-- 可以用来罗列信息,不同的值对应不同的信息 - 阅读全文
posted @ 2024-07-09 22:33 孤沉 阅读(66) 评论(0) 推荐(0)
摘要:前提:我的WPF程序在进入主程序之前显示登录界面 此时不想登录,点击退出的时候报错了 报错提示 An exception occurred while initializing module 'ShellModule'. - The exception message was: An excepti 阅读全文
posted @ 2024-04-22 21:27 孤沉 阅读(371) 评论(0) 推荐(0)
摘要:1、现在有多个程序集 lib1、lib2、lib3、lib4 每个程序集都有类标注了特性ScanningAttribute 特性的代码是 [AttributeUsage(AttributeTargets.Class, Inherited = false)] public class Scanning 阅读全文
posted @ 2024-03-21 10:24 孤沉 阅读(13) 评论(0) 推荐(0)
摘要:上次说到自动扫描的两种方式,接下来,先看看第一种方法,接口的注册 protected override void RegisterTypes(IContainerRegistry containerRegistry) { TextDemo textDemo = new TextDemo(contai 阅读全文
posted @ 2024-03-10 15:07 孤沉 阅读(20) 评论(0) 推荐(0)
摘要:今天,我向大家介绍一款WPF后台框架,以及,它的用法。 官网 https://prismlibrary.com/ Prism 框架是一个用于构建松耦合、可维护且可测试的 WPF 和 Xamarin.Forms 应用程序的开源框架。在 Prism 中,IContainerRegistry 接口用于注册 阅读全文
posted @ 2024-03-10 13:58 孤沉 阅读(546) 评论(0) 推荐(0)
摘要:在java中springboot的配置应用了自动扫描 @ComponentScan(value = {"com.example", "com.fox"}) 而对于Asp.Net Core 可以使用Scrutor static void Main(string[] args) { var collec 阅读全文
posted @ 2024-03-09 14:22 孤沉 阅读(53) 评论(0) 推荐(0)
摘要:Rules.Default..WithoutFastExpressionCompiler()报错 说没有找到容器 1、查看Prism.Wpf源码 获取DryIoc容器规则 2、证明项目中出现了另外一个DryIoc容器,它的规则不适用于Prism 3、排查项目中其他DryIoc容器,卸载掉 阅读全文
posted @ 2023-03-08 15:34 孤沉 阅读(173) 评论(0) 推荐(0)