diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 728d471..598022b 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -16,7 +16,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - $Id:$ */ + $Id$ */ #include "mainwindow.h" #include "qgraphicsroundtextitem.h" @@ -74,6 +74,10 @@ MainWindow::MainWindow(QWidget *parent) : this, SLOT(onMenuAbout()) ); + m_menuHelp->addAction( tr( "About Qt...", "Menu item \"About Qt\"" ), + this, + SLOT(onMenuQtAbout()) ); + QShapeFactory &sfactory = QShapeFactory::instance(); for( QShapeFactory::iterator i = sfactory.begin(); i != sfactory.end(); ++i ) { @@ -200,16 +204,18 @@ void MainWindow::onMenuSaveAs() cdscene->write( writer ); } + void MainWindow::onMenuAbout() { - QCDScene *cdscene = getScene( m_mdiArea ); - if( !cdscene ) - return; - - QPixmap pixmap = m_lscribe->preview( 0, cdscene, QSize( 400, 400 ) ); - - QLabel *label = new QLabel; - label->setPixmap( pixmap ); - QMdiSubWindow *subWindow = m_mdiArea->addSubWindow( label ); - subWindow->show(); + QMessageBox::about( this, + tr( "About" ), + tr( "
revision: $Revision:$
" + "visit project at home page " + "qlscribe.sourceforge.net
" ) ); +} + +void MainWindow::onMenuQtAbout() +{ + QMessageBox::aboutQt( this ); } diff --git a/src/mainwindow.h b/src/mainwindow.h index 1e40287..ea672ae 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -16,7 +16,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - $Id:$ */ + $Id$ */ #ifndef MAINWINDOW_H #define MAINWINDOW_H @@ -40,6 +40,7 @@ private slots: void onMenuSaveAs(); void onMenuInsert( int id ); void onMenuAbout(); + void onMenuQtAbout(); private: QLightScribe *m_lscribe;