Home · All Namespaces · All Classes · Functions · Coding Style · Plugins · File Structure

core/StelLoadingBar.hpp

00001 /*
00002  * Stellarium
00003  * Copyright (C) 2005 Fabien Chereau
00004  *
00005  * This program is free software; you can redistribute it and/or
00006  * modify it under the terms of the GNU General Public License
00007  * as published by the Free Software Foundation; either version 2
00008  * of the License, or (at your option) any later version.
00009  *
00010  * This program is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  *
00015  * You should have received a copy of the GNU General Public License
00016  * along with this program; if not, write to the Free Software
00017  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
00018  */
00019 
00020 #ifndef _STELLOADINGBAR_HPP_
00021 #define _STELLOADINGBAR_HPP_
00022 
00023 #include "StelTextureTypes.hpp"
00024 #include "StelProjectorType.hpp"
00025 #include "VecMath.hpp"
00026 
00027 #include <QString>
00028 
00029 class StelFont;
00030 
00041 class StelLoadingBar
00042 {
00043 public:
00053     StelLoadingBar(float fontSize, const QString&  splashTex, const QString& extraTextString="", 
00054                float extraTextSize = 30.f, float extraTextPosx = 0.f, float extraTextPosy = 0.f);
00055 
00056     virtual ~StelLoadingBar();
00057     
00060     void SetMessage(QString m) {message=m;}
00061     
00065     void Draw(float val);
00066 
00067 private:
00068     QString message;
00069     int splashx, splashy, barx, bary, width, height, barwidth, barheight;
00070     StelFont& barfont;
00071     StelFont& extraTextFont;
00072     StelTextureSP splash;
00073     QString extraText;
00074     Vec2f extraTextPos;
00075     double timeCounter;
00076 };
00077 
00078 #endif // _STELLOADINGBAR_HPP_

Generated on Mon Mar 9 16:16:15 2009 for Stellarium by  doxygen 1.5.5