[PyQt] PyQt-based Tetr*s

Matt Newell newellm at blur.com
Tue Mar 25 23:50:48 GMT 2008


On Tuesday 25 March 2008 16:29:36 Joshua Bronson wrote:
> I am new to Qt, and I just whipped up a PyQt-based implementation of
> Tetr*s. I am getting quite a bit of padding between the edges of the window
> and the edges of the area in which the blocks are drawn, and I can't seem
> to figure out how to set this to zero.
> To see this, svn export the following files:
> http://aipytris.googlecode.com/svn/trunk/aipytris/g.py
> http://aipytris.googlecode.com/svn/trunk/aipytris/piece.py
> http://aipytris.googlecode.com/svn/trunk/aipytris/observable.py
> http://aipytris.googlecode.com/svn/trunk/aipytris/boardqt.py
>
> Then run boardqt.py.
>
> Does anyone know how to get rid of this padding?
>
> Thanks,
> Josh

Call setMargin( pixels ) on your layout.

Matt


More information about the PyQt mailing list