Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 186285 - vice 1.21 creates application window of wrong size under certain circumstances
Summary: vice 1.21 creates application window of wrong size under certain circumstances
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Games (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Games
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-07-23 01:24 UTC by groepaz
Modified: 2007-10-31 03:24 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
window size patch (fabrizio-1.21-donotresizeatsizeallocate.diff.gz_[eyFywa].21-donotresizeatsizeallocate.diff,2.26 KB, patch)
2007-07-23 01:26 UTC, groepaz
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description groepaz 2007-07-23 01:24:10 UTC
under certain circumstances the emulators from the vice package will start with a window which is much too small. this seems to be somehow related to KDE and GTK, we couldnt quite find out the exact problem. i worked a bit at the problem with upstream, and this is what i recieved:

"I switched to KDE and sometimes got a wrong screen size. It happens 
erratically, sometimes it works and sometimes it shows a window 1 pixel 
high. And not even switching on then of HW scale restores it to the 
normal size.

I have strong suspects on size_allocate, in x11ui.c. This handles a GTK 
signal, size-allocate (which would better stay unhandled, IMHO), which 
sometimes is fired with spurious values. size_allocate changes the size 
of the window by invoking video_canvas_redraw_size."

...

"When a GTK widget needs a particular size (and this is the case of the 
main screen of the emulator), gtk_widget_set_size_request is called. 
This makes the widget ask its container for a size. When the container 
actually acknowledges the size request, it sends a size-allocate signal 
with the actual size.

According to GTK docs, "in some strange cases a widget may be allocated 
less than its requested size". And this is what sometimes happens when 
the KDE WM is running: a size-allocate of just 8x1 is sent. The good one 
is sent, only later.

What (unpatched) VICE does is saying: "OK, so I'll request a smaller 
size". And this causes the small window.

If the above description is true, the attached patch should solve the 
problem."

so here is the patch, and it works great for me (and others)
Comment 1 groepaz 2007-07-23 01:26:30 UTC
Created attachment 125713 [details, diff]
window size patch

this patch fixes the problem with wrong window size. it does NOT include the libX11 patch however, so that needs to be applied seperatly aswell.
Comment 2 Mr. Bones. (RETIRED) gentoo-dev 2007-10-30 19:18:50 UTC
Is this patch still needed with 1.22?
Comment 3 groepaz 2007-10-31 02:24:40 UTC
no, 1.22 doesnt need any of the 1.21 related patches
Comment 4 Mr. Bones. (RETIRED) gentoo-dev 2007-10-31 03:24:09 UTC
Thanks!