我正在使用Windowsformhost派生的Ipaddress控件.但是当我向下滚动我的窗口小部件时,它漂浮在窗口小部件外部,任何解决方案都会令人赞赏. [英] I Am Using Ipaddress Control Derived From Windowsformhost. But When I Scroll Down My Widget It Is Floating Outside Of Widget.Any Solution Will Be Appreciate.

查看:172
本文介绍了我正在使用Windowsformhost派生的Ipaddress控件.但是当我向下滚动我的窗口小部件时,它漂浮在窗口小部件外部,任何解决方案都会令人赞赏.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

xmlns:ipBox ="clr-namespace:IPAddressControlLib; assembly = IPAddressControlLib"

xmlns:ipBox="clr-namespace:IPAddressControlLib;assembly=IPAddressControlLib"

<local:WindowsFormsHostExtended Grid.Column="1" Grid.Row="1" Margin="40,15,3,0" Width="150" VerticalAlignment="Stretch" HorizontalAlignment="Stretch" ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto">
          <ipBox:IPAddressControl x:Name="IPAddress" TextChanged="IPAddress_TextChanged" />
      </local:WindowsFormsHostExtended>

推荐答案

这是WPF/WinForms互操作的一个众所周知的问题,通常称为空域"问题.添加到WPF窗口的WinForms控件有严格的限制:
This is a well-known problem with WPF/WinForms interop, often referred to as the "airspace" issue. WinForms controls added to a WPF window have severe limitations:


查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆