ConfigureWindow, CreateWindow and CreateGC now give good format size to buffer, fixed some tests