⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 form3.cpp

📁 这是一个嵌入式linux的GUI源码comdemo.tar.gz 一个QT/Embedded 的控件功能演示源码
💻 CPP
字号:
/****************************************************************************** Form implementation generated from reading ui file 'demo3.ui'**** Created: Sat Jun 26 17:31:47 2004**      by:  The User Interface Compiler (uic)**** WARNING! All changes made in this file will be lost!****************************************************************************/#include "form3.h"#include "form2.h"#include "form1.h"#include "ucdragon.xpm"#include <qcombobox.h>#include <qdial.h>#include <qlabel.h>#include <qlcdnumber.h>#include <qprogressbar.h>#include <qpushbutton.h>#include <qslider.h>#include <qlayout.h>#include <qvariant.h>#include <qtooltip.h>#include <qwhatsthis.h>#include <qimage.h>#include <qpixmap.h>/*  *  Constructs a Form3 which is a child of 'parent', with the  *  name 'name' and widget flags set to 'f'  */Form3::Form3( QWidget* parent,  const char* name, WFlags fl )    : QWidget( parent, name, fl ){   QPixmap image0( ( const char** ) image0_data );    if ( !name )	setName( "Form3" );    resize( 227, 312 );     setMaximumSize( QSize( 240, 320 ) );    setCaption( tr( "Form3" ) );    ProgressBar1 = new QProgressBar( this, "ProgressBar1" );    ProgressBar1->setGeometry( QRect( 20, 220, 201, 31 ) );     ProgressBar1->setProgress( 50 );    PushButton6_2 = new QPushButton( this, "PushButton6_2" );    PushButton6_2->setGeometry( QRect( 30, 270, 80, 30 ) );     PushButton6_2->setText( tr( "<< Prior" ) );    PushButton1 = new QPushButton( this, "PushButton1" );    PushButton1->setGeometry( QRect( 130, 270, 80, 30 ) );     PushButton1->setMaximumSize( QSize( 240, 320 ) );    PushButton1->setText( tr( "OK(&O)" ) );    Dial1 = new QDial( this, "Dial1" );    Dial1->setGeometry( QRect( 30, 90, 60, 70 ) );     PixmapLabel1 = new QLabel( this, "PixmapLabel1" );    PixmapLabel1->setGeometry( QRect( 101, 80, 120, 91 ) );     PixmapLabel1->setPixmap( image0 );    PixmapLabel1->setScaledContents( TRUE );    LCDNumber1 = new QLCDNumber( this, "LCDNumber1" );    LCDNumber1->setGeometry( QRect( 20, 180, 201, 31 ) );     LCDNumber1->setLineWidth( 1 );    LCDNumber1->setProperty( "intValue", 168 );    Slider1 = new QSlider( this, "Slider1" );    Slider1->setGeometry( QRect( 20, 40, 201, 31 ) );     Slider1->setValue( 34 );    Slider1->setOrientation( QSlider::Horizontal );    ComboBox1 = new QComboBox( FALSE, this, "ComboBox1" );    ComboBox1->setGeometry( QRect( 20, 10, 201, 21 ) );     connect( PushButton6_2, SIGNAL(clicked()), this, SLOT(showlast()) );    m_fm2 = 0;     m_fm1 = 0;     ComboBox1->insertItem("Item1");    ComboBox1->insertItem("Item2");    ComboBox1->insertItem("Item3");}/*   *  Destroys the object and frees any allocated resources */Form3::~Form3(){    // no need to delete child widgets, Qt does it all for us}void Form3::showlast(){ if (m_fm2){	hide();	m_fm2->show();}}void Form3::setFormPtr(Form1* fm1, Form2* fm2){m_fm2 = fm2;m_fm1 = fm1; connect( PushButton1, SIGNAL(clicked()), m_fm1, SLOT(close()) );}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -