All is fine and dandy on my Win 7 x64 based system running an app built in .NET4.0. However, not so good on the XP SP3 box. Rendering seems to be an issue. Borders are appearing where I dont want them to and dynamically populated items in ItemsControl are switching between values in a combobox! Following is what I have tried so far.
Ive been going through this question and tried to debug further.
- Turn off hardware acceleration off on the desktop properties. (didnt seem to make any difference)
- Add registry entry to turn off hardware acceleration (didnt seem to make any difference)
Add the following code on MainWindow.Xaml.Cs:
protected override void OnSourceInitialized(EventArgs e) { var hwndSource = PresentationSource.FromVisual(this) as HwndSource; if (hwndSource != null) { hwndSource.CompositionTarget.RenderMode = RenderMode.SoftwareOnly; _log.Debug("successfully set render mode to software");
_log.Debug("WPF Tier = {0}", RenderCapability.Tier / 0x10000); } base.OnSourceInitialized(e); }
Log shows that the Tier is 0. This XP SP3 box seems to have DirectX 9.0c. 4. Added the following code to App.xaml.cs:
protected override void OnStartup(StartupEventArgs e)
{
RenderOptions.ProcessRenderMode = RenderMode.SoftwareOnly;
}
Im not sure what else to try. Any assistance is welcome!
Thanks,