summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Bauer2011-06-17 16:07:54 +0200
committerJonathan Bauer2011-06-17 16:07:54 +0200
commit8be33c4c7cd1b1b988bc9575492dc4516f1dd8d8 (patch)
tree2b06525e3221448d8cdaf098fbcbe44872441e07
parentthe geometric way to layout label/progress bar, TODO proper central widget... (diff)
downloadfbsplash-8be33c4c7cd1b1b988bc9575492dc4516f1dd8d8.tar.gz
fbsplash-8be33c4c7cd1b1b988bc9575492dc4516f1dd8d8.tar.xz
fbsplash-8be33c4c7cd1b1b988bc9575492dc4516f1dd8d8.zip
README for build/run scripts & few comments..
-rw-r--r--README12
-rw-r--r--src/fbsplash.cpp12
2 files changed, 17 insertions, 7 deletions
diff --git a/README b/README
index 5489484..506c7fa 100644
--- a/README
+++ b/README
@@ -1,3 +1,15 @@
***************************************
Framebuffer BootSplash for OpenSLX
***************************************
+
+To create Makefile, use:
+
+ ./build.sh
+
+(this will generate Makefile with cmake, under the build/ subdirectory)
+
+To run the program (on the qvfb), use:
+
+ ./run.sh
+
+(this will start qvfb and launch fbsplash on it, similar to fbgui)
diff --git a/src/fbsplash.cpp b/src/fbsplash.cpp
index 0e84c5c..d22cbbc 100644
--- a/src/fbsplash.cpp
+++ b/src/fbsplash.cpp
@@ -12,24 +12,22 @@ fbsplash::fbsplash() :
createActions();
setupTheme();
- _label = new QLabel("<font size=10 color='green'>OpenSLX</font>");
- _label->setAlignment(Qt::AlignHCenter | Qt::AlignVCenter);
-
-
-
- qDebug() << "center x: " << center.x();
- qDebug() << "center y: " << center.y();
+ // basic progress bar for now
QProgressBar* pb = new QProgressBar(this);
//pb->setFormat("Progress: %p%");
pb->setWindowFlags(Qt::FramelessWindowHint);
pb->setRange(0, 100);
pb->setValue(10);
+ // move the pb to the center, TODO proper margin
QRect desktopRect = QApplication::desktop()->availableGeometry(this);
QPoint center = desktopRect.center();
pb->move(center.x() - pb->width()*0.5 , center.y() - pb->height()*0.5 + 50);
+ // Label in the middle of the screen
+ _label = new QLabel("<font size=10 color='green'>OpenSLX</font>");
+ _label->setAlignment(Qt::AlignHCenter | Qt::AlignVCenter);
setCentralWidget(_label);
setAttribute(Qt::WA_QuitOnClose, true);