|  | @@ -700,6 +700,7 @@ laScreen* la_EnsureScreen(char* Name, int mmw, int mmh, int x, int y, int w, int
 | 
	
		
			
				|  |  |      strSafeSet(&s->Name,Name);
 | 
	
		
			
				|  |  |      strSafePrint(&s->Description,"%dmm x %dmm with %dx%d ~%ddpi",mmw,mmh,w,h,dpi); s->RoughDPI=dpi;
 | 
	
		
			
				|  |  |      s->x=x;s->y=y;s->w=w;s->h=h;
 | 
	
		
			
				|  |  | +    laNotifyUsers("la.user_preferences.screens");
 | 
	
		
			
				|  |  |      return s;
 | 
	
		
			
				|  |  |  }
 | 
	
		
			
				|  |  |  void la_RemoveScreen(laScreen*s){
 | 
	
	
		
			
				|  | @@ -758,7 +759,17 @@ int la_GetDPI(Window* root_win){
 | 
	
		
			
				|  |  |  }
 | 
	
		
			
				|  |  |  #endif
 | 
	
		
			
				|  |  |  #ifdef _WIN32
 | 
	
		
			
				|  |  | +typedef struct laWin32MonitorEnumData {
 | 
	
		
			
				|  |  | +    int id;
 | 
	
		
			
				|  |  | +}laWin32MonitorEnumData;
 | 
	
		
			
				|  |  | +static BOOL CALLBACK la_Win32MonitorEnum(HMONITOR hMon, HDC hdc, LPRECT lprcMonitor, LPARAM pData){
 | 
	
		
			
				|  |  | +    laWin32MonitorEnumData* data = pData; char str[32]; sprintf(str, "Display %d", data->id); data->id++;
 | 
	
		
			
				|  |  | +    laScreen* s = la_EnsureScreen(str, 0,0, lprcMonitor->left, lprcMonitor->top, lprcMonitor->right-lprcMonitor->left, lprcMonitor->bottom-lprcMonitor->top, 0);
 | 
	
		
			
				|  |  | +    return TRUE;
 | 
	
		
			
				|  |  | +}
 | 
	
		
			
				|  |  |  int la_GetDPI(HWND win){
 | 
	
		
			
				|  |  | +    laWin32MonitorEnumData data = { 0 };
 | 
	
		
			
				|  |  | +    EnumDisplayMonitors(0, 0, la_Win32MonitorEnum, (LPARAM)&data);
 | 
	
		
			
				|  |  |      return GetDpiForWindow(win);
 | 
	
		
			
				|  |  |      return 144;
 | 
	
		
			
				|  |  |  }
 | 
	
	
		
			
				|  | @@ -1695,6 +1706,10 @@ void la_CommandResizeWindow(SYSWINDOW hwnd, int x, int y, int w, int h){
 | 
	
		
			
				|  |  |      window->W = rcw.right - rcw.left;
 | 
	
		
			
				|  |  |      window->H = rcw.bottom - rcw.top;
 | 
	
		
			
				|  |  |      window->X = rcw.left; window->Y = rcw.top;
 | 
	
		
			
				|  |  | +    if (MAIN.AutoSwitchColorSpace) {
 | 
	
		
			
				|  |  | +        laScreen* s = laGetWindowScreen(window);
 | 
	
		
			
				|  |  | +        if (s) { window->OutputColorSpace = s->ColorSpace; }
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  |  #endif
 | 
	
		
			
				|  |  |  #ifdef __linux__
 | 
	
		
			
				|  |  |      XWindowAttributes attr;
 | 
	
	
		
			
				|  | @@ -2867,6 +2882,8 @@ void la_WindowDefDraw(laWindow *w, laBoxedTheme *bt){
 | 
	
		
			
				|  |  |      laPanel *p, *NextP;
 | 
	
		
			
				|  |  |      laLayout *l = w->CurrentLayout;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | +    if (!w->CH || !w->CW) return;
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  |      la_ClearUnusedFramebuffers(w);
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      tnsDrawToScreen();
 | 
	
	
		
			
				|  | @@ -7487,6 +7504,8 @@ LRESULT CALLBACK LA_WindowProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lp
 | 
	
		
			
				|  |  |              break;
 | 
	
		
			
				|  |  |          case SC_KEYMENU:
 | 
	
		
			
				|  |  |              return 0;
 | 
	
		
			
				|  |  | +        case SC_MINIMIZE:
 | 
	
		
			
				|  |  | +            break;
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          break;
 | 
	
		
			
				|  |  |      case WM_SIZE:
 |