1 /*---------------------------------------------------------------------\
3 | __ __ ____ _____ ____ |
4 | \ \ / /_ _/ ___|_ _|___ \ |
5 | \ V / _` \___ \ | | __) | |
6 | | | (_| |___) || | / __/ |
7 | |_|\__,_|____/ |_| |_____| |
9 | contributed Qt widgets |
11 \----------------------------------------------------------------------/
13 File: QY2LayoutUtils.h
15 Author: Stefan Hundhammer <sh@suse.de>
17 These are pure Qt functions - they can be used independently of YaST2.
22 #ifndef QY2LayoutUtils_h
23 #define QY2LayoutUtils_h
29 * Add vertical stretchable space.
31 QWidget * addVStretch( QWidget * parent );
34 * Add horizontal stretchable space.
36 QWidget * addHStretch( QWidget * parent );
39 * Add a fixed height vertical space
41 QWidget * addVSpacing( QWidget * parent, int height = 8 );
44 * Add a fixed height horizontal space
46 QWidget * addHSpacing( QWidget * parent, int width = 8 );
49 * Limit a QSize to what is available on the same screen as 'widget'.
51 QSize limitToScreenSize( const QWidget * widget, const QSize & desiredSize );
52 QSize limitToScreenSize( const QWidget * widget, int width, int height );
54 #endif // ifndef QY2LayoutUtils_h