• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            隨筆 - 505  文章 - 1034  trackbacks - 0
            <2007年11月>
            28293031123
            45678910
            11121314151617
            18192021222324
            2526272829301
            2345678


            子曾經(jīng)曰過:編程無他,唯手熟爾!

            常用鏈接

            留言簿(94)

            隨筆分類(649)

            隨筆檔案(505)

            相冊

            BCB

            Crytek

            • crymod
            • Crytek's Offical Modding Portal

            Game Industry

            OGRE

            other

            Programmers

            Qt

            WOW Stuff

            搜索

            •  

            積分與排名

            • 積分 - 914442
            • 排名 - 14

            最新隨筆

            最新評論

            閱讀排行榜

            評論排行榜


            Qt 3.0的是這樣子的 http://www.qiliang.net/qt/tutorial1-03.html

            /****************************************************************
            **
            ** Qt教程一 - 3
            **
            ***************************************************************
            */

            #include 
            <qapplication.h>
            #include 
            <qpushbutton.h>
            #include 
            <qfont.h>
            #include 
            <qvbox.h>

            int main( int argc, char **argv )
            {
                QApplication a( argc, argv );

                QVBox box;
                box.resize( 
            200120 );

                QPushButton quit( 
            "Quit"&box );
                quit.setFont( QFont( 
            "Times"18, QFont::Bold ) );

                QObject::connect( 
            &quit, SIGNAL(clicked()), &a, SLOT(quit()) );

                a.setMainWidget( 
            &box );
                box.show();

                
            return a.exec();
            }

            在4.3中已經(jīng)沒有QVBox這個(gè)類了



            QVBox

            The QVBox class is now only available as Q3VBox in Qt 4. You can achieve the same result as QVBox by creating a QWidget with a vertical layout:

            For example, if you have code like

             QVBox *vbox = new QVBox;
             QPushButton *child1 = new QPushButton(vbox);
             QPushButton *child2 = new QPushButton(vbox); 

            you can rewrite it as

             QWidget *vbox = new QWidget;
             QPushButton *child1 = new QPushButton;
             QPushButton *child2 = new QPushButton;
            
            
             QVBoxLayout *layout = new QVBoxLayout;
             layout->addWidget(child1);
             layout->addWidget(child2);
             vbox->setLayout(layout); 

            Note that child widgets are not automatically placed into the widget's layout; you will need to manually add each widget to the QVBoxLayout.



            我寫的:

            /****************************************************************
            **
            ** Qt教程一 - 3
            **
            ***************************************************************
            */

            #include 
            <qapplication.h>
            #include 
            <qpushbutton.h>
            #include 
            <qfont.h>
            #include 
            <qboxlayout.h>

            int main( int argc, char **argv )
            {
                QApplication a( argc, argv );

                QWidget window;
                window.resize(
            200,120);

                QVBoxLayout layout;
                QPushButton quit( 
            "Quit"&window );
                quit.setFont( QFont( 
            "Times"18, QFont::Bold ) );
                QObject::connect( 
            &quit, SIGNAL(clicked()), &a, SLOT(quit()) );

                layout.addWidget(
            &quit);
                
                window.setLayout(
            &layout);
                window.show();

                
            return a.exec();
            }
            posted on 2007-07-21 05:02 七星重劍 閱讀(1921) 評論(1)  編輯 收藏 引用 所屬分類: PL--c/c++ 、C++ lib -- Qt

            FeedBack:
            # re: 遷移《Qt教程一 —— 第三章:家庭價(jià)值》到Qt 4.3.0 2016-01-22 12:34 Soler
            謝謝你  回復(fù)  更多評論
              
            久久99精品国产麻豆宅宅| 日本精品久久久久中文字幕| 国产午夜电影久久| 国产毛片久久久久久国产毛片| 精品久久久无码中文字幕| 久久亚洲天堂| 国产午夜福利精品久久2021| 国产叼嘿久久精品久久| 一本久道久久综合狠狠躁AV| 99久久国产热无码精品免费| 国产精品成人99久久久久 | 国产高清美女一级a毛片久久w| 青青草国产97免久久费观看| 1000部精品久久久久久久久| 亚洲精品高清一二区久久| 国产一区二区三区久久精品| 精品久久久久久中文字幕大豆网| 精品久久久久久国产91| 久久精品欧美日韩精品| 午夜精品久久久内射近拍高清| 国产精品久久永久免费| 亚洲午夜久久久久妓女影院 | 久久精品国产清高在天天线| 久久精品三级视频| 亚洲国产天堂久久综合网站| 国产婷婷成人久久Av免费高清| 2021国内久久精品| 欧美日韩中文字幕久久久不卡| 好久久免费视频高清| 久久久久99精品成人片直播| 久久久亚洲AV波多野结衣| 亚洲七七久久精品中文国产 | 2021久久国自产拍精品| 亚洲国产精品久久电影欧美| 久久亚洲中文字幕精品一区| 人妻少妇精品久久| 久久亚洲精品国产精品婷婷 | 久久久噜噜噜www成人网| 亚洲国产另类久久久精品黑人| 一本久久a久久精品综合香蕉| 久久经典免费视频|