Launching WPF Window from F# interactive, keyboard input broken

随声附和 提交于 2019-12-05 05:10:03

问题


A GUI was developed in WPF, and when launching it as a standalone application, all editable fields (datagrid columns, textboxes, etc.) work fine.

However, when instantiating the window from FSI, no individual key characters are registered when typing. The interesting thing is copy/paste and highlight + delete all work.

The window is being initialized like this:

public void ShowGui()
{
    guiWindow = new MainWindow(Bench, this);
    guiWindow.Show();
    guiWindow.Activate();     
}

this function is then being invoked in FSI

All other functionality seems to work (button clicks, switching tabs), but any element that takes key input will not register the typed characters.

来源:https://stackoverflow.com/questions/37175827/launching-wpf-window-from-f-interactive-keyboard-input-broken

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!