WPF 解决拼接屏全屏的问题

需求: 8块1920*1080屏幕拼接

橙色4个框每个框(1920*1080)拼接成一个1920*1080

红色4个框每个框(1920*1080)拼接成一个1920*1080

橙色和红色作为display 2屏 拼接3840*1080

蓝色框为主屏(1920*1080) 作为display 1屏

//获取窗口句柄
var handle = new WindowInteropHelper(this).Handle;
//获取所有窗口 从左开始 第0个屏 , 第1个屏(主屏)
System.Windows.Forms.Screen[] screen = System.Windows.Forms.Screen.AllScreens;
//屏幕的x位置
this.Left = screen[0].Bounds.X;
//屏幕的y位置
this.Top = screen[0].Bounds.Y;
this.Height = screen[0].Bounds.Height;
this.Width = screen[0].Bounds.Width;

 

原文地址:https://www.cnblogs.com/luquanmingren/p/7716349.html