Qt 2.x Designer PropertyEditor窗口风格

可能那时候Qt还没有QDockWindow,只贴下关键代码

#include <qvbox.h>
class PropertyEditor : public QVBox
{
public:
    PropertyEditor( QWidget *parent );
};

 

//-------------------------------------------------------
PropertyEditor::PropertyEditor( QWidget *parent )
    : QVBox( parent, 0, WStyle_Customize | WStyle_NormalBorder | WStyle_Title |
   WStyle_StaysOnTop | WStyle_Tool |WStyle_MinMax | WStyle_SysMenu )
{
    setCaption( tr( "Property Editor" ) );
}

 


//-------------------------------------------------------
QVBox* vb = new QVBox( this );
vb->setFrameStyle( QFrame::StyledPanel | QFrame::Sunken );
ws = new QWorkspace( vb );
ws->setScrollBarsEnabled( TRUE );
setCentralWidget( vb );

   
propertyEditor = new PropertyEditor( ws );
propertyEditor->resize( 300, 600 );

 

你可能感兴趣的:(Class,qt,vb)