material-design 相关问题

材料设计是Google针对Android 5.0 Lollipop引入的跨平台和设备的视觉,动作和交互设计指南。

是将 bootstrep 转换为 Material Design 的任何解决方案

我需要帮助我用 html、css 和 bootstrap 设计网站,现在我的客户告诉我不想要 bootstrap 所以是否有任何将 bootstrep 转换为 Material Design 的解决方案 是将 bootstrep 转换为

回答 0 投票 0

Material Design 3“colorSurface”受“colorPrimary”影响

我正在尝试通过设置 colorSurface 属性(如文档中所述)来更改对话框和底部工作表的背景颜色,但是我在运行应用程序时看到的颜色是不同的...

回答 0 投票 0

从主题更改 RaisedButton 的颜色不起作用

我尝试从 themeData 更改我所有 RaisedButtons 的颜色,但它拒绝工作。所有其他属性,例如 fontSize 和 fontWeight 已成功更改。只有文字的颜色

回答 7 投票 0

Material UI 日期选择器是否可以完全访问?

根据可访问性指南,最小可点击区域/可触摸区域应至少为 48px * 48px。 但是在 MUI 日期选择器中,从日历弹出窗口中选择日期时,它不满足这个条件......

回答 0 投票 0

具有透明背景的 BottomAppBar 内的 BottomNavigationView

我一直在将新的(ish)Material BottomAppBar 与标准的 BottomNavigationView 结合起来。我的 xml 是这样的: 我一直在将新的(ish)Material BottomAppBar 与标准的 BottomNavigationView 结合起来。我的xml是这样的: <com.google.android.material.bottomappbar.BottomAppBar android:id="@+id/bottom_bar" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_gravity="bottom" app:contentInsetStart="0dp" app:contentInsetStartWithNavigation="0dp" app:fabAlignmentMode="center"> <com.google.android.material.bottomnavigation.BottomNavigationView android:id="@+id/bottom_navigation" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginStart="0dp" android:layout_marginEnd="0dp" android:background="@android:color/transparent" app:itemTextAppearanceActive="@style/AppTheme.Text.BottomNavText.Active" app:itemTextAppearanceInactive="@style/AppTheme.Text.BottomNavText" app:labelVisibilityMode="labeled" app:menu="@menu/bottom_nav_menu" /> </com.google.android.material.bottomappbar.BottomAppBar> 在以前的版本 - 1.0.0 - 这工作正常,我仍然可以按预期看到 FAB 插图。唯一的小缺点是这个版本的材质组件库没有对底部应用栏的高度效果进行排序,所以栏和上面的内容之间的区别不是很清楚。 当我升级到最新的库时,我相信在撰写本文时是implementation 'com.google.android.material:material:1.1.0-alpha09',我得到了 BottomAppBar 提升效果,但是当我将透明背景应用于 BottomNavigationView 时,我得到了一个非常奇怪的视觉效果,对于我的生活我无法理解。 如果我去掉透明背景色,效果就没有了,但是我失去了 FAB 插图,如下所示: 如果我完全删除底部导航视图子项,而只有 BottomAppBar,我会看到正常的视觉效果,但没有我的导航: 我喜欢: - 一个很好的解决方案,将底部导航视图合并到 BottomAppBar 中,同时保留 1.1.0 版库良好的提升效果,并且在其中有效地包含 BottomNavigationView,因此我保留了该导航组件的所有优点 - 或者解释到底是什么导致了这种奇特的第一海拔效应,最好是解决它的方法 好吧,这个和BottomAppBar没关系。。。后台问题发生在BottomNavigationView不管在什么地方,素材库1.1.0- .... 这是(我认为)最新版本的 BottomNavigationView 的一个错误,如果背景为 null 或 ColorDrawable,它将设置一个可着色的MaterialShapeDrawableBackground 作为其背景...并且当您在 xml 中设置颜色时,它将 是一个 ColorDrawable(包括透明)。这是 BottomNavigationView 代码中的问题: if (getBackground() == null || getBackground() instanceof ColorDrawable) { // Add a MaterialShapeDrawable as background that supports tinting in every API level. ViewCompat.setBackground(this, createMaterialShapeDrawableBackground(context)); } 这一定是你在上面看到的随机阴影形状。 解决方案 解决方法是在 xml 中设置既不是 null 也不是 ColorDrawable 的背景。我创建了自己的 drawable,它只是一个透明的矩形,并将其设置为 BottomNavigationView 背景,它就可以工作了。 background_transparent.xml <?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android" android:padding="10dp" android:shape="rectangle" > <solid android:color="#00000000" /> </shape> 现在更新的 BottomNavigationView xml: <com.google.android.material.bottomnavigation.BottomNavigationView android:id="@+id/bottom_navigation" style="@style/BottomNav" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginStart="0dp" android:layout_marginEnd="0dp" android:background="@drawable/background_transparent" app:itemTextAppearanceActive="@style/AppTheme.Text.BottomNavText.Active" app:itemTextAppearanceInactive="@style/AppTheme.Text.BottomNavText" app:labelVisibilityMode="labeled" app:menu="@menu/bottom_nav_menu" /> 结果: 我遇到了同样的问题,对我来说最简单的一行修复是将 outlineSpotShadowColor 更改为透明。 解决方案... 在您的 xml 文件中,将其添加到 BottomNavigationView outlineSpotShadowColor = "@android:color/transparent" 完整的例子:- <com.google.android.material.bottomnavigation.BottomNavigationView android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/bottomNavigationView" android:layout_marginEnd="20dp" app:labelVisibilityMode="labeled" android:background="@android:color/transparent" android:outlineSpotShadowColor="@color/zxing_transparent" app:menu="@menu/bottom_menu"/>

回答 2 投票 0

如何使布局可组合在 jetpack compose 中具有透明背景

大家好,我正在使用 Layout 可组合项来实现动画抽屉,但是每当我将 Layout 的背景设置为透明时,它就会变成黑色,但如果我提供其他颜色,它们就是

回答 0 投票 0

如何在路由之间运行隐式动画?

在我的应用程序中有多个页面/路由。每个实现页面的小部件在构建方法的根部都有一个脚手架(这在 Flutter 中是习惯的)。 在某些路线上我想隐藏或更改

回答 0 投票 0

召集所有网络奇才:帮助一位研究员追求网络完美

我的网络奇才们! 我,一个谦虚的 Web 开发人员,着手改进我的个人简历网站,该网站使用 resctjs、animejs、JavaScript、CSS 和 HTML 的强大功能构建。 当我试图磨练我的

回答 0 投票 0

android 中的全局样式规则未应用

我有一个普通的 Android 应用程序,无法理解为什么我的全局样式定义没有应用于视图元素。 这是我的文件 res/values/styles.xml: <question vote="0"> <p>我有一个普通的 Android 应用程序,无法理解,为什么我的全局样式定义没有应用于视图元素。</p> <p>这是我的文件<pre><code>res/values/styles.xml</code></pre>:</p> <pre><code>&lt;resources&gt; &lt;style name=&#34;Theme.XXXXX&#34; parent=&#34;Theme.MaterialComponents&#34;&gt; &lt;item name=&#34;android:textAppearance&#34;&gt;@style/Theme.XXXXX.TextAppearance&lt;/item&gt; &lt;/style&gt; &lt;style name=&#34;Theme.XXXXX.TextAppearance&#34; parent=&#34;TextAppearance.MaterialComponents.Body1&#34;&gt; &lt;item name=&#34;android:textSize&#34;&gt;24sp&lt;/item&gt; &lt;/style&gt; &lt;/resources&gt; </code></pre> <p>这是我在清单中全局设置样式的地方:</p> <pre><code>&lt;application android:dataExtractionRules=&#34;@xml/data_extraction_rules&#34; android:fullBackupContent=&#34;@xml/backup_rules&#34; android:icon=&#34;@drawable/ic_launcher&#34; android:label=&#34;@string/app_name&#34; android:supportsRtl=&#34;true&#34; android:theme=&#34;@style/Theme.XXXXX&#34;&gt; </code></pre> <p>这是一个琐碎的活动布局:</p> <p></p> <pre><code>&lt;LinearLayout android:layout_width=&#34;match_parent&#34; android:layout_height=&#34;match_parent&#34; android:orientation=&#34;vertical&#34; android:padding=&#34;@dimen/dialog_padding&#34;&gt; &lt;TextView android:id=&#34;@+id/introduction_overview&#34; android:layout_width=&#34;match_parent&#34; android:layout_height=&#34;wrap_content&#34; android:text=&#34;@string/introduction_overview&#34; /&gt; &lt;LinearLayout android:id=&#34;@+id/introduction_usage&#34; android:layout_width=&#34;match_parent&#34; android:layout_height=&#34;wrap_content&#34; android:orientation=&#34;vertical&#34;&gt; </code></pre> <p>我的期望是TextView“@+id/introduction_overview”继承样式定义中定义的字体大小。然而,情况并非如此。为什么不呢?<em> </em>在我测试时,我将显式样式</p><code>android:textAppearance=&#34;@style/Theme.XXXXX.TextAppearance&#34;</code><p>添加到<pre><code>TextView</code></pre>。行得通,字体大小确实得到了应用。但我不想为我所有的视图元素设置单独的样式!这就是全局样式定义的目的!<pre> </pre>我看不出在哪里可以覆盖我自己的样式定义。或其他样式定义的任何显式应用。这是一个简单的应用程序。</p> <p>有谁知道我可能会检查什么,我可能需要更改什么?</p> <p> </p></question>

回答 0 投票 0

Flutter:如何使卡片可点击?

我只有一个简单的卡片,比如 new Card(child: new Text('My cool card')),我希望能够点击它的任何地方来运行一些功能,除了卡片没有 onPressed 方法。我可以...

回答 11 投票 0

如何在 Material UI 中将鼠标悬停在它上面时放大卡片大小?

我正在使用 Material UI,并希望在将鼠标悬停在卡片上时放大它,如下所示 我应该如何实现这一目标? 我已经使用了 raised 属性,但这不是我想要的。我还看到了一个人

回答 3 投票 0

Android TextInputLayout 和 TextInputEditText 光标颜色

我想更改光标(或插入符号)颜色,就像在这个堆栈溢出问题中一样,但是在材料 3 中。 我想更改光标(或插入符号)颜色,就像在这个堆栈溢出问题中一样,但是在 Material 3 中。 <com.google.android.material.textfield.TextInputLayout android:id="@+id/brands_input_layout" style="@style/Widget.Material3.TextInputLayout.FilledBox.ExposedDropdownMenu.Honk" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_margin="@dimen/size_medium" android:paddingEnd="44dp" android:theme="@style/Widget.Material3.TextInputLayout.FilledBox.ExposedDropdownMenu.Honk" app:layout_constraintEnd_toStartOf="@id/hide_show_brands_icon" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent" tools:ignore="RtlSymmetry"> <com.google.android.material.textfield.TextInputEditText android:id="@+id/description_input" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/colorPrimary" android:imeOptions="actionDone" android:inputType="textCapSentences" /> </com.google.android.material.textfield.TextInputLayout> 这是我的主题文件: <style name="Widget.Material3.TextInputLayout.FilledBox.ExposedDropdownMenu.Honk"> <item name="boxStrokeColor">@color/textDropdownBoxStrokeColor</item> <item name="hintTextColor">@color/textDropdownBoxStrokeColor</item> <item name="colorControlActivated">@color/textDropdownBoxStrokeColor</item> <item name="endIconTint">@color/dropdown_menu_arrow</item> </style> 我已经试过了: <style name="ThemeOverlay.SmartHabit.TextInputEditText.FilledBox.Dense" parent="ThemeOverlay.Material3.TextInputEditText.FilledBox.Dense"> <item name="colorControlActivated">@color/colorSecondary</item> </style> <com.google.android.material.textfield.TextInputEditText android:id="@+id/description_input" style="@style/ThemeOverlay.SmartHabit.TextInputEditText.FilledBox.Dense" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/colorPrimary" android:imeOptions="actionDone" android:inputType="textCapSentences" /> 我也已经试过了: <style name="ThemeOverlay.SmartHabit.TextInputEditText.FilledBox.Dense" parent="ThemeOverlay.Material3.TextInputEditText.FilledBox.Dense"> <item name="colorPrimary">@color/colorSecondary</item> </style> <com.google.android.material.textfield.TextInputEditText android:id="@+id/description_input" style="@style/ThemeOverlay.SmartHabit.TextInputEditText.FilledBox.Dense" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/colorPrimary" android:imeOptions="actionDone" android:inputType="textCapSentences" /> 编辑: 根据Material 3 Documentation,我已经尝试这样做了,但是没有用: <com.google.android.material.textfield.TextInputEditText android:id="@+id/description_input" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/colorPrimary" android:imeOptions="actionDone" android:inputType="textCapSentences" app:cursorColor="@color/myColor" />

回答 0 投票 0

更改按钮文本而不更改按钮宽度?

考虑以下代码: val saveInProgress = false // 实际上可能来自 ViewModel 按钮(onClick = {}){ val text = if(saveInProgress) "保存" else "..." ...

回答 1 投票 0

如何在 XML 中定义 MaterialShapeDrawable - Android

我想在我的 Android 项目的 /res/drawable 中的 XML 文件中使用漂亮的 MaterialShapeDrawable,但是每当我尝试将其定义为 /layout/XML 中的视图时,我都会看到: 元素 com.google.andr...

回答 0 投票 0

向 mui 主题添加自定义调色板会出现语法错误

我尝试简单地向我的 MUI 主题添加一个新的调色板并得到以下类型错误: 有什么帮助或提示吗?

回答 2 投票 0

如何在特定屏幕上隐藏 flutter 中的持久导航栏?

我在 flutter 中使用持久性导航栏包。包裹。它试图使用 getx 隐藏它。就像当我导航到仪表板时,我调用 getx 函数将导航设置为 true,当我重新...

回答 0 投票 0

白色在卡片小部件中显示不正确

我在一个屏幕上都使用了卡片小部件和容器,并在两个屏幕中都设置了白色,它在容器中显示正确,但在卡片小部件中显示不正确。我附上了截图。在这个

回答 1 投票 0

使用 SMUI(svelte material ui),我没有成功组合 2 个组件(抽屉和顶部应用栏)

我想要一个标准布局,它有一个顶部应用栏(图中红色)和一个抽屉(左边是一个打开关闭的抽屉) 问题是顶部应用栏应该是固定的,但是主体组件(那个

回答 0 投票 0

SwitchPreference 没有明显切换(没有颜色切换,没有动画)API >=23

所以我最近对我的应用程序做了一个小更新,旧 API 的用户(等于较低的 23)抱怨 PreferenceSwitch 适用于逻辑,但没有明显的迹象表明它已被切换。 API 超过 ...

回答 0 投票 0

如何在 wpf 中重新模板材料设计模板

所以我想做的是更改材料设计中的控件。 所以这就是我所做的,我为扩展器控件创建了一个控件模板 所以我想做的是更改材料设计中的控件。 这就是我所做的,我为扩展器控件创建了一个控件模板 <Expander Template="{StaticResource ExpanderTemplate1}"> </Expander> 这里是我的资源字典,控制模板在里面 <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:wpf="clr-namespace:MaterialDesignThemes.Wpf;assembly=MaterialDesignThemes.Wpf"> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Light.xaml" /> <ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Defaults.xaml" /> <ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Primary/MaterialDesignColor.BlueGrey.xaml" /> </ResourceDictionary.MergedDictionaries> <Style x:Key="MaterialDesignExpanderToggleButton" TargetType="{x:Type ToggleButton}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type ToggleButton}"> <Border Background="Transparent"> <wpf:PackIcon x:Name="ExpandPath" Foreground="{TemplateBinding Foreground}" Height="24" Kind="ChevronDown" Opacity="0.38" RenderTransformOrigin="0.5 0.5" Width="24"> <wpf:PackIcon.RenderTransform> <RotateTransform x:Name="ExpandPathRotateTransform"/> </wpf:PackIcon.RenderTransform> </wpf:PackIcon> </Border> </ControlTemplate> </Setter.Value> </Setter> </Style> <Style x:Key="MaterialDesignHorizontalHeaderStyle" TargetType="{x:Type ToggleButton}"> <Setter Property="Background" Value="Transparent"/> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type ToggleButton}"> <Border Background="{TemplateBinding Background}" Padding="{Binding (wpf:ExpanderAssist.HorizontalHeaderPadding), RelativeSource={RelativeSource AncestorLevel=1, AncestorType={x:Type Expander}}}"> <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="*"/> <ColumnDefinition Width="16"/> <ColumnDefinition Width="Auto"/> </Grid.ColumnDefinitions> <ContentPresenter ContentStringFormat="{TemplateBinding ContentStringFormat}" ContentTemplate="{TemplateBinding ContentTemplate}" Grid.Column="0" Content="{TemplateBinding Content}" ContentTemplateSelector="{TemplateBinding ContentTemplateSelector}" VerticalAlignment="Center"/> <ToggleButton x:Name="ExpanderButton" Grid.Column="2" Foreground="{TemplateBinding Foreground}" IsChecked="{Binding IsChecked, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" RenderTransformOrigin="0.5 0.5" VerticalAlignment="Center"> <ToggleButton.Style> <Style BasedOn="{StaticResource MaterialDesignExpanderToggleButton}" TargetType="{x:Type ToggleButton}"> <Style.Triggers> <DataTrigger Binding="{Binding ExpandDirection, RelativeSource={RelativeSource AncestorLevel=1, AncestorType={x:Type Expander}}}" Value="Up"> <Setter Property="RenderTransform"> <Setter.Value> <RotateTransform Angle="180"/> </Setter.Value> </Setter> </DataTrigger> </Style.Triggers> </Style> </ToggleButton.Style> </ToggleButton> </Grid> </Border> </ControlTemplate> </Setter.Value> </Setter> </Style> <Style x:Key="MaterialDesignVerticalHeaderStyle" TargetType="{x:Type ToggleButton}"> <Setter Property="Background" Value="Transparent"/> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type ToggleButton}"> <Border Background="{TemplateBinding Background}" Padding="{Binding (wpf:ExpanderAssist.VerticalHeaderPadding), RelativeSource={RelativeSource AncestorLevel=1, AncestorType={x:Type Expander}}}"> <Grid> <Grid.RowDefinitions> <RowDefinition Height="Auto"/> <RowDefinition Height="16"/> <RowDefinition Height="*"/> </Grid.RowDefinitions> <ToggleButton x:Name="ExpanderButton" Foreground="{TemplateBinding Foreground}" IsChecked="{Binding IsChecked, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" RenderTransformOrigin="0.5 0.5" Grid.Row="0" VerticalAlignment="Center"> <ToggleButton.Style> <Style BasedOn="{StaticResource MaterialDesignExpanderToggleButton}" TargetType="{x:Type ToggleButton}"> <Style.Triggers> <DataTrigger Binding="{Binding ExpandDirection, RelativeSource={RelativeSource AncestorLevel=1, AncestorType={x:Type Expander}}}" Value="Left"> <Setter Property="RenderTransform"> <Setter.Value> <RotateTransform Angle="90"/> </Setter.Value> </Setter> </DataTrigger> <DataTrigger Binding="{Binding ExpandDirection, RelativeSource={RelativeSource AncestorLevel=1, AncestorType={x:Type Expander}}}" Value="Right"> <Setter Property="RenderTransform"> <Setter.Value> <RotateTransform Angle="-90"/> </Setter.Value> </Setter> </DataTrigger> </Style.Triggers> </Style> </ToggleButton.Style> </ToggleButton> <ContentPresenter ContentStringFormat="{TemplateBinding ContentStringFormat}" ContentTemplate="{TemplateBinding ContentTemplate}" Content="{TemplateBinding Content}" ContentTemplateSelector="{TemplateBinding ContentTemplateSelector}" Grid.Row="2" VerticalAlignment="Center"/> </Grid> </Border> </ControlTemplate> </Setter.Value> </Setter> </Style> <ControlTemplate x:Key="ExpanderTemplate1" TargetType="{x:Type Expander}"> <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"> <DockPanel Background="{TemplateBinding Background}"> <ToggleButton x:Name="HeaderSite" Background="{TemplateBinding}" BorderThickness="0" ContentStringFormat="{TemplateBinding HeaderStringFormat}" ContentTemplate="{TemplateBinding HeaderTemplate}" Cursor="Hand" Content="{TemplateBinding Header}" ContentTemplateSelector="{TemplateBinding HeaderTemplateSelector}" DockPanel.Dock="Top" Foreground="{TemplateBinding Foreground}" Focusable="False" TextElement.FontSize="{TemplateBinding}" IsTabStop="False" IsChecked="{Binding IsExpanded, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" Opacity="0.87"/> <Border x:Name="ContentSite"> <Border.LayoutTransform> <TransformGroup> <ScaleTransform x:Name="ContentSiteScaleTransform"/> <RotateTransform Angle="{Binding ExpandDirection, Converter={StaticResource ExpanderRotateAngleConverter}, RelativeSource={RelativeSource AncestorType={x:Type Expander}}}"/> </TransformGroup> </Border.LayoutTransform> <Grid x:Name="ContentPanel" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"> <Grid.LayoutTransform> <RotateTransform Angle="{Binding ExpandDirection, ConverterParameter=-1, Converter={StaticResource ExpanderRotateAngleConverter}, RelativeSource={RelativeSource AncestorType={x:Type Expander}}}"/> </Grid.LayoutTransform> <ContentPresenter x:Name="PART_Content" ContentStringFormat="{TemplateBinding ContentStringFormat}" ContentTemplate="{TemplateBinding ContentTemplate}" ContentTemplateSelector="{TemplateBinding ContentTemplateSelector}" Focusable="False" Visibility="Collapsed"/> </Grid> </Border> </DockPanel> </Border> <ControlTemplate.Triggers> <Trigger Property="ExpandDirection" Value="Right"> <Setter Property="DockPanel.Dock" TargetName="HeaderSite" Value="Left"/> <Setter Property="Style" TargetName="HeaderSite" Value="{StaticResource MaterialDesignVerticalHeaderStyle}"/> </Trigger> <Trigger Property="ExpandDirection" Value="Left"> <Setter Property="DockPanel.Dock" TargetName="HeaderSite" Value="Right"/> <Setter Property="Style" TargetName="HeaderSite" Value="{StaticResource MaterialDesignVerticalHeaderStyle}"/> </Trigger> <Trigger Property="ExpandDirection" Value="Up"> <Setter Property="DockPanel.Dock" TargetName="HeaderSite" Value="Bottom"/> <Setter Property="Style" TargetName="HeaderSite" Value="{StaticResource MaterialDesignHorizontalHeaderStyle}"/> </Trigger> <Trigger Property="ExpandDirection" Value="Down"> <Setter Property="DockPanel.Dock" TargetName="HeaderSite" Value="Top"/> <Setter Property="Style" TargetName="HeaderSite" Value="{StaticResource MaterialDesignHorizontalHeaderStyle}"/> </Trigger> </ControlTemplate.Triggers> </ControlTemplate> </ResourceDictionary> 我收到错误“错误 XDG0062 对象引用未设置到对象的实例” 这是原始的模板,我似乎找不到任何解释如何更改材料设计控件的控制模板的内容。

回答 0 投票 0

© www.soinside.com 2019 - 2024. All rights reserved.