source: lumina/lumina-desktop/LPanel.h @ a584991

releng/10.0.3
Last change on this file since a584991 was a584991, checked in by Ken Moore <ken@…>, 2 months ago

Setup the desktop panels to now allow full transparency with the current window background. Also hard code a simple 1 pixel grey background with rounded corners for a cleaner edge for the panels.

  • Property mode set to 100644
File size: 1.5 KB
Line 
1//===========================================
2//  Lumina-DE source code
3//  Copyright (c) 2012, Ken Moore
4//  Available under the 3-clause BSD license
5//  See the LICENSE file for full details
6//===========================================
7//  This is the generic class for creating a full-width panel that stays
8//    on top of all other windows (top or bottom of the screen only)
9//===========================================
10#ifndef _LUMINA_DESKTOP_PANEL_H
11#define _LUMINA_DESKTOP_PANEL_H
12
13#include <QWidget>
14#include <QBoxLayout>
15#include <QSettings>
16#include <QString>
17#include <QStringList>
18#include <QTimer>
19#include <QMoveEvent>
20#include <QDesktopWidget>
21#include <QPainter>
22#include <QPaintEvent>
23
24#include "panel-plugins/NewPP.h"
25#include "panel-plugins/LPPlugin.h"
26
27#include <LuminaX11.h>
28
29class LPanel : public QWidget{
30        Q_OBJECT
31private:
32        QBoxLayout *layout;
33        QSettings *settings;
34        QString PPREFIX; //internal prefix for all settings
35        QDesktopWidget *screen;
36        QWidget *bgWindow, *panelArea;
37        bool defaultpanel, horizontal;
38        int screennum;
39        QList<LPPlugin*> PLUGINS;
40
41public:
42        LPanel(QSettings *file, int scr = 0, int num =0, QWidget *parent=0); //settings file, screen number, panel number
43        ~LPanel();
44
45        int number(){
46          return PPREFIX.section(".",-1).toInt();
47        }
48
49public slots:
50        void UpdatePanel();  //Load the settings file and update the panel appropriately
51        void UpdateLocale(); //Locale Changed externally
52        void UpdateTheme(); //Theme Changed externally
53
54protected:
55        void paintEvent(QPaintEvent *event);
56};
57
58#endif
Note: See TracBrowser for help on using the repository browser.