This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Resizing windows

Tags: None
(comma "," separated)
Daniel_Boff
Registered Member
Posts
82
Karma
0

Resizing windows

Fri Oct 16, 2009 3:46 pm
why is resizing windows with kwin or other wm's so slow: the content of the window is always a little bit behind the window itself. the resizing behaviour in mac os or windows is different (i think you know what i mean? )
can resizing in kde ever get like in windows, or why do we get this behaviour?
User avatar
Hans
Administrator
Posts
3304
Karma
24
OS

Re: Resizing windows

Fri Oct 16, 2009 4:20 pm
Depends on what you mean with "slow", but this might help: http://userbase.kde.org/GPU-Performance ... _is_choppy


Problem solved? Please click on "Accept this answer" below the post with the best answer to mark your topic as solved.

10 things you might want to do in KDE | Open menu with Super key | Mouse shortcuts
Daniel_Boff
Registered Member
Posts
82
Karma
0

Re: Resizing windows

Fri Oct 16, 2009 4:36 pm
no that's not what i mean. the window itself resizes normally, i just that the content inside the window is always "behind" the window. it's less than a second, but still noticeable.
it seems as if the function thats responsible for resizing the window itself isn't synced with the one that resizes the content.
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS

Re: Resizing windows

Fri Oct 16, 2009 10:22 pm
The reason for the lack of "sync" is because the window decorations and the contents of the window are created by two seperate applications, communicating with a third to get it displayed.

The window decoration is provided by the Window Manager which uses the information provided by the X server to draw decorations around the windows and asks X to perform certain functions for it when requested ( say minimize the window )

The contents of the window are provided by the application themselves. When you begin to resize the window the X server informs the application that its window is having its size modified. Once you finish resizing X tells the application the resize is complete and the window is redrawn.

If the application redrew every time you changed the size of the window then the resizing would be very choppy and your system would experience high CPU / GPU load as every time the window size is changed by 1 pixel it must be redrawn.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
Daniel_Boff
Registered Member
Posts
82
Karma
0

Re: Resizing windows

Fri Oct 16, 2009 11:23 pm
okay i see, but normally when i resize a window the content resizes before i release the mouse button. so there has to be an event which triggers the application to resize the window:

wouldn't it be possible to use the same event for resizing decorations?

this way the whole window (deco + content) would be out of "sync" with the mouse cursor, but the window wouldn't look so "loose" during resizing, and it would (at least in my opinion) look much better, than it does right now...
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS

Re: Resizing windows

Fri Oct 16, 2009 11:37 pm
I forgot one detail - applications will usually repaint themselves after a small delay when resizing so as not to appear inactive / frozen.

You may find that Qt 4.6 will offer some fixes for your issue.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]