Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

Repaint Issue when mixing WPF and WinForms on some PCs

$
0
0

Hello,

I have a strange problem with WPF and WinForms interop when I use scrolling (seems to be another airspace problem):

<Here should be a picture. Since I am new in the forum I cannot post it.>

You can see that the red border is not repainted after I scroll my buttons.

This is my WPF code:

<Border Padding="20"><Border Background="Red" Padding="5"><WindowsFormsHost x:Name="formsHost"><wfdx:LayoutControl x:Name="lc"></wfdx:LayoutControl></WindowsFormsHost></Border></Border>

The buttons are added programatically.

The LayoutControl is from DevExpress and is implemented with WinForms. Thus I have a WPF application which hosts a WinForms Layout Control which contains WinForm buttons.

The repaint issue you can see above only ocurrs in the following conditions:

1. Windows Aero Design is switched on

2. Enable desktop composition is checked (in Performance Options/Visual Effects)

3. Use two screens in "extending" mode

In all other cases the rendering problem does not appear. It also seems to depend on the used PC. I can see the problem with some HP laptops when I met the conditions above but on other laptop types I cannot see it even when all three conditions are met.

Does anyone have an idea what's the problem?

Best regards,

Thomas


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>