2 * \file QSplashDialog.C
3 * Copyright 2001 the LyX Team
4 * Read the file COPYING
11 #include <qapplication.h>
17 #include "support/filetools.h"
18 #include "support/lstrings.h"
20 #include "QSplashDialog.h"
22 QSplashDialog::QSplashDialog(QWidget * parent, const char * name, WFlags fl, bool modal)
23 : QFrame(parent, name, fl, modal)
25 string const banner_file = LibFileSearch("images", "banner", "xpm");
26 if (banner_file.empty())
29 QPixmap const pm(tostr(banner_file).c_str());
30 int const w = pm.width();
31 int const h = pm.height();
33 setBackgroundPixmap(pm);
35 setGeometry(QApplication::desktop()->width()/2 - w/2,
36 QApplication::desktop()->height()/2 - h/2,
39 QTimer::singleShot(5*1000, this, SLOT(hide()));
43 QSplashDialog::~QSplashDialog()
48 void QSplashDialog::mousePressEvent( QMouseEvent * )