Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

用于类型“MenuItem”的样式不能应用于类型“Separator” #829

Closed
hyfree opened this issue May 15, 2021 · 0 comments
Closed

Comments

@hyfree
Copy link

hyfree commented May 15, 2021

Describe the bug
A clear and concise description of what the bug is.
新建wpf项目并且引入HandyControl,HandyControl版本=3.1.0

经过测试,此问题在3.0.0版本中未发现,仅在3.1.0中出现该问题

在Menu标签中加入Separator会导致异常

image

Code

<Window
    x:Class="WpfApp3.MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:local="clr-namespace:WpfApp3"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    Title="MainWindow"
    Width="800"
    Height="450"
    mc:Ignorable="d">
    <Grid>
        <Menu>
            <MenuItem />
            <MenuItem />
            <Separator />
            <MenuItem />
            <MenuItem />
        </Menu>

    </Grid>
</Window>

异常

错误	XDG0066	用于类型“MenuItem”的样式不能应用于类型“Separator”。


错误	XDG0062	Baml 流中出现意外记录。尝试添加到不是集合或具有 TypeConverter 的 Path。	

@NaBian NaBian closed this as completed in a24baef May 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant