Compare commits

...

5 Commits

Author SHA1 Message Date
Alf Gaida
1a184961b6 Adding upstream version 0.9.0+20151101. 2015-11-01 03:16:38 +01:00
Alf Gaida
161a7316cf Adding upstream version 0.9.0+20151027. 2015-10-27 19:20:43 +01:00
Alf Gaida
c646cdaab7 Adding upstream version 0.9.0+20151024. 2015-10-25 02:26:00 +02:00
Alf Gaida
f591c66457 Adding upstream version 0.9.0+20150925. 2015-09-26 00:28:07 +02:00
Alf Gaida
bee030dd8b Adding upstream version 0.9.0+20150830. 2015-09-04 20:52:41 +02:00
1100 changed files with 6439 additions and 4361 deletions

View File

@ -1,9 +1,8 @@
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
@ -23,8 +22,7 @@ specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations
below.
strategy to use in any particular case, based on the explanations below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
@ -89,9 +87,9 @@ libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it
becomes a de-facto standard. To achieve this, non-free programs must
be allowed to use the library. A more frequent case is that a free
encourage the widest possible use of a certain library, so that it becomes
a de-facto standard. To achieve this, non-free programs must be
allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
@ -138,8 +136,8 @@ included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control
compilation and installation of the library.
interface definition files, plus the scripts used to control compilation
and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
@ -305,10 +303,10 @@ of these things:
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at least
three years, to give the same user the materials specified in
Subsection 6a, above, for a charge no more than the cost of
performing this distribution.
c) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
@ -386,10 +384,9 @@ all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply, and the section as a whole is intended to apply in other
circumstances.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply,
and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
@ -407,11 +404,11 @@ be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License
may add an explicit geographical distribution limitation excluding those
countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
original copyright holder who places the Library under this License may add
an explicit geographical distribution limitation excluding those countries,
so that distribution is permitted only in or among countries not thus
excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.

View File

@ -25,6 +25,8 @@ MACRO (BUILD_LXQT_PLUGIN NAME)
SOURCES
${${PROJECT_NAME}_DESKTOP_FILES_IN}
)
lxqt_plugin_translation_loader(QM_LOADER ${NAME} "lxqt-panel")
#************************************************
file (GLOB CONFIG_FILES resources/*.conf)
@ -42,7 +44,7 @@ MACRO (BUILD_LXQT_PLUGIN NAME)
endif()
list(FIND STATIC_PLUGINS ${NAME} IS_STATIC)
set(SRC ${HEADERS} ${SOURCES} ${MOC_SOURCES} ${${PROJECT_NAME}_QM_FILES} ${RESOURCES} ${UIS} ${DESKTOP_FILES})
set(SRC ${HEADERS} ${SOURCES} ${QM_LOADER} ${MOC_SOURCES} ${${PROJECT_NAME}_QM_FILES} ${RESOURCES} ${UIS} ${DESKTOP_FILES})
if (${IS_STATIC} EQUAL -1) # not static
add_library(${NAME} MODULE ${SRC}) # build dynamically loadable modules
install(TARGETS ${NAME} DESTINATION ${PLUGIN_DIR}) # install the *.so file

View File

@ -53,12 +53,12 @@ AddPluginDialog::AddPluginDialog(QWidget *parent):
desktopFilesDirs << QString("%1/%2").arg(XdgDirs::dataHome(), "/lxqt/lxqt-panel");
desktopFilesDirs << PLUGIN_DESKTOPS_DIR;
mPlugins = LxQt::PluginInfo::search(desktopFilesDirs, QStringLiteral("LxQtPanel/Plugin"), QStringLiteral("*"));
std::sort(mPlugins.begin(), mPlugins.end(), [](const LxQt::PluginInfo &p1, const LxQt::PluginInfo &p2) {
mPlugins = LXQt::PluginInfo::search(desktopFilesDirs, QLatin1String("LXQtPanel/Plugin"), QLatin1String("*"));
std::sort(mPlugins.begin(), mPlugins.end(), [](const LXQt::PluginInfo &p1, const LXQt::PluginInfo &p2) {
return p1.name() < p2.name() || (p1.name() == p2.name() && p1.comment() < p2.comment());
});
ui->pluginList->setItemDelegate(new LxQt::HtmlDelegate(QSize(32, 32), ui->pluginList));
ui->pluginList->setItemDelegate(new LXQt::HtmlDelegate(QSize(32, 32), ui->pluginList));
ui->pluginList->setContextMenuPolicy(Qt::CustomContextMenu);
filter();
@ -72,9 +72,9 @@ AddPluginDialog::AddPluginDialog(QWidget *parent):
connect(ui->pluginList, &QListWidget::doubleClicked, this, &AddPluginDialog::emitPluginSelected);
connect(ui->addButton, &QPushButton::clicked, this, &AddPluginDialog::emitPluginSelected);
connect(dynamic_cast<LxQtPanelApplication *>(qApp), &LxQtPanelApplication::pluginAdded
connect(dynamic_cast<LXQtPanelApplication *>(qApp), &LXQtPanelApplication::pluginAdded
, this, &AddPluginDialog::filter);
connect(dynamic_cast<LxQtPanelApplication *>(qApp), &LxQtPanelApplication::pluginRemoved
connect(dynamic_cast<LXQtPanelApplication *>(qApp), &LXQtPanelApplication::pluginRemoved
, this, &AddPluginDialog::filter);
}
@ -95,25 +95,26 @@ void AddPluginDialog::filter()
int pluginCount = mPlugins.length();
for (int i = 0; i < pluginCount; ++i)
{
const LxQt::PluginInfo &plugin = mPlugins.at(i);
const LXQt::PluginInfo &plugin = mPlugins.at(i);
QString s = QStringLiteral("%1 %2 %3 %4").arg(plugin.name(),
QString s = QString("%1 %2 %3 %4 %5").arg(plugin.name(),
plugin.comment(),
plugin.value("Name").toString(),
plugin.value("Comment").toString());
plugin.value("Comment").toString(),
plugin.id());
if (!s.contains(ui->searchEdit->text(), Qt::CaseInsensitive))
continue;
QListWidgetItem* item = new QListWidgetItem(ui->pluginList);
// disable single-instances plugins already in use
if (dynamic_cast<LxQtPanelApplication const *>(qApp)->isPluginSingletonAndRunnig(plugin.id()))
if (dynamic_cast<LXQtPanelApplication const *>(qApp)->isPluginSingletonAndRunnig(plugin.id()))
{
item->setFlags(item->flags() & ~Qt::ItemIsEnabled);
item->setBackground(palette().brush(QPalette::Disabled, QPalette::Text));
item->setText(QStringLiteral("<b>%1</b><br>%2<br><small>%3</small>")
.arg(plugin.name(), plugin.comment(), tr("(only one instance can run at a time)")));
item->setText(QString("<b>%1</b> (%2)<br>%3<br><small>%4</small>")
.arg(plugin.name(), plugin.id(), plugin.comment(), tr("(only one instance can run at a time)")));
} else
item->setText(QStringLiteral("<b>%1</b><br>%2").arg(plugin.name(), plugin.comment()));
item->setText(QString("<b>%1</b> (%2)<br>%3").arg(plugin.name(), plugin.id(), plugin.comment()));
item->setIcon(plugin.icon(fallIco));
item->setData(INDEX_ROLE, i);
}
@ -127,7 +128,7 @@ void AddPluginDialog::emitPluginSelected()
QListWidget* pluginList = ui->pluginList;
if (pluginList->currentItem() && pluginList->currentItem()->isSelected())
{
LxQt::PluginInfo plugin = mPlugins.at(pluginList->currentItem()->data(INDEX_ROLE).toInt());
LXQt::PluginInfo plugin = mPlugins.at(pluginList->currentItem()->data(INDEX_ROLE).toInt());
emit pluginSelected(plugin);
}
}

View File

@ -48,11 +48,11 @@ public:
~AddPluginDialog();
signals:
void pluginSelected(const LxQt::PluginInfo &plugin);
void pluginSelected(const LXQt::PluginInfo &plugin);
private:
Ui::AddPluginDialog *ui;
LxQt::PluginInfoList mPlugins;
LXQt::PluginInfoList mPlugins;
QTimer mSearchTimer;
private slots:

View File

@ -27,19 +27,19 @@
#include "configpaneldialog.h"
ConfigPanelDialog::ConfigPanelDialog(LxQtPanel *panel, QWidget *parent):
LxQt::ConfigDialog(tr("Configure Panel"), panel->settings(), parent),
ConfigPanelDialog::ConfigPanelDialog(LXQtPanel *panel, QWidget *parent):
LXQt::ConfigDialog(tr("Configure Panel"), panel->settings(), parent),
mPanelPage(nullptr),
mPluginsPage(nullptr)
{
setAttribute(Qt::WA_DeleteOnClose);
mPanelPage = new ConfigPanelWidget(panel, this);
addPage(mPanelPage, tr("Panel"), QStringLiteral("configure"));
addPage(mPanelPage, tr("Panel"), QLatin1String("configure"));
connect(this, &ConfigPanelDialog::reset, mPanelPage, &ConfigPanelWidget::reset);
mPluginsPage = new ConfigPluginsWidget(panel, this);
addPage(mPluginsPage, tr("Widgets"), QStringLiteral("preferences-plugin"));
addPage(mPluginsPage, tr("Widgets"), QLatin1String("preferences-plugin"));
connect(this, &ConfigPanelDialog::reset, mPluginsPage, &ConfigPluginsWidget::reset);
connect(this, &ConfigPanelDialog::accepted, [panel] {

View File

@ -34,12 +34,12 @@
#include <LXQt/ConfigDialog>
class ConfigPanelDialog : public LxQt::ConfigDialog
class ConfigPanelDialog : public LXQt::ConfigDialog
{
Q_OBJECT
public:
ConfigPanelDialog(LxQtPanel *panel, QWidget *parent = 0);
ConfigPanelDialog(LXQtPanel *panel, QWidget *parent = 0);
void showConfigPanelPage();
void showConfigPluginsPage();

View File

@ -39,16 +39,16 @@
#include <QFileDialog>
#include <QStandardPaths>
using namespace LxQt;
using namespace LXQt;
struct ScreenPosition
{
int screen;
ILxQtPanel::Position position;
ILXQtPanel::Position position;
};
Q_DECLARE_METATYPE(ScreenPosition)
ConfigPanelWidget::ConfigPanelWidget(LxQtPanel *panel, QWidget *parent) :
ConfigPanelWidget::ConfigPanelWidget(LXQtPanel *panel, QWidget *parent) :
QWidget(parent),
ui(new Ui::ConfigPanelWidget),
mPanel(panel)
@ -153,10 +153,10 @@ void ConfigPanelWidget::fillComboBox_position()
int screenCount = QApplication::desktop()->screenCount();
if (screenCount == 1)
{
addPosition(tr("Top of desktop"), 0, LxQtPanel::PositionTop);
addPosition(tr("Left of desktop"), 0, LxQtPanel::PositionLeft);
addPosition(tr("Right of desktop"), 0, LxQtPanel::PositionRight);
addPosition(tr("Bottom of desktop"), 0, LxQtPanel::PositionBottom);
addPosition(tr("Top of desktop"), 0, LXQtPanel::PositionTop);
addPosition(tr("Left of desktop"), 0, LXQtPanel::PositionLeft);
addPosition(tr("Right of desktop"), 0, LXQtPanel::PositionRight);
addPosition(tr("Bottom of desktop"), 0, LXQtPanel::PositionBottom);
}
else
{
@ -165,10 +165,10 @@ void ConfigPanelWidget::fillComboBox_position()
if (screenNum)
ui->comboBox_position->insertSeparator(9999);
addPosition(tr("Top of desktop %1").arg(screenNum +1), screenNum, LxQtPanel::PositionTop);
addPosition(tr("Left of desktop %1").arg(screenNum +1), screenNum, LxQtPanel::PositionLeft);
addPosition(tr("Right of desktop %1").arg(screenNum +1), screenNum, LxQtPanel::PositionRight);
addPosition(tr("Bottom of desktop %1").arg(screenNum +1), screenNum, LxQtPanel::PositionBottom);
addPosition(tr("Top of desktop %1").arg(screenNum +1), screenNum, LXQtPanel::PositionTop);
addPosition(tr("Left of desktop %1").arg(screenNum +1), screenNum, LXQtPanel::PositionLeft);
addPosition(tr("Right of desktop %1").arg(screenNum +1), screenNum, LXQtPanel::PositionRight);
addPosition(tr("Bottom of desktop %1").arg(screenNum +1), screenNum, LXQtPanel::PositionBottom);
}
}
}
@ -179,13 +179,13 @@ void ConfigPanelWidget::fillComboBox_position()
************************************************/
void ConfigPanelWidget::fillComboBox_alignment()
{
ui->comboBox_alignment->setItemData(0, QVariant(LxQtPanel::AlignmentLeft));
ui->comboBox_alignment->setItemData(1, QVariant(LxQtPanel::AlignmentCenter));
ui->comboBox_alignment->setItemData(2, QVariant(LxQtPanel::AlignmentRight));
ui->comboBox_alignment->setItemData(0, QVariant(LXQtPanel::AlignmentLeft));
ui->comboBox_alignment->setItemData(1, QVariant(LXQtPanel::AlignmentCenter));
ui->comboBox_alignment->setItemData(2, QVariant(LXQtPanel::AlignmentRight));
if (mPosition == ILxQtPanel::PositionTop ||
mPosition == ILxQtPanel::PositionBottom)
if (mPosition == ILXQtPanel::PositionTop ||
mPosition == ILXQtPanel::PositionBottom)
{
ui->comboBox_alignment->setItemText(0, tr("Left"));
ui->comboBox_alignment->setItemText(1, tr("Center"));
@ -203,9 +203,9 @@ void ConfigPanelWidget::fillComboBox_alignment()
/************************************************
*
************************************************/
void ConfigPanelWidget::addPosition(const QString& name, int screen, LxQtPanel::Position position)
void ConfigPanelWidget::addPosition(const QString& name, int screen, LXQtPanel::Position position)
{
if (LxQtPanel::canPlacedOn(screen, position))
if (LXQtPanel::canPlacedOn(screen, position))
ui->comboBox_position->addItem(name, QVariant::fromValue((ScreenPosition){screen, position}));
}
@ -213,7 +213,7 @@ void ConfigPanelWidget::addPosition(const QString& name, int screen, LxQtPanel::
/************************************************
*
************************************************/
int ConfigPanelWidget::indexForPosition(int screen, ILxQtPanel::Position position)
int ConfigPanelWidget::indexForPosition(int screen, ILXQtPanel::Position position)
{
for (int i = 0; i < ui->comboBox_position->count(); i++)
{
@ -247,7 +247,7 @@ void ConfigPanelWidget::editChanged()
ui->comboBox_lenghtType->currentIndex() == 0,
true);
LxQtPanel::Alignment align = LxQtPanel::Alignment(
LXQtPanel::Alignment align = LXQtPanel::Alignment(
ui->comboBox_alignment->itemData(
ui->comboBox_alignment->currentIndex()
).toInt());
@ -304,8 +304,8 @@ int ConfigPanelWidget::getMaxLength()
{
QDesktopWidget* dw = QApplication::desktop();
if (mPosition == ILxQtPanel::PositionTop ||
mPosition == ILxQtPanel::PositionBottom)
if (mPosition == ILXQtPanel::PositionTop ||
mPosition == ILXQtPanel::PositionBottom)
return dw->screenGeometry(mScreenNum).width();
else
return dw->screenGeometry(mScreenNum).height();
@ -320,10 +320,10 @@ void ConfigPanelWidget::positionChanged()
ScreenPosition sp = ui->comboBox_position->itemData(
ui->comboBox_position->currentIndex()).value<ScreenPosition>();
bool updateAlig = (sp.position == ILxQtPanel::PositionTop ||
sp.position == ILxQtPanel::PositionBottom) !=
(mPosition == ILxQtPanel::PositionTop ||
mPosition == ILxQtPanel::PositionBottom);
bool updateAlig = (sp.position == ILXQtPanel::PositionTop ||
sp.position == ILXQtPanel::PositionBottom) !=
(mPosition == ILXQtPanel::PositionTop ||
mPosition == ILXQtPanel::PositionBottom);
int oldMax = getMaxLength();
mPosition = sp.position;

View File

@ -33,7 +33,7 @@
#include <QTimer>
#include <LXQt/ConfigDialog>
class LxQtPanel;
class LXQtPanel;
namespace Ui {
class ConfigPanelWidget;
@ -44,11 +44,11 @@ class ConfigPanelWidget : public QWidget
Q_OBJECT
public:
explicit ConfigPanelWidget(LxQtPanel *panel, QWidget *parent = 0);
explicit ConfigPanelWidget(LXQtPanel *panel, QWidget *parent = 0);
~ConfigPanelWidget();
int screenNum() const { return mScreenNum; }
ILxQtPanel::Position position() const { return mPosition; }
ILXQtPanel::Position position() const { return mPosition; }
signals:
void changed();
@ -66,14 +66,14 @@ private slots:
private:
Ui::ConfigPanelWidget *ui;
LxQtPanel *mPanel;
LXQtPanel *mPanel;
int mScreenNum;
ILxQtPanel::Position mPosition;
ILXQtPanel::Position mPosition;
void addPosition(const QString& name, int screen, LxQtPanel::Position position);
void addPosition(const QString& name, int screen, LXQtPanel::Position position);
void fillComboBox_position();
void fillComboBox_alignment();
int indexForPosition(int screen, ILxQtPanel::Position position);
int indexForPosition(int screen, ILXQtPanel::Position position);
int getMaxLength();
// new values
@ -86,8 +86,8 @@ private:
int mOldLineCount;
int mOldLength;
bool mOldLengthInPercents;
LxQtPanel::Alignment mOldAlignment;
ILxQtPanel::Position mOldPosition;
LXQtPanel::Alignment mOldAlignment;
ILXQtPanel::Position mOldPosition;
bool mOldHidable;
int mOldScreenNum;
QColor mOldFontColor;

View File

@ -36,7 +36,7 @@
#include <QPushButton>
#include <QItemSelectionModel>
ConfigPluginsWidget::ConfigPluginsWidget(LxQtPanel *panel, QWidget* parent) :
ConfigPluginsWidget::ConfigPluginsWidget(LXQtPanel *panel, QWidget* parent) :
QWidget(parent),
ui(new Ui::ConfigPluginsWidget),
mPanel(panel)
@ -50,7 +50,7 @@ ConfigPluginsWidget::ConfigPluginsWidget(LxQtPanel *panel, QWidget* parent) :
}
{
QScopedPointer<QAbstractItemDelegate> d(ui->listView_plugins->itemDelegate());
ui->listView_plugins->setItemDelegate(new LxQt::HtmlDelegate(QSize(16, 16), ui->listView_plugins));
ui->listView_plugins->setItemDelegate(new LXQt::HtmlDelegate(QSize(16, 16), ui->listView_plugins));
}
resetButtons();
@ -109,7 +109,7 @@ void ConfigPluginsWidget::resetButtons()
Plugin const * plugin
= ui->listView_plugins->model()->data(selectionModel->currentIndex(), Qt::UserRole).value<Plugin const *>();
if (nullptr != plugin)
hasConfigDialog = plugin->iPlugin()->flags().testFlag(ILxQtPanelPlugin::HaveConfigDialog);
hasConfigDialog = plugin->iPlugin()->flags().testFlag(ILXQtPanelPlugin::HaveConfigDialog);
}
ui->pushButton_removePlugin->setEnabled(hasSelection);

View File

@ -42,7 +42,7 @@ class ConfigPluginsWidget : public QWidget
Q_OBJECT
public:
ConfigPluginsWidget(LxQtPanel *panel, QWidget* parent = 0);
ConfigPluginsWidget(LXQtPanel *panel, QWidget* parent = 0);
~ConfigPluginsWidget();
signals:
@ -58,7 +58,7 @@ private slots:
private:
Ui::ConfigPluginsWidget *ui;
QScopedPointer<AddPluginDialog> mAddPluginDialog;
LxQtPanel *mPanel;
LXQtPanel *mPanel;
};
#endif

View File

@ -31,11 +31,11 @@
#include <QRect>
#include "lxqtpanelglobals.h"
class ILxQtPanelPlugin;
class ILXQtPanelPlugin;
/**
**/
class LXQT_PANEL_API ILxQtPanel
class LXQT_PANEL_API ILXQtPanel
{
public:
/**
@ -73,7 +73,7 @@ public:
If you need to show some popup window, you can use it, to get global screen position for the new window.
**/
virtual QRect calculatePopupWindowPos(const QPoint &absolutePos, const QSize &windowSize) const = 0;
virtual QRect calculatePopupWindowPos(const ILxQtPanelPlugin *plugin, const QSize &windowSize) const = 0;
virtual QRect calculatePopupWindowPos(const ILXQtPanelPlugin *plugin, const QSize &windowSize) const = 0;
};
#endif // ILXQTPANEL_H

View File

@ -37,7 +37,7 @@
#include "lxqtpanelglobals.h"
/**
LxQt panel plugins are standalone sharedlibraries
LXQt panel plugins are standalone sharedlibraries
(*.so) located in PLUGIN_DIR (define provided by CMakeLists.txt).
Plugin for the panel is a library written on C++. One more necessary thing
@ -51,15 +51,15 @@ like translations. Themselves plugins will be installed to
class QDialog;
struct LXQT_PANEL_API ILxQtPanelPluginStartupInfo
struct LXQT_PANEL_API ILXQtPanelPluginStartupInfo
{
ILxQtPanel *lxqtPanel;
ILXQtPanel *lxqtPanel;
QSettings *settings;
const LxQt::PluginInfo *desktopFile;
const LXQt::PluginInfo *desktopFile;
};
/** \brief Base abstract class for LxQt panel widgets/plugins.
/** \brief Base abstract class for LXQt panel widgets/plugins.
All plugins *must* be inherited from this one.
This class provides some basic API and inherited/implemented
@ -69,7 +69,7 @@ See <a href=https://github.com/LXDE-Qt/lxde-qt/wiki/How-to-write-the-panel-plugi
How to write the panel plugin</a> for more information about how to make your plugins.
**/
class LXQT_PANEL_API ILxQtPanelPlugin
class LXQT_PANEL_API ILXQtPanelPlugin
{
public:
/**
@ -99,10 +99,10 @@ public:
};
/**
Constructs a ILxQtPanelPlugin object with the given startupInfo. You do not have to worry
about the startupInfo parameters, ILxQtPanelPlugin process the parameters yourself.
Constructs a ILXQtPanelPlugin object with the given startupInfo. You do not have to worry
about the startupInfo parameters, ILXQtPanelPlugin process the parameters yourself.
**/
ILxQtPanelPlugin(const ILxQtPanelPluginStartupInfo &startupInfo):
ILXQtPanelPlugin(const ILXQtPanelPluginStartupInfo &startupInfo):
mSettings(startupInfo.settings),
mPanel(startupInfo.lxqtPanel),
mDesktopFile(startupInfo.desktopFile)
@ -111,7 +111,7 @@ public:
/**
Destroys the object.
**/
virtual ~ILxQtPanelPlugin() {}
virtual ~ILXQtPanelPlugin() {}
/**
Returns the plugin flags.
@ -139,7 +139,7 @@ public:
The default implementation returns 0, no dialog;
Note that the flags method has to return HaveConfigDialog flag.
To save the settings you should use a ready-to-use ILxQtPanelPlugin::settings() object.
To save the settings you should use a ready-to-use ILXQtPanelPlugin::settings() object.
**/
virtual QDialog *configureDialog() { return 0; }
@ -154,7 +154,7 @@ public:
/**
This function is called when the user activates the plugin. reason specifies the reason for activation.
ILxQtPanelPlugin::ActivationReason enumerates the various reasons.
ILXQtPanelPlugin::ActivationReason enumerates the various reasons.
The default implementation do nothing.
**/
@ -171,11 +171,11 @@ public:
/**
Returns the panel object.
**/
ILxQtPanel *panel() const { return mPanel; }
ILXQtPanel *panel() const { return mPanel; }
QSettings *settings() const { return mSettings; }
const LxQt::PluginInfo *desktopFile() const { return mDesktopFile; }
const LXQt::PluginInfo *desktopFile() const { return mDesktopFile; }
/**
Helper functions for calculating global screen position of some popup window with windowSize size.
@ -191,42 +191,42 @@ public:
virtual bool isExpandable() const { return false; }
private:
QSettings *mSettings;
ILxQtPanel *mPanel;
const LxQt::PluginInfo *mDesktopFile;
ILXQtPanel *mPanel;
const LXQt::PluginInfo *mDesktopFile;
};
Q_DECLARE_OPERATORS_FOR_FLAGS(ILxQtPanelPlugin::Flags)
Q_DECLARE_OPERATORS_FOR_FLAGS(ILXQtPanelPlugin::Flags)
/**
Every plugin must has the loader. You shoul only reimplement instance() method, and return your plugin.
Example:
@code
class LxQtClockPluginLibrary: public QObject, public ILxQtPanelPluginLibrary
class LXQtClockPluginLibrary: public QObject, public ILXQtPanelPluginLibrary
{
Q_OBJECT
Q_PLUGIN_METADATA(IID "lxde-qt.org/Panel/PluginInterface/3.0")
Q_INTERFACES(ILxQtPanelPluginLibrary)
Q_INTERFACES(ILXQtPanelPluginLibrary)
public:
ILxQtPanelPlugin *instance(const ILxQtPanelPluginStartupInfo &startupInfo) { return new LxQtClock(startupInfo);}
ILXQtPanelPlugin *instance(const ILXQtPanelPluginStartupInfo &startupInfo) { return new LXQtClock(startupInfo);}
};
@endcode
**/
class LXQT_PANEL_API ILxQtPanelPluginLibrary
class LXQT_PANEL_API ILXQtPanelPluginLibrary
{
public:
/**
Destroys the ILxQtPanelPluginLibrary object.
Destroys the ILXQtPanelPluginLibrary object.
**/
virtual ~ILxQtPanelPluginLibrary() {}
virtual ~ILXQtPanelPluginLibrary() {}
/**
Returns the root component object of the plugin. When the library is finally unloaded, the root component will automatically be deleted.
**/
virtual ILxQtPanelPlugin* instance(const ILxQtPanelPluginStartupInfo &startupInfo) const = 0;
virtual ILXQtPanelPlugin* instance(const ILXQtPanelPluginStartupInfo &startupInfo) const = 0;
};
Q_DECLARE_INTERFACE(ILxQtPanelPluginLibrary,
Q_DECLARE_INTERFACE(ILXQtPanelPluginLibrary,
"lxde-qt.org/Panel/PluginInterface/3.0")
#endif // ILXQTPANELPLUGIN_H

View File

@ -35,7 +35,6 @@
#include "popupmenu.h"
#include "plugin.h"
#include "panelpluginsmodel.h"
#include <LXQt/Settings>
#include <LXQt/PluginInfo>
#include <QScreen>
@ -78,12 +77,12 @@
String is one of "Top", "Left", "Bottom", "Right", string is not case sensitive.
If the string is not correct, returns defaultValue.
************************************************/
ILxQtPanel::Position LxQtPanel::strToPosition(const QString& str, ILxQtPanel::Position defaultValue)
ILXQtPanel::Position LXQtPanel::strToPosition(const QString& str, ILXQtPanel::Position defaultValue)
{
if (str.toUpper() == "TOP") return LxQtPanel::PositionTop;
if (str.toUpper() == "LEFT") return LxQtPanel::PositionLeft;
if (str.toUpper() == "RIGHT") return LxQtPanel::PositionRight;
if (str.toUpper() == "BOTTOM") return LxQtPanel::PositionBottom;
if (str.toUpper() == "TOP") return LXQtPanel::PositionTop;
if (str.toUpper() == "LEFT") return LXQtPanel::PositionLeft;
if (str.toUpper() == "RIGHT") return LXQtPanel::PositionRight;
if (str.toUpper() == "BOTTOM") return LXQtPanel::PositionBottom;
return defaultValue;
}
@ -91,17 +90,17 @@ ILxQtPanel::Position LxQtPanel::strToPosition(const QString& str, ILxQtPanel::Po
/************************************************
Return string representation of the position
************************************************/
QString LxQtPanel::positionToStr(ILxQtPanel::Position position)
QString LXQtPanel::positionToStr(ILXQtPanel::Position position)
{
switch (position)
{
case LxQtPanel::PositionTop:
case LXQtPanel::PositionTop:
return QString("Top");
case LxQtPanel::PositionLeft:
case LXQtPanel::PositionLeft:
return QString("Left");
case LxQtPanel::PositionRight:
case LXQtPanel::PositionRight:
return QString("Right");
case LxQtPanel::PositionBottom:
case LXQtPanel::PositionBottom:
return QString("Bottom");
}
@ -112,8 +111,9 @@ QString LxQtPanel::positionToStr(ILxQtPanel::Position position)
/************************************************
************************************************/
LxQtPanel::LxQtPanel(const QString &configGroup, QWidget *parent) :
LXQtPanel::LXQtPanel(const QString &configGroup, LXQt::Settings *settings, QWidget *parent) :
QFrame(parent),
mSettings(settings),
mConfigGroup(configGroup),
mPlugins{nullptr},
mPanelSize(0),
@ -121,8 +121,9 @@ LxQtPanel::LxQtPanel(const QString &configGroup, QWidget *parent) :
mLineCount(0),
mLength(0),
mAlignment(AlignmentLeft),
mPosition(ILxQtPanel::PositionBottom),
mPosition(ILXQtPanel::PositionBottom),
mScreenNum(0), //whatever (avoid conditional on uninitialized value)
mActualScreenNum(0),
mHidable(false),
mHidden(false)
{
@ -146,19 +147,19 @@ LxQtPanel::LxQtPanel(const QString &configGroup, QWidget *parent) :
setAttribute(Qt::WA_TranslucentBackground);
setAttribute(Qt::WA_AcceptDrops);
setWindowTitle("LxQt Panel");
setObjectName(QString("LxQtPanel %1").arg(configGroup));
setWindowTitle("LXQt Panel");
setObjectName(QString("LXQtPanel %1").arg(configGroup));
LxQtPanelWidget = new QFrame(this);
LxQtPanelWidget->setObjectName("BackgroundWidget");
LXQtPanelWidget = new QFrame(this);
LXQtPanelWidget->setObjectName("BackgroundWidget");
QGridLayout* lav = new QGridLayout();
lav->setMargin(0);
setLayout(lav);
this->layout()->addWidget(LxQtPanelWidget);
this->layout()->addWidget(LXQtPanelWidget);
mLayout = new LxQtPanelLayout(LxQtPanelWidget);
connect(mLayout, &LxQtPanelLayout::pluginMoved, this, &LxQtPanel::pluginMoved);
LxQtPanelWidget->setLayout(mLayout);
mLayout = new LXQtPanelLayout(LXQtPanelWidget);
connect(mLayout, &LXQtPanelLayout::pluginMoved, this, &LXQtPanel::pluginMoved);
LXQtPanelWidget->setLayout(mLayout);
mLayout->setLineCount(mLineCount);
mDelaySave.setSingleShot(true);
@ -171,11 +172,9 @@ LxQtPanel::LxQtPanel(const QString &configGroup, QWidget *parent) :
connect(QApplication::desktop(), SIGNAL(workAreaResized(int)), this, SLOT(realign()));
connect(QApplication::desktop(), SIGNAL(screenCountChanged(int)), this, SLOT(ensureVisible()));
connect(LxQt::Settings::globalSettings(), SIGNAL(settingsChanged()), this, SLOT(update()));
connect(LXQt::Settings::globalSettings(), SIGNAL(settingsChanged()), this, SLOT(update()));
connect(lxqtApp, SIGNAL(themeChanged()), this, SLOT(realign()));
LxQtPanelApplication *app = reinterpret_cast<LxQtPanelApplication*>(qApp);
mSettings = app->settings();
readSettings();
// the old position might be on a visible screen
ensureVisible();
@ -194,7 +193,7 @@ LxQtPanel::LxQtPanel(const QString &configGroup, QWidget *parent) :
/************************************************
************************************************/
void LxQtPanel::readSettings()
void LXQtPanel::readSettings()
{
// Read settings ......................................
mSettings->beginGroup(mConfigGroup);
@ -213,7 +212,8 @@ void LxQtPanel::readSettings()
mSettings->value(CFG_KEY_PERCENT, true).toBool(),
false);
setPosition(mSettings->value(CFG_KEY_SCREENNUM, QApplication::desktop()->primaryScreen()).toInt(),
mScreenNum = mSettings->value(CFG_KEY_SCREENNUM, QApplication::desktop()->primaryScreen()).toInt();
setPosition(mScreenNum,
strToPosition(mSettings->value(CFG_KEY_POSITION).toString(), PositionBottom),
false);
@ -239,7 +239,7 @@ void LxQtPanel::readSettings()
/************************************************
************************************************/
void LxQtPanel::saveSettings(bool later)
void LXQtPanel::saveSettings(bool later)
{
mDelaySave.stop();
if (later)
@ -279,10 +279,12 @@ void LxQtPanel::saveSettings(bool later)
/************************************************
************************************************/
void LxQtPanel::ensureVisible()
void LXQtPanel::ensureVisible()
{
if (!canPlacedOn(mScreenNum, mPosition))
setPosition(findAvailableScreen(mPosition), mPosition, true);
else
mActualScreenNum = mScreenNum;
// the screen size might be changed, let's update the reserved screen space.
updateWmStrut();
@ -292,7 +294,7 @@ void LxQtPanel::ensureVisible()
/************************************************
************************************************/
LxQtPanel::~LxQtPanel()
LXQtPanel::~LXQtPanel()
{
mLayout->setEnabled(false);
// do not save settings because of "user deleted panel" functionality saveSettings();
@ -302,7 +304,7 @@ LxQtPanel::~LxQtPanel()
/************************************************
************************************************/
void LxQtPanel::show()
void LXQtPanel::show()
{
QWidget::show();
KWindowSystem::setOnDesktop(effectiveWinId(), NET::OnAllDesktops);
@ -325,18 +327,18 @@ QStringList pluginDesktopDirs()
/************************************************
************************************************/
void LxQtPanel::loadPlugins()
void LXQtPanel::loadPlugins()
{
QString names_key(mConfigGroup);
names_key += '/';
names_key += QLatin1String(CFG_KEY_PLUGINS);
mPlugins.reset(new PanelPluginsModel(this, names_key, pluginDesktopDirs()));
connect(mPlugins.data(), &PanelPluginsModel::pluginAdded, mLayout, &LxQtPanelLayout::addPlugin);
connect(mPlugins.data(), &PanelPluginsModel::pluginMovedUp, mLayout, &LxQtPanelLayout::moveUpPlugin);
connect(mPlugins.data(), &PanelPluginsModel::pluginAdded, mLayout, &LXQtPanelLayout::addPlugin);
connect(mPlugins.data(), &PanelPluginsModel::pluginMovedUp, mLayout, &LXQtPanelLayout::moveUpPlugin);
//reemit signals
connect(mPlugins.data(), &PanelPluginsModel::pluginAdded, this, &LxQtPanel::pluginAdded);
connect(mPlugins.data(), &PanelPluginsModel::pluginRemoved, this, &LxQtPanel::pluginRemoved);
connect(mPlugins.data(), &PanelPluginsModel::pluginAdded, this, &LXQtPanel::pluginAdded);
connect(mPlugins.data(), &PanelPluginsModel::pluginRemoved, this, &LXQtPanel::pluginRemoved);
for (auto const & plugin : mPlugins->plugins())
mLayout->addPlugin(plugin);
@ -345,14 +347,14 @@ void LxQtPanel::loadPlugins()
/************************************************
************************************************/
int LxQtPanel::getReserveDimension()
int LXQtPanel::getReserveDimension()
{
return mHidable ? PANEL_HIDE_SIZE : qMax(PANEL_MINIMUM_SIZE, mPanelSize);
}
void LxQtPanel::setPanelGeometry()
void LXQtPanel::setPanelGeometry()
{
const QRect currentScreen = QApplication::desktop()->screenGeometry(mScreenNum);
const QRect currentScreen = QApplication::desktop()->screenGeometry(mActualScreenNum);
QRect rect;
if (isHorizontal())
@ -374,21 +376,21 @@ void LxQtPanel::setPanelGeometry()
// Horiz ......................
switch (mAlignment)
{
case LxQtPanel::AlignmentLeft:
case LXQtPanel::AlignmentLeft:
rect.moveLeft(currentScreen.left());
break;
case LxQtPanel::AlignmentCenter:
case LXQtPanel::AlignmentCenter:
rect.moveCenter(currentScreen.center());
break;
case LxQtPanel::AlignmentRight:
case LXQtPanel::AlignmentRight:
rect.moveRight(currentScreen.right());
break;
}
// Vert .......................
if (mPosition == ILxQtPanel::PositionTop)
if (mPosition == ILXQtPanel::PositionTop)
rect.moveTop(currentScreen.top());
else
rect.moveBottom(currentScreen.bottom());
@ -412,21 +414,21 @@ void LxQtPanel::setPanelGeometry()
// Vert .......................
switch (mAlignment)
{
case LxQtPanel::AlignmentLeft:
case LXQtPanel::AlignmentLeft:
rect.moveTop(currentScreen.top());
break;
case LxQtPanel::AlignmentCenter:
case LXQtPanel::AlignmentCenter:
rect.moveCenter(currentScreen.center());
break;
case LxQtPanel::AlignmentRight:
case LXQtPanel::AlignmentRight:
rect.moveBottom(currentScreen.bottom());
break;
}
// Horiz ......................
if (mPosition == ILxQtPanel::PositionLeft)
if (mPosition == ILXQtPanel::PositionLeft)
rect.moveLeft(currentScreen.left());
else
rect.moveRight(currentScreen.right());
@ -439,7 +441,7 @@ void LxQtPanel::setPanelGeometry()
}
}
void LxQtPanel::realign()
void LXQtPanel::realign()
{
if (!isVisible())
return;
@ -464,12 +466,13 @@ void LxQtPanel::realign()
// Update the _NET_WM_PARTIAL_STRUT and _NET_WM_STRUT properties for the window
void LxQtPanel::updateWmStrut()
void LXQtPanel::updateWmStrut()
{
WId wid = effectiveWinId();
if(wid == 0 || !isVisible())
return;
const QRect wholeScreen = QApplication::desktop()->geometry();
const QRect rect = geometry();
// NOTE: http://standards.freedesktop.org/wm-spec/wm-spec-latest.html
// Quote from the EWMH spec: " Note that the strut is relative to the screen edge, and not the edge of the xinerama monitor."
@ -478,27 +481,27 @@ void LxQtPanel::updateWmStrut()
// At least openbox is implemented like this.
switch (mPosition)
{
case LxQtPanel::PositionTop:
case LXQtPanel::PositionTop:
KWindowSystem::setExtendedStrut(wid,
/* Left */ 0, 0, 0,
/* Right */ 0, 0, 0,
/* Top */ getReserveDimension(), rect.left(), rect.right(),
/* Top */ rect.top() + getReserveDimension(), rect.left(), rect.right(),
/* Bottom */ 0, 0, 0
);
break;
case LxQtPanel::PositionBottom:
case LXQtPanel::PositionBottom:
KWindowSystem::setExtendedStrut(wid,
/* Left */ 0, 0, 0,
/* Right */ 0, 0, 0,
/* Top */ 0, 0, 0,
/* Bottom */ getReserveDimension(), rect.left(), rect.right()
/* Bottom */ wholeScreen.bottom() - rect.bottom() + getReserveDimension(), rect.left(), rect.right()
);
break;
case LxQtPanel::PositionLeft:
case LXQtPanel::PositionLeft:
KWindowSystem::setExtendedStrut(wid,
/* Left */ getReserveDimension(), rect.top(), rect.bottom(),
/* Left */ rect.left() + getReserveDimension(), rect.top(), rect.bottom(),
/* Right */ 0, 0, 0,
/* Top */ 0, 0, 0,
/* Bottom */ 0, 0, 0
@ -506,10 +509,10 @@ void LxQtPanel::updateWmStrut()
break;
case LxQtPanel::PositionRight:
case LXQtPanel::PositionRight:
KWindowSystem::setExtendedStrut(wid,
/* Left */ 0, 0, 0,
/* Right */ getReserveDimension(), rect.top(), rect.bottom(),
/* Right */ wholeScreen.right() - rect.right() + getReserveDimension(), rect.top(), rect.bottom(),
/* Top */ 0, 0, 0,
/* Bottom */ 0, 0, 0
);
@ -523,31 +526,31 @@ void LxQtPanel::updateWmStrut()
This function checks, is the panel can be placed on the display
@displayNum on @position.
************************************************/
bool LxQtPanel::canPlacedOn(int screenNum, LxQtPanel::Position position)
bool LXQtPanel::canPlacedOn(int screenNum, LXQtPanel::Position position)
{
QDesktopWidget* dw = QApplication::desktop();
switch (position)
{
case LxQtPanel::PositionTop:
case LXQtPanel::PositionTop:
for (int i = 0; i < dw->screenCount(); ++i)
if (dw->screenGeometry(i).bottom() < dw->screenGeometry(screenNum).top())
return false;
return true;
case LxQtPanel::PositionBottom:
case LXQtPanel::PositionBottom:
for (int i = 0; i < dw->screenCount(); ++i)
if (dw->screenGeometry(i).top() > dw->screenGeometry(screenNum).bottom())
return false;
return true;
case LxQtPanel::PositionLeft:
case LXQtPanel::PositionLeft:
for (int i = 0; i < dw->screenCount(); ++i)
if (dw->screenGeometry(i).right() < dw->screenGeometry(screenNum).left())
return false;
return true;
case LxQtPanel::PositionRight:
case LXQtPanel::PositionRight:
for (int i = 0; i < dw->screenCount(); ++i)
if (dw->screenGeometry(i).left() > dw->screenGeometry(screenNum).right())
return false;
@ -561,7 +564,7 @@ bool LxQtPanel::canPlacedOn(int screenNum, LxQtPanel::Position position)
/************************************************
************************************************/
int LxQtPanel::findAvailableScreen(LxQtPanel::Position position)
int LXQtPanel::findAvailableScreen(LXQtPanel::Position position)
{
int current = mScreenNum;
@ -580,7 +583,7 @@ int LxQtPanel::findAvailableScreen(LxQtPanel::Position position)
/************************************************
************************************************/
void LxQtPanel::showConfigDialog()
void LXQtPanel::showConfigDialog()
{
if (mConfigDialog.isNull())
mConfigDialog = new ConfigPanelDialog(this, nullptr /*make it top level window*/);
@ -599,7 +602,7 @@ void LxQtPanel::showConfigDialog()
/************************************************
************************************************/
void LxQtPanel::showAddPluginDialog()
void LXQtPanel::showAddPluginDialog()
{
if (mConfigDialog.isNull())
mConfigDialog = new ConfigPanelDialog(this, nullptr /*make it top level window*/);
@ -618,16 +621,16 @@ void LxQtPanel::showAddPluginDialog()
/************************************************
************************************************/
void LxQtPanel::updateStyleSheet()
void LXQtPanel::updateStyleSheet()
{
QStringList sheet;
sheet << QString("Plugin > QAbstractButton, LxQtTray { qproperty-iconSize: %1px %1px; }").arg(mIconSize);
sheet << QString("Plugin > QAbstractButton, LXQtTray { qproperty-iconSize: %1px %1px; }").arg(mIconSize);
sheet << QString("Plugin > * > QAbstractButton, TrayIcon { qproperty-iconSize: %1px %1px; }").arg(mIconSize);
if (mFontColor.isValid())
sheet << QString("Plugin * { color: " + mFontColor.name() + "; }");
QString object = LxQtPanelWidget->objectName();
QString object = LXQtPanelWidget->objectName();
if (mBackgroundColor.isValid())
{
@ -636,11 +639,11 @@ void LxQtPanel::updateStyleSheet()
.arg(mBackgroundColor.green())
.arg(mBackgroundColor.blue())
.arg((float) mOpacity / 100);
sheet << QString("LxQtPanel #BackgroundWidget { background-color: rgba(" + color + "); }");
sheet << QString("LXQtPanel #BackgroundWidget { background-color: rgba(" + color + "); }");
}
if (QFileInfo(mBackgroundImage).exists())
sheet << QString("LxQtPanel #BackgroundWidget { background-image: url('" + mBackgroundImage + "');}");
sheet << QString("LXQtPanel #BackgroundWidget { background-image: url('" + mBackgroundImage + "');}");
setStyleSheet(sheet.join("\n"));
}
@ -650,7 +653,7 @@ void LxQtPanel::updateStyleSheet()
/************************************************
************************************************/
void LxQtPanel::setPanelSize(int value, bool save)
void LXQtPanel::setPanelSize(int value, bool save)
{
if (mPanelSize != value)
{
@ -667,7 +670,7 @@ void LxQtPanel::setPanelSize(int value, bool save)
/************************************************
************************************************/
void LxQtPanel::setIconSize(int value, bool save)
void LXQtPanel::setIconSize(int value, bool save)
{
if (mIconSize != value)
{
@ -686,7 +689,7 @@ void LxQtPanel::setIconSize(int value, bool save)
/************************************************
************************************************/
void LxQtPanel::setLineCount(int value, bool save)
void LXQtPanel::setLineCount(int value, bool save)
{
if (mLineCount != value)
{
@ -706,7 +709,7 @@ void LxQtPanel::setLineCount(int value, bool save)
/************************************************
************************************************/
void LxQtPanel::setLength(int length, bool inPercents, bool save)
void LXQtPanel::setLength(int length, bool inPercents, bool save)
{
if (mLength == length &&
mLengthInPercents == inPercents)
@ -725,13 +728,13 @@ void LxQtPanel::setLength(int length, bool inPercents, bool save)
/************************************************
************************************************/
void LxQtPanel::setPosition(int screen, ILxQtPanel::Position position, bool save)
void LXQtPanel::setPosition(int screen, ILXQtPanel::Position position, bool save)
{
if (mScreenNum == screen &&
mPosition == position)
return;
mScreenNum = screen;
mActualScreenNum = screen;
mPosition = position;
mLayout->setPosition(mPosition);
@ -766,7 +769,7 @@ void LxQtPanel::setPosition(int screen, ILxQtPanel::Position position, bool save
/************************************************
*
************************************************/
void LxQtPanel::setAlignment(Alignment value, bool save)
void LXQtPanel::setAlignment(Alignment value, bool save)
{
if (mAlignment == value)
return;
@ -782,7 +785,7 @@ void LxQtPanel::setAlignment(Alignment value, bool save)
/************************************************
*
************************************************/
void LxQtPanel::setFontColor(QColor color, bool save)
void LXQtPanel::setFontColor(QColor color, bool save)
{
mFontColor = color;
updateStyleSheet();
@ -794,7 +797,7 @@ void LxQtPanel::setFontColor(QColor color, bool save)
/************************************************
************************************************/
void LxQtPanel::setBackgroundColor(QColor color, bool save)
void LXQtPanel::setBackgroundColor(QColor color, bool save)
{
mBackgroundColor = color;
updateStyleSheet();
@ -806,7 +809,7 @@ void LxQtPanel::setBackgroundColor(QColor color, bool save)
/************************************************
************************************************/
void LxQtPanel::setBackgroundImage(QString path, bool save)
void LXQtPanel::setBackgroundImage(QString path, bool save)
{
mBackgroundImage = path;
updateStyleSheet();
@ -819,7 +822,7 @@ void LxQtPanel::setBackgroundImage(QString path, bool save)
/************************************************
*
************************************************/
void LxQtPanel::setOpacity(int opacity, bool save)
void LXQtPanel::setOpacity(int opacity, bool save)
{
mOpacity = opacity;
updateStyleSheet();
@ -832,7 +835,7 @@ void LxQtPanel::setOpacity(int opacity, bool save)
/************************************************
************************************************/
QRect LxQtPanel::globalGometry() const
QRect LXQtPanel::globalGometry() const
{
return QRect(mapToGlobal(QPoint(0, 0)), this->size());
}
@ -841,7 +844,7 @@ QRect LxQtPanel::globalGometry() const
/************************************************
************************************************/
bool LxQtPanel::event(QEvent *event)
bool LXQtPanel::event(QEvent *event)
{
switch (event->type())
{
@ -896,7 +899,7 @@ bool LxQtPanel::event(QEvent *event)
************************************************/
void LxQtPanel::showEvent(QShowEvent *event)
void LXQtPanel::showEvent(QShowEvent *event)
{
QFrame::showEvent(event);
realign();
@ -906,7 +909,7 @@ void LxQtPanel::showEvent(QShowEvent *event)
/************************************************
************************************************/
void LxQtPanel::showPopupMenu(Plugin *plugin)
void LXQtPanel::showPopupMenu(Plugin *plugin)
{
PopupMenu * menu = new PopupMenu(tr("Panel"), this);
menu->setAttribute(Qt::WA_DeleteOnClose);
@ -930,7 +933,7 @@ void LxQtPanel::showPopupMenu(Plugin *plugin)
menu->addTitle(QIcon(), tr("Panel"));
menu->addAction(XdgIcon::fromTheme(QStringLiteral("configure")),
menu->addAction(XdgIcon::fromTheme(QLatin1String("configure")),
tr("Configure Panel"),
this, SLOT(showConfigDialog())
);
@ -940,7 +943,7 @@ void LxQtPanel::showPopupMenu(Plugin *plugin)
this, SLOT(showAddPluginDialog())
);
LxQtPanelApplication *a = reinterpret_cast<LxQtPanelApplication*>(qApp);
LXQtPanelApplication *a = reinterpret_cast<LXQtPanelApplication*>(qApp);
menu->addAction(XdgIcon::fromTheme(QLatin1String("list-add")),
tr("Add Panel"),
a, SLOT(addNewPanel())
@ -948,7 +951,7 @@ void LxQtPanel::showPopupMenu(Plugin *plugin)
if (a->count() > 1)
{
menu->addAction(XdgIcon::fromTheme(QStringLiteral("list-remove")),
menu->addAction(XdgIcon::fromTheme(QLatin1String("list-remove")),
tr("Remove Panel"),
this, SLOT(userRequestForDeletion())
);
@ -967,7 +970,7 @@ void LxQtPanel::showPopupMenu(Plugin *plugin)
menu->show();
}
Plugin* LxQtPanel::findPlugin(const ILxQtPanelPlugin* iPlugin) const
Plugin* LXQtPanel::findPlugin(const ILXQtPanelPlugin* iPlugin) const
{
Plugin *plugin = nullptr;
for (Plugin *plug : mPlugins->plugins())
@ -979,25 +982,25 @@ Plugin* LxQtPanel::findPlugin(const ILxQtPanelPlugin* iPlugin) const
/************************************************
************************************************/
QRect LxQtPanel::calculatePopupWindowPos(QPoint const & absolutePos, QSize const & windowSize) const
QRect LXQtPanel::calculatePopupWindowPos(QPoint const & absolutePos, QSize const & windowSize) const
{
int x = absolutePos.x(), y = absolutePos.y();
switch (position())
{
case ILxQtPanel::PositionTop:
case ILXQtPanel::PositionTop:
y = globalGometry().bottom();
break;
case ILxQtPanel::PositionBottom:
case ILXQtPanel::PositionBottom:
y = globalGometry().top() - windowSize.height();
break;
case ILxQtPanel::PositionLeft:
case ILXQtPanel::PositionLeft:
x = globalGometry().right();
break;
case ILxQtPanel::PositionRight:
case ILXQtPanel::PositionRight:
x = globalGometry().left() - windowSize.width();
break;
}
@ -1027,7 +1030,7 @@ QRect LxQtPanel::calculatePopupWindowPos(QPoint const & absolutePos, QSize const
/************************************************
************************************************/
QRect LxQtPanel::calculatePopupWindowPos(const ILxQtPanelPlugin *plugin, const QSize &windowSize) const
QRect LXQtPanel::calculatePopupWindowPos(const ILXQtPanelPlugin *plugin, const QSize &windowSize) const
{
Plugin *panel_plugin = findPlugin(plugin);
if (nullptr == panel_plugin)
@ -1040,7 +1043,7 @@ QRect LxQtPanel::calculatePopupWindowPos(const ILxQtPanelPlugin *plugin, const Q
/************************************************
************************************************/
QString LxQtPanel::qssPosition() const
QString LXQtPanel::qssPosition() const
{
return positionToStr(position());
}
@ -1048,7 +1051,7 @@ QString LxQtPanel::qssPosition() const
/************************************************
************************************************/
void LxQtPanel::pluginMoved(Plugin * plug)
void LXQtPanel::pluginMoved(Plugin * plug)
{
//get new position of the moved plugin
bool found{false};
@ -1074,7 +1077,7 @@ void LxQtPanel::pluginMoved(Plugin * plug)
/************************************************
************************************************/
void LxQtPanel::userRequestForDeletion()
void LXQtPanel::userRequestForDeletion()
{
mSettings->beginGroup(mConfigGroup);
QStringList plugins = mSettings->value("plugins").toStringList();
@ -1089,7 +1092,7 @@ void LxQtPanel::userRequestForDeletion()
emit deletedByUser(this);
}
void LxQtPanel::showPanel()
void LXQtPanel::showPanel()
{
if (mHidable)
{
@ -1102,13 +1105,13 @@ void LxQtPanel::showPanel()
}
}
void LxQtPanel::hidePanel()
void LXQtPanel::hidePanel()
{
if (mHidable && !mHidden)
mHideTimer.start();
}
void LxQtPanel::hidePanelWork()
void LXQtPanel::hidePanelWork()
{
if (mHidable && !mHidden && !geometry().contains(QCursor::pos()))
{
@ -1120,7 +1123,7 @@ void LxQtPanel::hidePanelWork()
}
}
void LxQtPanel::setHidable(bool hidable, bool save)
void LXQtPanel::setHidable(bool hidable, bool save)
{
if (mHidable == hidable)
return;
@ -1133,11 +1136,11 @@ void LxQtPanel::setHidable(bool hidable, bool save)
realign();
}
bool LxQtPanel::isPluginSingletonAndRunnig(QString const & pluginId) const
bool LXQtPanel::isPluginSingletonAndRunnig(QString const & pluginId) const
{
Plugin const * plugin = mPlugins->pluginByID(pluginId);
if (nullptr == plugin)
return false;
else
return plugin->iPlugin()->flags().testFlag(ILxQtPanelPlugin::SingleInstance);
return plugin->iPlugin()->flags().testFlag(ILXQtPanelPlugin::SingleInstance);
}

View File

@ -33,6 +33,7 @@
#include <QString>
#include <QTimer>
#include <QPointer>
#include <LXQt/Settings>
#include "ilxqtpanel.h"
#include "lxqtpanelglobals.h"
@ -40,17 +41,17 @@ class QMenu;
class Plugin;
class QAbstractItemModel;
namespace LxQt {
namespace LXQt {
class Settings;
class PluginInfo;
}
class LxQtPanelLayout;
class LXQtPanelLayout;
class ConfigPanelDialog;
class PanelPluginsModel;
/*! \brief The LxQtPanel class provides a single lxqt-panel.
/*! \brief The LXQtPanel class provides a single lxqt-panel.
*/
class LXQT_PANEL_API LxQtPanel : public QFrame, public ILxQtPanel
class LXQT_PANEL_API LXQtPanel : public QFrame, public ILXQtPanel
{
Q_OBJECT
@ -59,6 +60,8 @@ class LXQT_PANEL_API LxQtPanel : public QFrame, public ILxQtPanel
// for configuration dialog
friend class ConfigPanelWidget;
friend class ConfigPluginsWidget;
friend class ConfigPanelDialog;
friend class PanelPluginsModel;
public:
enum Alignment {
@ -67,8 +70,8 @@ public:
AlignmentRight = 1
};
LxQtPanel(const QString &configGroup, QWidget *parent = 0);
virtual ~LxQtPanel();
LXQtPanel(const QString &configGroup, LXQt::Settings *settings, QWidget *parent = 0);
virtual ~LXQtPanel();
QString name() { return mConfigGroup; }
@ -76,19 +79,19 @@ public:
void showPopupMenu(Plugin *plugin = 0);
// ILxQtPanel .........................
ILxQtPanel::Position position() const { return mPosition; }
// ILXQtPanel .........................
ILXQtPanel::Position position() const { return mPosition; }
QRect globalGometry() const;
Plugin *findPlugin(const ILxQtPanelPlugin *iPlugin) const;
Plugin *findPlugin(const ILXQtPanelPlugin *iPlugin) const;
QRect calculatePopupWindowPos(QPoint const & absolutePos, QSize const & windowSize) const;
QRect calculatePopupWindowPos(const ILxQtPanelPlugin *plugin, const QSize &windowSize) const;
QRect calculatePopupWindowPos(const ILXQtPanelPlugin *plugin, const QSize &windowSize) const;
// For QSS properties ..................
QString qssPosition() const;
static bool canPlacedOn(int screenNum, LxQtPanel::Position position);
static QString positionToStr(ILxQtPanel::Position position);
static ILxQtPanel::Position strToPosition(const QString &str, ILxQtPanel::Position defaultValue);
static bool canPlacedOn(int screenNum, LXQtPanel::Position position);
static QString positionToStr(ILXQtPanel::Position position);
static ILXQtPanel::Position strToPosition(const QString &str, ILXQtPanel::Position defaultValue);
// Settings
int panelSize() const { return mPanelSize; }
@ -96,7 +99,7 @@ public:
int lineCount() const { return mLineCount; }
int length() const { return mLength; }
bool lengthInPercents() const { return mLengthInPercents; }
LxQtPanel::Alignment alignment() const { return mAlignment; }
LXQtPanel::Alignment alignment() const { return mAlignment; }
int screenNum() const { return mScreenNum; }
QColor fontColor() const { return mFontColor; };
QColor backgroundColor() const { return mBackgroundColor; };
@ -104,8 +107,6 @@ public:
int opacity() const { return mOpacity; };
bool hidable() const { return mHidable; }
LxQt::Settings *settings() const { return mSettings; }
bool isPluginSingletonAndRunnig(QString const & pluginId) const;
public slots:
@ -119,8 +120,8 @@ public slots:
void setIconSize(int value, bool save);
void setLineCount(int value, bool save);
void setLength(int length, bool inPercents, bool save);
void setPosition(int screen, ILxQtPanel::Position position, bool save);
void setAlignment(LxQtPanel::Alignment value, bool save);
void setPosition(int screen, ILXQtPanel::Position position, bool save);
void setAlignment(LXQtPanel::Alignment value, bool save);
void setFontColor(QColor color, bool save);
void setBackgroundColor(QColor color, bool save);
void setBackgroundImage(QString path, bool save);
@ -132,7 +133,7 @@ public slots:
signals:
void realigned();
void deletedByUser(LxQtPanel *self);
void deletedByUser(LXQtPanel *self);
void pluginAdded();
void pluginRemoved();
@ -142,6 +143,7 @@ protected:
public slots:
void showConfigDialog();
private slots:
void showAddPluginDialog();
void realign();
@ -149,13 +151,13 @@ private slots:
void userRequestForDeletion();
private:
LxQtPanelLayout* mLayout;
LxQt::Settings *mSettings;
QFrame *LxQtPanelWidget;
LXQtPanelLayout* mLayout;
LXQt::Settings *mSettings;
QFrame *LXQtPanelWidget;
QString mConfigGroup;
QScopedPointer<PanelPluginsModel> mPlugins;
int findAvailableScreen(LxQtPanel::Position position);
int findAvailableScreen(LXQtPanel::Position position);
void updateWmStrut();
void loadPlugins();
@ -172,8 +174,9 @@ private:
Alignment mAlignment;
ILxQtPanel::Position mPosition;
int mScreenNum;
ILXQtPanel::Position mPosition;
int mScreenNum; //!< configured screen (user preference)
int mActualScreenNum; //!< panel currently shown at (if the configured screen is not available)
QTimer mDelaySave;
bool mHidable;
bool mHidden;
@ -187,6 +190,9 @@ private:
QPointer<ConfigPanelDialog> mConfigDialog;
void updateStyleSheet();
// settings should be kept private for security
LXQt::Settings *settings() const { return mSettings; }
};

View File

@ -36,19 +36,19 @@
#include <QWindow>
#include <QCommandLineParser>
LxQtPanelApplication::LxQtPanelApplication(int& argc, char** argv)
: LxQt::Application(argc, argv, true)
LXQtPanelApplication::LXQtPanelApplication(int& argc, char** argv)
: LXQt::Application(argc, argv, true)
{
QCoreApplication::setApplicationName(QStringLiteral("lxqt-panel"));
QCoreApplication::setApplicationName(QLatin1String("lxqt-panel"));
QCoreApplication::setApplicationVersion(LXQT_VERSION);
QCommandLineParser parser;
parser.setApplicationDescription(QStringLiteral("LXQt panel"));
parser.setApplicationDescription(QLatin1String("LXQt panel"));
parser.addHelpOption();
parser.addVersionOption();
QCommandLineOption configFileOption(QStringList()
<< QStringLiteral("c") << QStringLiteral("config") << QStringLiteral("configfile"),
<< QLatin1String("c") << QLatin1String("config") << QLatin1String("configfile"),
QCoreApplication::translate("main", "Use alternate configuration file."),
QCoreApplication::translate("main", "Configuration file"));
parser.addOption(configFileOption);
@ -58,17 +58,17 @@ LxQtPanelApplication::LxQtPanelApplication(int& argc, char** argv)
const QString configFile = parser.value(configFileOption);
if (configFile.isEmpty())
mSettings = new LxQt::Settings(QStringLiteral("panel"), this);
mSettings = new LXQt::Settings(QLatin1String("panel"), this);
else
mSettings = new LxQt::Settings(configFile, QSettings::IniFormat, this);
mSettings = new LXQt::Settings(configFile, QSettings::IniFormat, this);
// This is a workaround for Qt 5 bug #40681.
Q_FOREACH(QScreen* screen, screens())
{
connect(screen, &QScreen::destroyed, this, &LxQtPanelApplication::screenDestroyed);
connect(screen, &QScreen::destroyed, this, &LXQtPanelApplication::screenDestroyed);
}
connect(this, &QGuiApplication::screenAdded, this, &LxQtPanelApplication::handleScreenAdded);
connect(this, &QCoreApplication::aboutToQuit, this, &LxQtPanelApplication::cleanup);
connect(this, &QGuiApplication::screenAdded, this, &LXQtPanelApplication::handleScreenAdded);
connect(this, &QCoreApplication::aboutToQuit, this, &LXQtPanelApplication::cleanup);
QStringList panels = mSettings->value("panels").toStringList();
@ -84,19 +84,19 @@ LxQtPanelApplication::LxQtPanelApplication(int& argc, char** argv)
}
}
LxQtPanelApplication::~LxQtPanelApplication()
LXQtPanelApplication::~LXQtPanelApplication()
{
}
void LxQtPanelApplication::cleanup()
void LXQtPanelApplication::cleanup()
{
qDeleteAll(mPanels);
}
void LxQtPanelApplication::addNewPanel()
void LXQtPanelApplication::addNewPanel()
{
QString name("panel_" + QUuid::createUuid().toString());
LxQtPanel *p = addPanel(name);
LXQtPanel *p = addPanel(name);
QStringList panels = mSettings->value("panels").toStringList();
panels << name;
mSettings->setValue("panels", panels);
@ -105,37 +105,37 @@ void LxQtPanelApplication::addNewPanel()
p->showConfigDialog();
}
LxQtPanel* LxQtPanelApplication::addPanel(const QString& name)
LXQtPanel* LXQtPanelApplication::addPanel(const QString& name)
{
LxQtPanel *panel = new LxQtPanel(name);
LXQtPanel *panel = new LXQtPanel(name, mSettings);
mPanels << panel;
connect(panel, SIGNAL(deletedByUser(LxQtPanel*)),
this, SLOT(removePanel(LxQtPanel*)));
//reemit signals
connect(panel, &LxQtPanel::pluginAdded, this, &LxQtPanelApplication::pluginAdded);
connect(panel, &LxQtPanel::pluginRemoved, this, &LxQtPanelApplication::pluginRemoved);
// reemit signals
connect(panel, &LXQtPanel::deletedByUser, this, &LXQtPanelApplication::removePanel);
connect(panel, &LXQtPanel::pluginAdded, this, &LXQtPanelApplication::pluginAdded);
connect(panel, &LXQtPanel::pluginRemoved, this, &LXQtPanelApplication::pluginRemoved);
return panel;
}
void LxQtPanelApplication::handleScreenAdded(QScreen* newScreen)
void LXQtPanelApplication::handleScreenAdded(QScreen* newScreen)
{
// qDebug() << "LxQtPanelApplication::handleScreenAdded" << newScreen;
connect(newScreen, &QScreen::destroyed, this, &LxQtPanelApplication::screenDestroyed);
// qDebug() << "LXQtPanelApplication::handleScreenAdded" << newScreen;
connect(newScreen, &QScreen::destroyed, this, &LXQtPanelApplication::screenDestroyed);
}
void LxQtPanelApplication::reloadPanelsAsNeeded()
void LXQtPanelApplication::reloadPanelsAsNeeded()
{
// NOTE by PCMan: This is a workaround for Qt 5 bug #40681.
// Here we try to re-create the missing panels which are deleted in
// LxQtPanelApplication::screenDestroyed().
// LXQtPanelApplication::screenDestroyed().
// qDebug() << "LxQtPanelApplication::reloadPanelsAsNeeded()";
// qDebug() << "LXQtPanelApplication::reloadPanelsAsNeeded()";
QStringList names = mSettings->value("panels").toStringList();
Q_FOREACH(const QString& name, names)
{
bool found = false;
Q_FOREACH(LxQtPanel* panel, mPanels)
Q_FOREACH(LXQtPanel* panel, mPanels)
{
if(panel->name() == name)
{
@ -153,7 +153,7 @@ void LxQtPanelApplication::reloadPanelsAsNeeded()
qApp->setQuitOnLastWindowClosed(true);
}
void LxQtPanelApplication::screenDestroyed(QObject* screenObj)
void LXQtPanelApplication::screenDestroyed(QObject* screenObj)
{
// NOTE by PCMan: This is a workaround for Qt 5 bug #40681.
// With this very dirty workaround, we can fix lxde/lxde-qt bug #204, #205, and #206.
@ -182,7 +182,7 @@ void LxQtPanelApplication::screenDestroyed(QObject* screenObj)
QScreen* screen = static_cast<QScreen*>(screenObj);
bool reloadNeeded = false;
qApp->setQuitOnLastWindowClosed(false);
Q_FOREACH(LxQtPanel* panel, mPanels)
Q_FOREACH(LXQtPanel* panel, mPanels)
{
QWindow* panelWindow = panel->windowHandle();
if(panelWindow && panelWindow->screen() == screen)
@ -203,7 +203,7 @@ void LxQtPanelApplication::screenDestroyed(QObject* screenObj)
qApp->setQuitOnLastWindowClosed(true);
}
void LxQtPanelApplication::removePanel(LxQtPanel* panel)
void LXQtPanelApplication::removePanel(LXQtPanel* panel)
{
Q_ASSERT(mPanels.contains(panel));
@ -216,7 +216,7 @@ void LxQtPanelApplication::removePanel(LxQtPanel* panel)
panel->deleteLater();
}
bool LxQtPanelApplication::isPluginSingletonAndRunnig(QString const & pluginId) const
bool LXQtPanelApplication::isPluginSingletonAndRunnig(QString const & pluginId) const
{
for (auto const & panel : mPanels)
if (panel->isPluginSingletonAndRunnig(pluginId))

View File

@ -34,20 +34,19 @@
class QScreen;
class LxQtPanel;
namespace LxQt {
class LXQtPanel;
namespace LXQt {
class Settings;
}
class LxQtPanelApplication : public LxQt::Application
class LXQtPanelApplication : public LXQt::Application
{
Q_OBJECT
public:
explicit LxQtPanelApplication(int& argc, char** argv);
~LxQtPanelApplication();
explicit LXQtPanelApplication(int& argc, char** argv);
~LXQtPanelApplication();
int count() { return mPanels.count(); }
LxQt::Settings *settings() { return mSettings; }
bool isPluginSingletonAndRunnig(QString const & pluginId) const;
public slots:
@ -58,12 +57,12 @@ signals:
void pluginRemoved();
private:
QList<LxQtPanel*> mPanels;
QList<LXQtPanel*> mPanels;
LxQtPanel* addPanel(const QString &name);
LXQtPanel* addPanel(const QString &name);
private slots:
void removePanel(LxQtPanel* panel);
void removePanel(LXQtPanel* panel);
void handleScreenAdded(QScreen* newScreen);
void screenDestroyed(QObject* screenObj);
@ -71,7 +70,7 @@ private slots:
void cleanup();
private:
LxQt::Settings *mSettings;
LXQt::Settings *mSettings;
};

View File

@ -409,11 +409,11 @@ void LayoutItemGrid::setHoriz(bool value)
/************************************************
************************************************/
LxQtPanelLayout::LxQtPanelLayout(QWidget *parent) :
LXQtPanelLayout::LXQtPanelLayout(QWidget *parent) :
QLayout(parent),
mLeftGrid(new LayoutItemGrid()),
mRightGrid(new LayoutItemGrid()),
mPosition(ILxQtPanel::PositionBottom),
mPosition(ILXQtPanel::PositionBottom),
mAnimate(false)
{
setMargin(0);
@ -423,7 +423,7 @@ LxQtPanelLayout::LxQtPanelLayout(QWidget *parent) :
/************************************************
************************************************/
LxQtPanelLayout::~LxQtPanelLayout()
LXQtPanelLayout::~LXQtPanelLayout()
{
delete mLeftGrid;
delete mRightGrid;
@ -433,7 +433,7 @@ LxQtPanelLayout::~LxQtPanelLayout()
/************************************************
************************************************/
void LxQtPanelLayout::addItem(QLayoutItem *item)
void LXQtPanelLayout::addItem(QLayoutItem *item)
{
LayoutItemGrid *grid = mRightGrid;
@ -448,7 +448,7 @@ void LxQtPanelLayout::addItem(QLayoutItem *item)
/************************************************
************************************************/
void LxQtPanelLayout::globalIndexToLocal(int index, LayoutItemGrid **grid, int *gridIndex)
void LXQtPanelLayout::globalIndexToLocal(int index, LayoutItemGrid **grid, int *gridIndex)
{
if (index < mLeftGrid->count())
{
@ -464,7 +464,7 @@ void LxQtPanelLayout::globalIndexToLocal(int index, LayoutItemGrid **grid, int *
/************************************************
************************************************/
void LxQtPanelLayout::globalIndexToLocal(int index, LayoutItemGrid **grid, int *gridIndex) const
void LXQtPanelLayout::globalIndexToLocal(int index, LayoutItemGrid **grid, int *gridIndex) const
{
if (index < mLeftGrid->count())
{
@ -481,7 +481,7 @@ void LxQtPanelLayout::globalIndexToLocal(int index, LayoutItemGrid **grid, int *
/************************************************
************************************************/
QLayoutItem *LxQtPanelLayout::itemAt(int index) const
QLayoutItem *LXQtPanelLayout::itemAt(int index) const
{
if (index < 0 || index >= count())
return 0;
@ -497,7 +497,7 @@ QLayoutItem *LxQtPanelLayout::itemAt(int index) const
/************************************************
************************************************/
QLayoutItem *LxQtPanelLayout::takeAt(int index)
QLayoutItem *LXQtPanelLayout::takeAt(int index)
{
if (index < 0 || index >= count())
return 0;
@ -513,7 +513,7 @@ QLayoutItem *LxQtPanelLayout::takeAt(int index)
/************************************************
************************************************/
int LxQtPanelLayout::count() const
int LXQtPanelLayout::count() const
{
return mLeftGrid->count() + mRightGrid->count();
}
@ -522,7 +522,7 @@ int LxQtPanelLayout::count() const
/************************************************
************************************************/
void LxQtPanelLayout::moveItem(int from, int to, bool withAnimation)
void LXQtPanelLayout::moveItem(int from, int to, bool withAnimation)
{
if (from != to)
{
@ -558,7 +558,7 @@ void LxQtPanelLayout::moveItem(int from, int to, bool withAnimation)
/************************************************
************************************************/
QSize LxQtPanelLayout::sizeHint() const
QSize LXQtPanelLayout::sizeHint() const
{
if (!mLeftGrid->isValid())
mLeftGrid->update();
@ -585,7 +585,7 @@ QSize LxQtPanelLayout::sizeHint() const
/************************************************
************************************************/
void LxQtPanelLayout::setGeometry(const QRect &geometry)
void LXQtPanelLayout::setGeometry(const QRect &geometry)
{
if (!mLeftGrid->isValid())
mLeftGrid->update();
@ -611,7 +611,7 @@ void LxQtPanelLayout::setGeometry(const QRect &geometry)
/************************************************
************************************************/
void LxQtPanelLayout::setItemGeometry(QLayoutItem *item, const QRect &geometry, bool withAnimation)
void LXQtPanelLayout::setItemGeometry(QLayoutItem *item, const QRect &geometry, bool withAnimation)
{
Plugin *plugin = qobject_cast<Plugin*>(item->widget());
if (withAnimation && plugin)
@ -631,7 +631,7 @@ void LxQtPanelLayout::setItemGeometry(QLayoutItem *item, const QRect &geometry,
/************************************************
************************************************/
void LxQtPanelLayout::setGeometryHoriz(const QRect &geometry)
void LXQtPanelLayout::setGeometryHoriz(const QRect &geometry)
{
// Calc expFactor for expandable plugins like TaskBar.
double expFactor;
@ -654,7 +654,7 @@ void LxQtPanelLayout::setGeometryHoriz(const QRect &geometry)
}
#if 0
qDebug() << "** LxQtPanelLayout::setGeometryHoriz **************";
qDebug() << "** LXQtPanelLayout::setGeometryHoriz **************";
qDebug() << "geometry: " << geometry;
qDebug() << "Left grid";
@ -747,7 +747,7 @@ void LxQtPanelLayout::setGeometryHoriz(const QRect &geometry)
/************************************************
************************************************/
void LxQtPanelLayout::setGeometryVert(const QRect &geometry)
void LXQtPanelLayout::setGeometryVert(const QRect &geometry)
{
// Calc expFactor for expandable plugins like TaskBar.
double expFactor;
@ -770,7 +770,7 @@ void LxQtPanelLayout::setGeometryVert(const QRect &geometry)
}
#if 0
qDebug() << "** LxQtPanelLayout::setGeometryVert **************";
qDebug() << "** LXQtPanelLayout::setGeometryVert **************";
qDebug() << "geometry: " << geometry;
qDebug() << "Left grid";
@ -862,7 +862,7 @@ void LxQtPanelLayout::setGeometryVert(const QRect &geometry)
/************************************************
************************************************/
void LxQtPanelLayout::invalidate()
void LXQtPanelLayout::invalidate()
{
mLeftGrid->invalidate();
mRightGrid->invalidate();
@ -874,7 +874,7 @@ void LxQtPanelLayout::invalidate()
/************************************************
************************************************/
int LxQtPanelLayout::lineCount() const
int LXQtPanelLayout::lineCount() const
{
return mLeftGrid->colCount();
}
@ -883,7 +883,7 @@ int LxQtPanelLayout::lineCount() const
/************************************************
************************************************/
void LxQtPanelLayout::setLineCount(int value)
void LXQtPanelLayout::setLineCount(int value)
{
mLeftGrid->setColCount(value);
mRightGrid->setColCount(value);
@ -894,7 +894,7 @@ void LxQtPanelLayout::setLineCount(int value)
/************************************************
************************************************/
int LxQtPanelLayout::lineSize() const
int LXQtPanelLayout::lineSize() const
{
return mLeftGrid->lineSize();
}
@ -903,7 +903,7 @@ int LxQtPanelLayout::lineSize() const
/************************************************
************************************************/
void LxQtPanelLayout::setLineSize(int value)
void LXQtPanelLayout::setLineSize(int value)
{
mLeftGrid->setLineSize(value);
mRightGrid->setLineSize(value);
@ -914,7 +914,7 @@ void LxQtPanelLayout::setLineSize(int value)
/************************************************
************************************************/
void LxQtPanelLayout::setPosition(ILxQtPanel::Position value)
void LXQtPanelLayout::setPosition(ILXQtPanel::Position value)
{
mPosition = value;
mLeftGrid->setHoriz(isHorizontal());
@ -925,17 +925,17 @@ void LxQtPanelLayout::setPosition(ILxQtPanel::Position value)
/************************************************
************************************************/
bool LxQtPanelLayout::isHorizontal() const
bool LXQtPanelLayout::isHorizontal() const
{
return mPosition == ILxQtPanel::PositionTop ||
mPosition == ILxQtPanel::PositionBottom;
return mPosition == ILXQtPanel::PositionTop ||
mPosition == ILXQtPanel::PositionBottom;
}
/************************************************
************************************************/
bool LxQtPanelLayout::itemIsSeparate(QLayoutItem *item)
bool LXQtPanelLayout::itemIsSeparate(QLayoutItem *item)
{
if (!item)
return true;
@ -951,7 +951,7 @@ bool LxQtPanelLayout::itemIsSeparate(QLayoutItem *item)
/************************************************
************************************************/
void LxQtPanelLayout::startMovePlugin()
void LXQtPanelLayout::startMovePlugin()
{
Plugin *plugin = qobject_cast<Plugin*>(sender());
if (plugin)
@ -968,7 +968,7 @@ void LxQtPanelLayout::startMovePlugin()
/************************************************
************************************************/
void LxQtPanelLayout::finishMovePlugin()
void LXQtPanelLayout::finishMovePlugin()
{
PluginMoveProcessor *moveProcessor = qobject_cast<PluginMoveProcessor*>(sender());
if (moveProcessor)
@ -983,7 +983,7 @@ void LxQtPanelLayout::finishMovePlugin()
/************************************************
************************************************/
void LxQtPanelLayout::moveUpPlugin(Plugin * plugin)
void LXQtPanelLayout::moveUpPlugin(Plugin * plugin)
{
const int i = indexOf(plugin);
if (0 < i)
@ -993,9 +993,9 @@ void LxQtPanelLayout::moveUpPlugin(Plugin * plugin)
/************************************************
************************************************/
void LxQtPanelLayout::addPlugin(Plugin * plugin)
void LXQtPanelLayout::addPlugin(Plugin * plugin)
{
connect(plugin, &Plugin::startMove, this, &LxQtPanelLayout::startMovePlugin);
connect(plugin, &Plugin::startMove, this, &LXQtPanelLayout::startMovePlugin);
const int prev_count = count();
addWidget(plugin);

View File

@ -43,12 +43,12 @@ class QEvent;
class Plugin;
class LayoutItemGrid;
class LXQT_PANEL_API LxQtPanelLayout : public QLayout
class LXQT_PANEL_API LXQtPanelLayout : public QLayout
{
Q_OBJECT
public:
explicit LxQtPanelLayout(QWidget *parent);
~LxQtPanelLayout();
explicit LXQtPanelLayout(QWidget *parent);
~LXQtPanelLayout();
void addItem(QLayoutItem *item);
QLayoutItem *itemAt(int index) const;
@ -70,8 +70,8 @@ public:
int lineSize() const;
void setLineSize(int value);
ILxQtPanel::Position position() const { return mPosition; }
void setPosition(ILxQtPanel::Position value);
ILXQtPanel::Position position() const { return mPosition; }
void setPosition(ILXQtPanel::Position value);
static bool itemIsSeparate(QLayoutItem *item);
signals:
@ -87,7 +87,7 @@ private:
mutable QSize mMinPluginSize;
LayoutItemGrid *mLeftGrid;
LayoutItemGrid *mRightGrid;
ILxQtPanel::Position mPosition;
ILXQtPanel::Position mPosition;
bool mAnimate;

View File

@ -36,7 +36,7 @@
/************************************************
************************************************/
LxQtPanelPluginConfigDialog::LxQtPanelPluginConfigDialog(QSettings &settings, QWidget *parent) :
LXQtPanelPluginConfigDialog::LXQtPanelPluginConfigDialog(QSettings &settings, QWidget *parent) :
QDialog(parent),
mSettings(settings),
mOldSettings(settings)
@ -47,7 +47,7 @@ LxQtPanelPluginConfigDialog::LxQtPanelPluginConfigDialog(QSettings &settings, QW
/************************************************
************************************************/
LxQtPanelPluginConfigDialog::~LxQtPanelPluginConfigDialog()
LXQtPanelPluginConfigDialog::~LXQtPanelPluginConfigDialog()
{
}
@ -55,7 +55,7 @@ LxQtPanelPluginConfigDialog::~LxQtPanelPluginConfigDialog()
/************************************************
************************************************/
QSettings& LxQtPanelPluginConfigDialog::settings() const
QSettings& LXQtPanelPluginConfigDialog::settings() const
{
return mSettings;
}
@ -65,7 +65,7 @@ QSettings& LxQtPanelPluginConfigDialog::settings() const
/************************************************
************************************************/
void LxQtPanelPluginConfigDialog::dialogButtonsAction(QAbstractButton *btn)
void LXQtPanelPluginConfigDialog::dialogButtonsAction(QAbstractButton *btn)
{
QDialogButtonBox *box = qobject_cast<QDialogButtonBox*>(btn->parent());
@ -84,7 +84,7 @@ void LxQtPanelPluginConfigDialog::dialogButtonsAction(QAbstractButton *btn)
/************************************************
************************************************/
void LxQtPanelPluginConfigDialog::setComboboxIndexByData(QComboBox *comboBox, const QVariant &data, int defaultIndex) const
void LXQtPanelPluginConfigDialog::setComboboxIndexByData(QComboBox *comboBox, const QVariant &data, int defaultIndex) const
{
int index = comboBox ->findData(data);
if (index < 0)

View File

@ -36,12 +36,12 @@
class QComboBox;
class LXQT_PANEL_API LxQtPanelPluginConfigDialog : public QDialog
class LXQT_PANEL_API LXQtPanelPluginConfigDialog : public QDialog
{
Q_OBJECT
public:
explicit LxQtPanelPluginConfigDialog(QSettings &settings, QWidget *parent = 0);
virtual ~LxQtPanelPluginConfigDialog();
explicit LXQtPanelPluginConfigDialog(QSettings &settings, QWidget *parent = 0);
virtual ~LXQtPanelPluginConfigDialog();
QSettings& settings() const;
@ -57,7 +57,7 @@ protected:
private:
QSettings &mSettings;
LxQt::SettingsCache mOldSettings;
LXQt::SettingsCache mOldSettings;
};

View File

@ -36,7 +36,7 @@
int main(int argc, char *argv[])
{
LxQtPanelApplication app(argc, argv);
LXQtPanelApplication app(argc, argv);
return app.exec();
}

View File

@ -38,7 +38,7 @@ Several plugins are loaded by default, the desktop menu and windows workspaces c
By right clickin over there show config setting options for each plugins and also panel itsefl.
.SH AUTOSTART
The module only are showed on \fBLXQt\fR desktop environment, but you can create an autostart action
for you prefered desktop environment.
for you preferred desktop environment.
.SH "REPORTING BUGS"
Report bugs to https://github.com/LXDE/LXQt/issues
.SH "SEE ALSO"

View File

@ -34,7 +34,7 @@
#include <QDebug>
PanelPluginsModel::PanelPluginsModel(LxQtPanel * panel,
PanelPluginsModel::PanelPluginsModel(LXQtPanel * panel,
QString const & namesKey,
QStringList const & desktopDirs,
QObject * parent/* = nullptr*/)
@ -69,9 +69,9 @@ QVariant PanelPluginsModel::data(const QModelIndex & index, int role/* = Qt::Dis
{
case Qt::DisplayRole:
if (plugin.second.isNull())
ret = QStringLiteral("<b>Unknown</b> (%1)").arg(plugin.first);
ret = QString("<b>Unknown</b> (%1)").arg(plugin.first);
else
ret = QStringLiteral("<b>%1</b> (%2)").arg(plugin.second->name(), plugin.first);
ret = QString("<b>%1</b> (%2)").arg(plugin.second->name(), plugin.first);
break;
case Qt::DecorationRole:
if (plugin.second.isNull())
@ -96,7 +96,7 @@ QStringList PanelPluginsModel::pluginNames() const
QStringList names;
for (auto const & p : mPlugins)
names.append(p.first);
return std::move(names);
return names;
}
QList<Plugin *> PanelPluginsModel::plugins() const
@ -105,7 +105,7 @@ QList<Plugin *> PanelPluginsModel::plugins() const
for (auto const & p : mPlugins)
if (!p.second.isNull())
plugins.append(p.second.data());
return std::move(plugins);
return plugins;
}
Plugin* PanelPluginsModel::pluginByName(QString name) const
@ -127,9 +127,9 @@ Plugin const * PanelPluginsModel::pluginByID(QString id) const
return nullptr;
}
void PanelPluginsModel::addPlugin(const LxQt::PluginInfo &desktopFile)
void PanelPluginsModel::addPlugin(const LXQt::PluginInfo &desktopFile)
{
if (dynamic_cast<LxQtPanelApplication const *>(qApp)->isPluginSingletonAndRunnig(desktopFile.id()))
if (dynamic_cast<LXQtPanelApplication const *>(qApp)->isPluginSingletonAndRunnig(desktopFile.id()))
return;
QString name = findNewPluginSettingsGroup(desktopFile.id());
@ -211,7 +211,7 @@ void PanelPluginsModel::loadPlugins(QStringList const & desktopDirs)
continue;
}
LxQt::PluginInfoList list = LxQt::PluginInfo::search(desktopDirs, "LxQtPanel/Plugin", QString("%1.desktop").arg(type));
LXQt::PluginInfoList list = LXQt::PluginInfo::search(desktopDirs, "LXQtPanel/Plugin", QString("%1.desktop").arg(type));
if( !list.count())
{
qWarning() << QString("Plugin \"%1\" not found.").arg(type);
@ -226,12 +226,12 @@ void PanelPluginsModel::loadPlugins(QStringList const & desktopDirs)
}
}
QPointer<Plugin> PanelPluginsModel::loadPlugin(LxQt::PluginInfo const & desktopFile, QString const & settingsGroup)
QPointer<Plugin> PanelPluginsModel::loadPlugin(LXQt::PluginInfo const & desktopFile, QString const & settingsGroup)
{
std::unique_ptr<Plugin> plugin(new Plugin(desktopFile, mPanel->settings()->fileName(), settingsGroup, mPanel));
if (plugin->isLoaded())
{
connect(mPanel, &LxQtPanel::realigned, plugin.get(), &Plugin::realign);
connect(mPanel, &LXQtPanel::realigned, plugin.get(), &Plugin::realign);
connect(plugin.get(), &Plugin::remove,
this, static_cast<void (PanelPluginsModel::*)()>(&PanelPluginsModel::removePlugin));
return plugin.release();
@ -246,9 +246,19 @@ QString PanelPluginsModel::findNewPluginSettingsGroup(const QString &pluginType)
groups.sort();
// Generate new section name
for (int i = 2; true; ++i)
if (!groups.contains(QStringLiteral("%1%2").arg(pluginType).arg(i)))
return QStringLiteral("%1%2").arg(pluginType).arg(i);
QString pluginName = QString("%1").arg(pluginType);
if (!groups.contains(pluginName))
return pluginName;
else
{
for (int i = 2; true; ++i)
{
pluginName = QString("%1%2").arg(pluginType).arg(i);
if (!groups.contains(pluginName))
return pluginName;
}
}
}
void PanelPluginsModel::onActivatedIndex(QModelIndex const & index)
@ -314,7 +324,7 @@ void PanelPluginsModel::onConfigurePlugin()
return;
Plugin * const plugin = mPlugins[mActive.row()].second.data();
if (nullptr != plugin && (ILxQtPanelPlugin::HaveConfigDialog & plugin->iPlugin()->flags()))
if (nullptr != plugin && (ILXQtPanelPlugin::HaveConfigDialog & plugin->iPlugin()->flags()))
plugin->showConfigureDialog();
}

View File

@ -29,20 +29,20 @@
#include <QAbstractListModel>
#include <memory>
namespace LxQt
namespace LXQt
{
class PluginInfo;
struct PluginData;
}
class LxQtPanel;
class LXQtPanel;
class Plugin;
class PanelPluginsModel : public QAbstractListModel
{
Q_OBJECT
public:
PanelPluginsModel(LxQtPanel * panel,
PanelPluginsModel(LXQtPanel * panel,
QString const & namesKey,
QStringList const & desktopDirs,
QObject * parent = nullptr);
@ -73,7 +73,7 @@ signals:
void pluginMovedUp(Plugin * plugin);
public slots:
void addPlugin(const LxQt::PluginInfo &desktopFile);
void addPlugin(const LXQt::PluginInfo &desktopFile);
void removePlugin();
// slots for configuration dialog
@ -88,14 +88,14 @@ private:
private:
void loadPlugins(QStringList const & desktopDirs);
QPointer<Plugin> loadPlugin(LxQt::PluginInfo const & desktopFile, QString const & settingsGroup);
QPointer<Plugin> loadPlugin(LXQt::PluginInfo const & desktopFile, QString const & settingsGroup);
QString findNewPluginSettingsGroup(const QString &pluginType) const;
bool isActiveIndexValid() const;
void removePlugin(pluginslist_t::iterator plugin);
const QString mNamesKey;
pluginslist_t mPlugins;
LxQtPanel * mPanel;
LXQtPanel * mPanel;
QPersistentModelIndex mActive;
};

View File

@ -50,22 +50,32 @@
// statically linked built-in plugins
#include "../plugin-clock/lxqtclock.h" // clock
extern void * loadPluginTranslation_clock_helper;
#include "../plugin-desktopswitch/desktopswitch.h" // desktopswitch
extern void * loadPluginTranslation_desktopswitch_helper;
#include "../plugin-mainmenu/lxqtmainmenu.h" // mainmenu
extern void * loadPluginTranslation_mainmenu_helper;
#include "../plugin-quicklaunch/lxqtquicklaunchplugin.h" // quicklaunch
extern void * loadPluginTranslation_quicklaunch_helper;
#include "../plugin-showdesktop/showdesktop.h" // showdesktop
extern void * loadPluginTranslation_showdesktop_helper;
#include "../plugin-spacer/spacer.h" // spacer
extern void * loadPluginTranslation_spacer_helper;
#include "../plugin-statusnotifier/statusnotifier.h" // statusnotifier
extern void * loadPluginTranslation_statusnotifier_helper;
#include "../plugin-taskbar/lxqttaskbarplugin.h" // taskbar
extern void * loadPluginTranslation_taskbar_helper;
#include "../plugin-tray/lxqttrayplugin.h" // tray
extern void * loadPluginTranslation_tray_helper;
#include "../plugin-worldclock/lxqtworldclock.h" // worldclock
extern void * loadPluginTranslation_worldclock_helper;
QColor Plugin::mMoveMarkerColor= QColor(255, 0, 0, 255);
/************************************************
************************************************/
Plugin::Plugin(const LxQt::PluginInfo &desktopFile, const QString &settingsFile, const QString &settingsGroup, LxQtPanel *panel) :
Plugin::Plugin(const LXQt::PluginInfo &desktopFile, const QString &settingsFile, const QString &settingsGroup, LXQtPanel *panel) :
QFrame(panel),
mDesktopFile(desktopFile),
mPluginLoader(0),
@ -76,7 +86,7 @@ Plugin::Plugin(const LxQt::PluginInfo &desktopFile, const QString &settingsFile,
mPanel(panel)
{
mSettings = new LxQt::Settings(settingsFile, QSettings::IniFormat, this);
mSettings = new LXQt::Settings(settingsFile, QSettings::IniFormat, this);
connect(mSettings, SIGNAL(settingsChanged()), this, SLOT(settingsChanged()));
mSettings->beginGroup(settingsGroup);
@ -90,7 +100,7 @@ Plugin::Plugin(const LxQt::PluginInfo &desktopFile, const QString &settingsFile,
dirs << PLUGIN_DIR;
bool found = false;
if(ILxQtPanelPluginLibrary const * pluginLib = findStaticPlugin(desktopFile.id()))
if(ILXQtPanelPluginLibrary const * pluginLib = findStaticPlugin(desktopFile.id()))
{
// this is a static plugin
found = true;
@ -119,20 +129,17 @@ Plugin::Plugin(const LxQt::PluginInfo &desktopFile, const QString &settingsFile,
return;
}
// Load plugin translations
LxQt::Translator::translatePlugin(desktopFile.id(), QLatin1String("lxqt-panel"));
setObjectName(mPlugin->themeId() + "Plugin");
// plugin handle for easy context menu
setProperty("NeedsHandle", mPlugin->flags().testFlag(ILxQtPanelPlugin::NeedsHandle));
setProperty("NeedsHandle", mPlugin->flags().testFlag(ILXQtPanelPlugin::NeedsHandle));
QString s = mSettings->value("alignment").toString();
// Retrun default value
if (s.isEmpty())
{
mAlignment = (mPlugin->flags().testFlag(ILxQtPanelPlugin::PreferRightAlignment)) ?
mAlignment = (mPlugin->flags().testFlag(ILXQtPanelPlugin::PreferRightAlignment)) ?
Plugin::AlignRight :
Plugin::AlignLeft;
}
@ -184,70 +191,72 @@ void Plugin::setAlignment(Plugin::Alignment alignment)
namespace
{
//helper types for static plugins storage & binary search
typedef std::unique_ptr<ILxQtPanelPluginLibrary> plugin_ptr_t;
typedef std::pair<QString, plugin_ptr_t > plugin_pair_t;
typedef std::unique_ptr<ILXQtPanelPluginLibrary> plugin_ptr_t;
typedef std::tuple<QString, plugin_ptr_t, void *> plugin_tuple_t;
//NOTE: Please keep the plugins sorted by name while adding new plugins.
static plugin_pair_t const static_plugins[] = {
//NOTE2: we need to reference some (dummy) symbol from (autogenerated) LXQtPluginTranslationLoader.cpp
// to be not stripped (as unused/unreferenced) in static linking time
static plugin_tuple_t const static_plugins[] = {
#if defined(WITH_CLOCK_PLUGIN)
{ QStringLiteral("clock"), plugin_ptr_t{new LxQtClockPluginLibrary} },// clock
std::make_tuple(QLatin1String("clock"), plugin_ptr_t{new LXQtClockPluginLibrary}, loadPluginTranslation_clock_helper),// clock
#endif
#if defined(WITH_DESKTOPSWITCH_PLUGIN)
{ QStringLiteral("desktopswitch"), plugin_ptr_t{new DesktopSwitchPluginLibrary} },// desktopswitch
std::make_tuple(QLatin1String("desktopswitch"), plugin_ptr_t{new DesktopSwitchPluginLibrary}, loadPluginTranslation_desktopswitch_helper),// desktopswitch
#endif
#if defined(WITH_MAINMENU_PLUGIN)
{ QStringLiteral("mainmenu"), plugin_ptr_t{new LxQtMainMenuPluginLibrary} },// mainmenu
std::make_tuple(QLatin1String("mainmenu"), plugin_ptr_t{new LXQtMainMenuPluginLibrary}, loadPluginTranslation_mainmenu_helper),// mainmenu
#endif
#if defined(WITH_QUICKLAUNCH_PLUGIN)
{ QStringLiteral("quicklaunch"), plugin_ptr_t{new LxQtQuickLaunchPluginLibrary} },// quicklaunch
std::make_tuple(QLatin1String("quicklaunch"), plugin_ptr_t{new LXQtQuickLaunchPluginLibrary}, loadPluginTranslation_quicklaunch_helper),// quicklaunch
#endif
#if defined(WITH_SHOWDESKTOP_PLUGIN)
{ QStringLiteral("showdesktop"), plugin_ptr_t{new ShowDesktopLibrary} },// showdesktop
std::make_tuple(QLatin1String("showdesktop"), plugin_ptr_t{new ShowDesktopLibrary}, loadPluginTranslation_showdesktop_helper),// showdesktop
#endif
#if defined(WITH_SPACER_PLUGIN)
{ QStringLiteral("spacer"), plugin_ptr_t{new SpacerPluginLibrary} },// spacer
std::make_tuple(QLatin1String("spacer"), plugin_ptr_t{new SpacerPluginLibrary}, loadPluginTranslation_spacer_helper),// spacer
#endif
#if defined(WITH_STATUSNOTIFIER_PLUGIN)
{ QStringLiteral("statusnotifier"), plugin_ptr_t{new StatusNotifierLibrary} },// statusnotifier
std::make_tuple(QLatin1String("statusnotifier"), plugin_ptr_t{new StatusNotifierLibrary}, loadPluginTranslation_statusnotifier_helper),// statusnotifier
#endif
#if defined(WITH_TASKBAR_PLUGIN)
{ QStringLiteral("taskbar"), plugin_ptr_t{new LxQtTaskBarPluginLibrary} },// taskbar
std::make_tuple(QLatin1String("taskbar"), plugin_ptr_t{new LXQtTaskBarPluginLibrary}, loadPluginTranslation_taskbar_helper),// taskbar
#endif
#if defined(WITH_TRAY_PLUGIN)
{ QStringLiteral("tray"), plugin_ptr_t{new LxQtTrayPluginLibrary} },// tray
std::make_tuple(QLatin1String("tray"), plugin_ptr_t{new LXQtTrayPluginLibrary}, loadPluginTranslation_tray_helper),// tray
#endif
#if defined(WITH_WORLDCLOCK_PLUGIN)
{ QStringLiteral("worldclock"), plugin_ptr_t{new LxQtWorldClockLibrary} },// worldclock
std::make_tuple(QLatin1String("worldclock"), plugin_ptr_t{new LXQtWorldClockLibrary}, loadPluginTranslation_worldclock_helper),// worldclock
#endif
};
static constexpr plugin_pair_t const * const plugins_begin = static_plugins;
static constexpr plugin_pair_t const * const plugins_end = static_plugins + sizeof (static_plugins) / sizeof (static_plugins[0]);
static constexpr plugin_tuple_t const * const plugins_begin = static_plugins;
static constexpr plugin_tuple_t const * const plugins_end = static_plugins + sizeof (static_plugins) / sizeof (static_plugins[0]);
struct assert_helper
{
assert_helper()
{
Q_ASSERT(std::is_sorted(plugins_begin, plugins_end
, [] (plugin_pair_t const & p1, plugin_pair_t const & p2) -> bool { return p1.first < p2.first; }));
, [] (plugin_tuple_t const & p1, plugin_tuple_t const & p2) -> bool { return std::get<0>(p1) < std::get<0>(p2); }));
}
};
static assert_helper h;
}
ILxQtPanelPluginLibrary const * Plugin::findStaticPlugin(const QString &libraryName)
ILXQtPanelPluginLibrary const * Plugin::findStaticPlugin(const QString &libraryName)
{
// find a static plugin library by name -> binary search
plugin_pair_t const * plugin = std::lower_bound(plugins_begin, plugins_end, libraryName
, [] (plugin_pair_t const & plugin, QString const & name) -> bool { return plugin.first < name; });
if (plugins_end != plugin && libraryName == plugin->first)
return plugin->second.get();
plugin_tuple_t const * plugin = std::lower_bound(plugins_begin, plugins_end, libraryName
, [] (plugin_tuple_t const & plugin, QString const & name) -> bool { return std::get<0>(plugin) < name; });
if (plugins_end != plugin && libraryName == std::get<0>(*plugin))
return std::get<1>(*plugin).get();
return nullptr;
}
// load a plugin from a library
bool Plugin::loadLib(ILxQtPanelPluginLibrary const * pluginLib)
bool Plugin::loadLib(ILXQtPanelPluginLibrary const * pluginLib)
{
ILxQtPanelPluginStartupInfo startupInfo;
ILXQtPanelPluginStartupInfo startupInfo;
startupInfo.settings = mSettings;
startupInfo.desktopFile = &mDesktopFile;
startupInfo.lxqtPanel = mPanel;
@ -255,7 +264,7 @@ bool Plugin::loadLib(ILxQtPanelPluginLibrary const * pluginLib)
mPlugin = pluginLib->instance(startupInfo);
if (!mPlugin)
{
qWarning() << QString("Can't load plugin \"%1\". Plugin can't build ILxQtPanelPlugin.").arg(mPluginLoader->fileName());
qWarning() << QString("Can't load plugin \"%1\". Plugin can't build ILXQtPanelPlugin.").arg(mPluginLoader->fileName());
return false;
}
@ -286,10 +295,10 @@ bool Plugin::loadModule(const QString &libraryName)
return false;
}
ILxQtPanelPluginLibrary* pluginLib= qobject_cast<ILxQtPanelPluginLibrary*>(obj);
ILXQtPanelPluginLibrary* pluginLib= qobject_cast<ILXQtPanelPluginLibrary*>(obj);
if (!pluginLib)
{
qWarning() << QString("Can't load plugin \"%1\". Plugin is not a ILxQtPanelPluginLibrary.").arg(mPluginLoader->fileName());
qWarning() << QString("Can't load plugin \"%1\". Plugin is not a ILXQtPanelPluginLibrary.").arg(mPluginLoader->fileName());
delete obj;
return false;
}
@ -356,11 +365,11 @@ void Plugin::mousePressEvent(QMouseEvent *event)
switch (event->button())
{
case Qt::LeftButton:
mPlugin->activated(ILxQtPanelPlugin::Trigger);
mPlugin->activated(ILXQtPanelPlugin::Trigger);
break;
case Qt::MidButton:
mPlugin->activated(ILxQtPanelPlugin::MiddleClick);
mPlugin->activated(ILXQtPanelPlugin::MiddleClick);
break;
default:
@ -374,7 +383,7 @@ void Plugin::mousePressEvent(QMouseEvent *event)
************************************************/
void Plugin::mouseDoubleClickEvent(QMouseEvent*)
{
mPlugin->activated(ILxQtPanelPlugin::DoubleClick);
mPlugin->activated(ILXQtPanelPlugin::DoubleClick);
}
@ -396,10 +405,10 @@ QMenu *Plugin::popupMenu() const
QString name = this->name().replace("&", "&&");
QMenu* menu = new QMenu(windowTitle());
if (mPlugin->flags().testFlag(ILxQtPanelPlugin::HaveConfigDialog))
if (mPlugin->flags().testFlag(ILXQtPanelPlugin::HaveConfigDialog))
{
QAction* configAction = new QAction(
XdgIcon::fromTheme(QStringLiteral("preferences-other")),
XdgIcon::fromTheme(QLatin1String("preferences-other")),
tr("Configure \"%1\"").arg(name), menu);
menu->addAction(configAction);
connect(configAction, SIGNAL(triggered()), this, SLOT(showConfigureDialog()));
@ -412,7 +421,7 @@ QMenu *Plugin::popupMenu() const
menu->addSeparator();
QAction* removeAction = new QAction(
XdgIcon::fromTheme(QStringLiteral("list-remove")),
XdgIcon::fromTheme(QLatin1String("list-remove")),
tr("Remove \"%1\"").arg(name), menu);
menu->addAction(removeAction);
connect(removeAction, SIGNAL(triggered()), this, SLOT(requestRemove()));

View File

@ -37,9 +37,9 @@
class QPluginLoader;
class QSettings;
class ILxQtPanelPlugin;
class ILxQtPanelPluginLibrary;
class LxQtPanel;
class ILXQtPanelPlugin;
class ILXQtPanelPluginLibrary;
class LXQtPanel;
class QMenu;
@ -55,7 +55,7 @@ public:
};
explicit Plugin(const LxQt::PluginInfo &desktopFile, const QString &settingsFile, const QString &settingsGroup, LxQtPanel *panel);
explicit Plugin(const LXQt::PluginInfo &desktopFile, const QString &settingsFile, const QString &settingsGroup, LXQtPanel *panel);
~Plugin();
bool isLoaded() const { return mPlugin != 0; }
@ -67,9 +67,9 @@ public:
void saveSettings();
QMenu* popupMenu() const;
const ILxQtPanelPlugin * iPlugin() const { return mPlugin; }
const ILXQtPanelPlugin * iPlugin() const { return mPlugin; }
const LxQt::PluginInfo desktopFile() const { return mDesktopFile; }
const LXQt::PluginInfo desktopFile() const { return mDesktopFile; }
bool isSeparate() const;
bool isExpandable() const;
@ -98,19 +98,19 @@ protected:
void showEvent(QShowEvent *event);
private:
bool loadLib(ILxQtPanelPluginLibrary const * pluginLib);
bool loadLib(ILXQtPanelPluginLibrary const * pluginLib);
bool loadModule(const QString &libraryName);
ILxQtPanelPluginLibrary const * findStaticPlugin(const QString &libraryName);
ILXQtPanelPluginLibrary const * findStaticPlugin(const QString &libraryName);
const LxQt::PluginInfo mDesktopFile;
const LXQt::PluginInfo mDesktopFile;
QByteArray calcSettingsHash();
QPluginLoader *mPluginLoader;
ILxQtPanelPlugin *mPlugin;
ILXQtPanelPlugin *mPlugin;
QWidget *mPluginWidget;
Alignment mAlignment;
QSettings *mSettings;
QString mSettingsGroup;
LxQtPanel *mPanel;
LXQtPanel *mPanel;
QByteArray mSettingsHash;
static QColor mMoveMarkerColor;
QString mName;

View File

@ -35,7 +35,7 @@
/************************************************
************************************************/
PluginMoveProcessor::PluginMoveProcessor(LxQtPanelLayout *layout, Plugin *plugin):
PluginMoveProcessor::PluginMoveProcessor(LXQtPanelLayout *layout, Plugin *plugin):
QWidget(plugin),
mLayout(layout),
mPlugin(plugin)
@ -108,8 +108,8 @@ void PluginMoveProcessor::mouseMoveEvent(QMouseEvent *event)
}
bool plugSep = mPlugin->isSeparate();
bool prevSep = LxQtPanelLayout::itemIsSeparate(prevItem);
bool nextSep = LxQtPanelLayout::itemIsSeparate(nextItem);
bool prevSep = LXQtPanelLayout::itemIsSeparate(prevItem);
bool nextSep = LXQtPanelLayout::itemIsSeparate(nextItem);
if (!nextItem)
{
@ -178,13 +178,13 @@ PluginMoveProcessor::MousePosInfo PluginMoveProcessor::itemByMousePos(const QPoi
ret.item = item;
if (mLayout->isHorizontal())
{
ret.after = LxQtPanelLayout::itemIsSeparate(item) ?
ret.after = LXQtPanelLayout::itemIsSeparate(item) ?
mouse.x() > itemRect.center().x() :
mouse.y() > itemRect.center().y() ;
}
else
{
ret.after = LxQtPanelLayout::itemIsSeparate(item) ?
ret.after = LXQtPanelLayout::itemIsSeparate(item) ?
mouse.y() > itemRect.center().y() :
mouse.x() > itemRect.center().x() ;
}

View File

@ -35,7 +35,7 @@
#include "plugin.h"
#include "lxqtpanelglobals.h"
class LxQtPanelLayout;
class LXQtPanelLayout;
class QLayoutItem;
@ -43,7 +43,7 @@ class LXQT_PANEL_API PluginMoveProcessor : public QWidget
{
Q_OBJECT
public:
explicit PluginMoveProcessor(LxQtPanelLayout *layout, Plugin *plugin);
explicit PluginMoveProcessor(LXQtPanelLayout *layout, Plugin *plugin);
~PluginMoveProcessor();
Plugin *plugin() const { return mPlugin; }
@ -80,7 +80,7 @@ private:
bool after;
};
LxQtPanelLayout *mLayout;
LXQtPanelLayout *mLayout;
Plugin *mPlugin;
int mDestIndex;

View File

@ -284,7 +284,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="912"/>
<location filename="../lxqtpanel.cpp" line="931"/>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">تهيئة</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">تهيئة اللوحة</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Nastavit</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Nastavit panel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Nastavit</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Nastavit panel</translation>

View File

@ -238,7 +238,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -272,7 +272,7 @@
</message>
</context>
<context>
<name>LxQtPanelPluginPrivate</name>
<name>LXQtPanelPluginPrivate</name>
<message>
<source>Configure</source>
<translation type="vanished">Indstil</translation>
@ -287,7 +287,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Panel</source>
<translation type="vanished">Panel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Indstil</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Indstil panel</translation>

View File

@ -284,7 +284,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="912"/>
<location filename="../lxqtpanel.cpp" line="931"/>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1" language="el_GR">
<TS version="2.1" language="el">
<context>
<name>ConfigPanelDialog</name>
<message>
@ -91,7 +91,7 @@
<location filename="../config/configpaneldialog.cpp" line="80"/>
<location filename="../config/configpaneldialog.cpp" line="86"/>
<source>Configure Panel</source>
<translation type="unfinished"></translation>
<translation>Διαμόρφωση του πίνακα</translation>
</message>
</context>
<context>
@ -99,186 +99,186 @@
<message>
<location filename="../config/configpaneldialog.ui" line="20"/>
<source>Configure panel</source>
<translation type="unfinished">Διαμόρφωση πίνακα</translation>
<translation>Διαμόρφωση του πίνακα</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="32"/>
<source>Size</source>
<translation type="unfinished"></translation>
<translation>Μέγεθος</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="41"/>
<source>Size:</source>
<translation type="unfinished">Μέγεθος:</translation>
<translation>Μέγεθος:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="48"/>
<location filename="../config/configpaneldialog.ui" line="82"/>
<source> px</source>
<translation type="unfinished"></translation>
<translation> εικ</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="58"/>
<source>Icon size:</source>
<translation type="unfinished"></translation>
<translation>Μέγεθος εικονιδίων:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="65"/>
<source>Length:</source>
<translation type="unfinished">Μήκος:</translation>
<translation>Μήκος:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="110"/>
<source>&lt;p&gt;Negative pixel value sets the panel length to that many pixels less than available screen space.&lt;/p&gt;&lt;p/&gt;&lt;p&gt;&lt;i&gt;E.g. &quot;Length&quot; set to -100px, screen size is 1000px, then real panel length will be 900 px.&lt;/i&gt;&lt;/p&gt;</source>
<translation type="unfinished"></translation>
<translation>&lt;p&gt;Μια αρνητική τιμή εικονοστοιχείων θέτει το μήκος του πίνακα σε τόσα εικονοστοιχεία λιγότερο από τον διαθέσιμο χώρο της οθόνης.&lt;/p&gt;&lt;p/&gt;&lt;p&gt;&lt;i&gt;Π.χ. θέτοντας το «Μήκος» σε -100εικ, και με μέγεθος οθόνης 1000εικ, τότε το πραγματικό μήκος του πίνακα θα είναι 900 εικ.&lt;/i&gt;&lt;/p&gt;</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="124"/>
<source>%</source>
<translation type="unfinished">%</translation>
<translation>%</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="129"/>
<source>px</source>
<translation type="unfinished">px</translation>
<translation>εικ</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="140"/>
<source>Rows count:</source>
<translation type="unfinished"></translation>
<translation>Πλήθος γραμμών:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="172"/>
<source>Alignment &amp;&amp; position</source>
<translation type="unfinished"></translation>
<translation>Στοίχιση &amp;&amp; θέση</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="182"/>
<location filename="../config/configpaneldialog.cpp" line="234"/>
<source>Left</source>
<translation type="unfinished">Αριστερά</translation>
<translation>Αριστερά</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="187"/>
<location filename="../config/configpaneldialog.cpp" line="235"/>
<location filename="../config/configpaneldialog.cpp" line="241"/>
<source>Center</source>
<translation type="unfinished">Κέντρο</translation>
<translation>Κέντρο</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="192"/>
<location filename="../config/configpaneldialog.cpp" line="236"/>
<source>Right</source>
<translation type="unfinished">Δεξιά</translation>
<translation>Δεξιά</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="200"/>
<source>Alignment:</source>
<translation type="unfinished">Στοίχιση:</translation>
<translation>Στοίχιση:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="210"/>
<source>Position:</source>
<translation type="unfinished">Θέση:</translation>
<translation>Θέση:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="217"/>
<source>Auto-hide</source>
<translation type="unfinished"></translation>
<translation>Αυτόματη απόκρυψη</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="233"/>
<source>Styling</source>
<translation type="unfinished"></translation>
<translation>Ύφος</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="239"/>
<source>Custom font color:</source>
<translation type="unfinished"></translation>
<translation>Προσαρμοσμένο χρώμα γραμματοσειράς:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="246"/>
<source>Custom background image:</source>
<translation type="unfinished"></translation>
<translation>Προσαρμοσμένη εικόνα ταπετσαρίας:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="260"/>
<source>Custom background color:</source>
<translation type="unfinished"></translation>
<translation>Προσαρμοσμένο χρώμα ταπετσαρίας:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="351"/>
<source>Opacity</source>
<translation type="unfinished"></translation>
<translation>Αδιαφάνεια</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="200"/>
<source>Top of desktop</source>
<translation type="unfinished">Επάνω στην επιφάνεια εργασίας</translation>
<translation>Στην κορυφή της επιφάνεια εργασίας</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="201"/>
<source>Left of desktop</source>
<translation type="unfinished">Αριστερά στην επιφάνεια εργασίας</translation>
<translation>Στα αριστερά της επιφάνειας εργασίας</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="202"/>
<source>Right of desktop</source>
<translation type="unfinished">Δεξιά στην επιφάνεια εργασίας</translation>
<translation>Στα δεξιά της επιφάνειας εργασίας</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="203"/>
<source>Bottom of desktop</source>
<translation type="unfinished">Κάτω στην επιφάνεια εργασίας</translation>
<translation>Στη βάση της επιφάνειας εργασίας</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="212"/>
<source>Top of desktop %1</source>
<translation type="unfinished">Επάνω στην επιφάνεια εργασίας %1</translation>
<translation>Στην κορυφή της επιφάνειας εργασίας %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="213"/>
<source>Left of desktop %1</source>
<translation type="unfinished">Αριστερά στην επιφάνεια εργασίας %1</translation>
<translation>Στα αριστερά της επιφάνειας εργασίας %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="214"/>
<source>Right of desktop %1</source>
<translation type="unfinished">Δεξιά στην επιφάνεια εργασίας %1</translation>
<translation>Στα δεξιά της επιφάνειας εργασίας %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="215"/>
<source>Bottom of desktop %1</source>
<translation type="unfinished">Κάτω στην επιφάνεια εργασίας %1</translation>
<translation>Στη βάση της επιφάνειας εργασίας %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="240"/>
<source>Top</source>
<translation type="unfinished"></translation>
<translation>Κορυφή</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="242"/>
<source>Bottom</source>
<translation type="unfinished"></translation>
<translation>Βάση</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="397"/>
<location filename="../config/configpaneldialog.cpp" line="411"/>
<source>Pick color</source>
<translation type="unfinished"></translation>
<translation>Επιλέξτε το χρώμα</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="431"/>
<source>Images (*.png *.gif *.jpg)</source>
<translation type="unfinished"></translation>
<translation>Εικόνες (*.png *.gif *.jpg)</translation>
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
<translation type="unfinished"></translation>
<translation>Προσθήκη γραφικών συστατικών στον πίνακα</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="951"/>
@ -289,52 +289,52 @@
<message>
<location filename="../lxqtpanel.cpp" line="973"/>
<source>Configure Panel...</source>
<translation type="unfinished"></translation>
<translation>Διαμόρφωση του πίνακα...</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="978"/>
<source>Add Panel Widgets...</source>
<translation type="unfinished"></translation>
<translation>Προσθήκη γραφικών συστατικών στον πίνακα...</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="984"/>
<source>Add Panel</source>
<translation type="unfinished"></translation>
<translation>Προσθήκη πίνακα</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="991"/>
<source>Remove Panel</source>
<translation type="unfinished"></translation>
<translation>Αφαίρεση πίνακα</translation>
</message>
<message>
<source>Configure panel...</source>
<translation type="vanished">Διαμόρφωση πίνακα...</translation>
<translation>Διαμόρφωση του πίνακα...</translation>
</message>
<message>
<source>Add plugins ...</source>
<translation type="vanished">Προσθήκη επεκτάσεων...</translation>
<translation>Προσθήκη πρόσθετων...</translation>
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Διαμόρφωση</translation>
<translation>Διαμόρφωση</translation>
</message>
<message>
<source>Move</source>
<translation type="vanished">Μετακίνηση</translation>
<translation>Μετακίνηση</translation>
</message>
<message>
<source>Remove</source>
<translation type="vanished">Αφαίρεση</translation>
<translation>Αφαίρεση</translation>
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Διαμόρφωση πίνακα</translation>
<translation>Διαμόρφωση του πίνακα</translation>
</message>
</context>
<context>
@ -342,17 +342,17 @@
<message>
<location filename="../plugin.cpp" line="395"/>
<source>Configure &quot;%1&quot;</source>
<translation type="unfinished"></translation>
<translation>Διαμόρφωση του «%1»</translation>
</message>
<message>
<location filename="../plugin.cpp" line="400"/>
<source>Move &quot;%1&quot;</source>
<translation type="unfinished"></translation>
<translation>Μετακίνηση του «%1»</translation>
</message>
<message>
<location filename="../plugin.cpp" line="408"/>
<source>Remove &quot;%1&quot;</source>
<translation type="unfinished"></translation>
<translation>Αφαίρεση του «%1»</translation>
</message>
</context>
</TS>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -284,7 +284,7 @@
<location filename="../lxqtpanel.cpp" line="951"/>
<location filename="../lxqtpanel.cpp" line="970"/>
<source>Panel</source>
<translation>Agordoj de muso por LxQto</translation>
<translation>Agordoj de muso por LXQto</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="973"/>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Agordi</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Agordi panelon</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configurar</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configurar panel</translation>

View File

@ -190,7 +190,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -224,7 +224,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Panel</source>
<translation type="vanished">Panel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configurar</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configurar panel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Konfiguratu</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Konfiguratu panela</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Muokkaa</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Muokkaa paneelia</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configurer</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configurer le tableau de bord</translation>

View File

@ -222,7 +222,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -222,7 +222,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -198,7 +198,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -190,7 +190,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -184,7 +184,7 @@
<message>
<location filename="../config/configpaneldialog.ui" line="217"/>
<source>Auto-hide</source>
<translation type="unfinished"></translation>
<translation>Nascondi automaticamente</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="233"/>
@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -289,7 +289,7 @@
<message>
<location filename="../lxqtpanel.cpp" line="973"/>
<source>Configure Panel...</source>
<translation>Configura pannello...</translation>
<translation>Configura panello...</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="978"/>
@ -317,7 +317,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configura</translation>
@ -332,7 +332,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configura pannello</translation>

View File

@ -1,359 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1" language="it_IT">
<context>
<name>ConfigPanelDialog</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configura il pannello</translation>
</message>
<message>
<source>Panel size</source>
<translation type="vanished">Dimensione pannello</translation>
</message>
<message>
<source>Size:</source>
<translation type="vanished">Dimensione:</translation>
</message>
<message>
<source>px</source>
<translation type="vanished">px</translation>
</message>
<message>
<source>Use automatic sizing</source>
<translation type="vanished">Usa dimensionamento automatico</translation>
</message>
<message>
<source>Panel length &amp;&amp; position</source>
<translation type="vanished">Lunghezza e posizione del pannello</translation>
</message>
<message>
<source>Left</source>
<translation type="vanished">Sinistra</translation>
</message>
<message>
<source>Center</source>
<translation type="vanished">Centro</translation>
</message>
<message>
<source>Right</source>
<translation type="vanished">Destra</translation>
</message>
<message>
<source>%</source>
<translation type="vanished">%</translation>
</message>
<message>
<source>Alignment:</source>
<translation type="vanished">Allineamento:</translation>
</message>
<message>
<source>Length:</source>
<translation type="vanished">Lunghezza:</translation>
</message>
<message>
<source>Position:</source>
<translation type="vanished">Posizione:</translation>
</message>
<message>
<source>Top of desktop</source>
<translation type="vanished">Alto del desktop</translation>
</message>
<message>
<source>Left of desktop</source>
<translation type="vanished">Sinistra del desktop</translation>
</message>
<message>
<source>Right of desktop</source>
<translation type="vanished">Destra del desktop</translation>
</message>
<message>
<source>Bottom of desktop</source>
<translation type="vanished">Basso del desktop</translation>
</message>
<message>
<source>Top of desktop %1</source>
<translation type="vanished">Alto del desktop %1</translation>
</message>
<message>
<source>Left of desktop %1</source>
<translation type="vanished">Sinistra del desktop %1</translation>
</message>
<message>
<source>Right of desktop %1</source>
<translation type="vanished">Destra del desktop %1</translation>
</message>
<message>
<source>Bottom of desktop %1</source>
<translation type="vanished">Basso del desktop %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="80"/>
<location filename="../config/configpaneldialog.cpp" line="86"/>
<source>Configure Panel</source>
<translation>Configura panello</translation>
</message>
</context>
<context>
<name>ConfigPanelWidget</name>
<message>
<location filename="../config/configpaneldialog.ui" line="20"/>
<source>Configure panel</source>
<translation>Configura panello</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="32"/>
<source>Size</source>
<translation>Dimensione</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="41"/>
<source>Size:</source>
<translation>Dimensione:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="48"/>
<location filename="../config/configpaneldialog.ui" line="82"/>
<source> px</source>
<translation></translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="58"/>
<source>Icon size:</source>
<translation>Dimensione icone:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="65"/>
<source>Length:</source>
<translation>Lunghezza:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="110"/>
<source>&lt;p&gt;Negative pixel value sets the panel length to that many pixels less than available screen space.&lt;/p&gt;&lt;p/&gt;&lt;p&gt;&lt;i&gt;E.g. &quot;Length&quot; set to -100px, screen size is 1000px, then real panel length will be 900 px.&lt;/i&gt;&lt;/p&gt;</source>
<translation>&lt;p&gt;Valori negativi impongano una lunghezza del panello di quel numero di pixel meno dello spazio disponibile. &lt;/p&gt;&lt;p/&gt;&lt;p&gt;&lt;i&gt;Esempio: -100px e schermo di 1280px = 1180px&lt;/i&gt;&lt;/p&gt;</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="124"/>
<source>%</source>
<translation>%</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="129"/>
<source>px</source>
<translation>px</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="140"/>
<source>Rows count:</source>
<translation>Numero righe:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="172"/>
<source>Alignment &amp;&amp; position</source>
<translation>Allineamento e posizione</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="182"/>
<location filename="../config/configpaneldialog.cpp" line="234"/>
<source>Left</source>
<translation>Sinistra</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="187"/>
<location filename="../config/configpaneldialog.cpp" line="235"/>
<location filename="../config/configpaneldialog.cpp" line="241"/>
<source>Center</source>
<translation>Centro</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="192"/>
<location filename="../config/configpaneldialog.cpp" line="236"/>
<source>Right</source>
<translation>Destra</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="200"/>
<source>Alignment:</source>
<translation>Allineamento:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="210"/>
<source>Position:</source>
<translation>Posizione:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="217"/>
<source>Auto-hide</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="233"/>
<source>Styling</source>
<translation>Aspetto</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="239"/>
<source>Custom font color:</source>
<translation>Colore carattere personalizzato:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="246"/>
<source>Custom background image:</source>
<translation>Immagine sfondo:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="260"/>
<source>Custom background color:</source>
<translation>Colore sfondo personalizzato:</translation>
</message>
<message>
<location filename="../config/configpaneldialog.ui" line="351"/>
<source>Opacity</source>
<translation>Trasparenza</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="200"/>
<source>Top of desktop</source>
<translation>Alto del desktop</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="201"/>
<source>Left of desktop</source>
<translation>Sinistra del desktop</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="202"/>
<source>Right of desktop</source>
<translation>Destra del desktop</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="203"/>
<source>Bottom of desktop</source>
<translation>Basso del desktop</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="212"/>
<source>Top of desktop %1</source>
<translation>Alto del desktop %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="213"/>
<source>Left of desktop %1</source>
<translation>Sinistra del desktop %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="214"/>
<source>Right of desktop %1</source>
<translation>Destra del desktop %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="215"/>
<source>Bottom of desktop %1</source>
<translation>Basso del desktop %1</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="240"/>
<source>Top</source>
<translation>In cima</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="242"/>
<source>Bottom</source>
<translation>In fondo</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="397"/>
<location filename="../config/configpaneldialog.cpp" line="411"/>
<source>Pick color</source>
<translation>Scegli colore</translation>
</message>
<message>
<location filename="../config/configpaneldialog.cpp" line="431"/>
<source>Images (*.png *.gif *.jpg)</source>
<translation>Immagini (*.png *.gif *.jpg)</translation>
</message>
</context>
<context>
<name>LxQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
<translation>Aggiungi elementi</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="951"/>
<location filename="../lxqtpanel.cpp" line="970"/>
<source>Panel</source>
<translation>Panello</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="973"/>
<source>Configure Panel...</source>
<translation>Configura pannello...</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="978"/>
<source>Add Panel Widgets...</source>
<translatorcomment>Call them &quot;plugins&quot; better?</translatorcomment>
<translation>Aggiungi elementi...</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="984"/>
<source>Add Panel</source>
<translation>Aggiungi panello</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="991"/>
<source>Remove Panel</source>
<translation>Rimuovi panello</translation>
</message>
<message>
<source>Configure panel...</source>
<translation type="vanished">Configura pannello...</translation>
</message>
<message>
<source>Add plugins ...</source>
<translation type="vanished">Aggiungi plugin...</translation>
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configura</translation>
</message>
<message>
<source>Move</source>
<translation type="vanished">Sposta</translation>
</message>
<message>
<source>Remove</source>
<translation type="vanished">Rimuovi</translation>
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configura pannello</translation>
</message>
</context>
<context>
<name>Plugin</name>
<message>
<location filename="../plugin.cpp" line="395"/>
<source>Configure &quot;%1&quot;</source>
<translation>Configura &quot;%1&quot;</translation>
</message>
<message>
<location filename="../plugin.cpp" line="400"/>
<source>Move &quot;%1&quot;</source>
<translation>Sposta &quot;%1&quot;</translation>
</message>
<message>
<location filename="../plugin.cpp" line="408"/>
<source>Remove &quot;%1&quot;</source>
<translation>Rimuovi &quot;%1&quot;</translation>
</message>
</context>
</TS>

View File

@ -190,7 +190,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -190,7 +190,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Konfigūruoti</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Skydelio konfigūravimas</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Instellen</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Paneel instellingen</translation>

View File

@ -190,7 +190,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Konfiguruj</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Konfiguruj panel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configurar</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configurar painel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configurar</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configurar painel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Configurează</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Configurează panoul</translation>

View File

@ -284,7 +284,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="912"/>
<location filename="../lxqtpanel.cpp" line="931"/>

View File

@ -284,7 +284,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="912"/>
<location filename="../lxqtpanel.cpp" line="931"/>

View File

@ -246,7 +246,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -284,7 +284,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Nastaviť panel</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Nastavitev</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Nastavitev pulta</translation>

View File

@ -190,7 +190,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>

View File

@ -238,7 +238,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -272,7 +272,7 @@
</message>
</context>
<context>
<name>LxQtPanelPluginPrivate</name>
<name>LXQtPanelPluginPrivate</name>
<message>
<source>Configure</source>
<translation type="vanished">Подеси</translation>
@ -287,7 +287,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Panel</source>
<translation type="vanished">Панел</translation>

View File

@ -262,7 +262,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -300,7 +300,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Подеси</translation>
@ -311,7 +311,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Подеси панел</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished"></translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished"></translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Yapılandır</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Paneli yapılandır</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished">Налаштувати</translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished">Налаштувати панель</translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished"></translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished"></translation>

View File

@ -274,7 +274,7 @@
</message>
</context>
<context>
<name>LxQtPanel</name>
<name>LXQtPanel</name>
<message>
<location filename="../lxqtpanel.cpp" line="623"/>
<source>Add Panel Widgets</source>
@ -284,7 +284,7 @@
<location filename="../lxqtpanel.cpp" line="951"/>
<location filename="../lxqtpanel.cpp" line="970"/>
<source>Panel</source>
<translation>LxQt滑鼠設定</translation>
<translation>LXQt滑鼠設定</translation>
</message>
<message>
<location filename="../lxqtpanel.cpp" line="973"/>
@ -316,7 +316,7 @@
</message>
</context>
<context>
<name>LxQtPanelPlugin</name>
<name>LXQtPanelPlugin</name>
<message>
<source>Configure</source>
<translation type="vanished"></translation>
@ -331,7 +331,7 @@
</message>
</context>
<context>
<name>LxQtPanelPrivate</name>
<name>LXQtPanelPrivate</name>
<message>
<source>Configure panel</source>
<translation type="vanished"></translation>

View File

@ -30,7 +30,7 @@
#include <QEvent>
CalendarPopup::CalendarPopup(QWidget *parent):
QDialog(parent, Qt::Dialog | Qt::WindowStaysOnTopHint | Qt::CustomizeWindowHint | Qt::Popup | Qt::X11BypassWindowManagerHint)
QDialog(parent, Qt::Window | Qt::WindowStaysOnTopHint | Qt::CustomizeWindowHint | Qt::Popup | Qt::X11BypassWindowManagerHint)
{
setLayout(new QHBoxLayout(this));
layout()->setMargin(1);
@ -51,14 +51,6 @@ void CalendarPopup::show()
QDialog::show();
}
bool CalendarPopup::event(QEvent *event)
{
if (event->type() == QEvent::WindowDeactivate)
hide();
return QDialog::event(event);
}
void CalendarPopup::setFirstDayOfWeek(Qt::DayOfWeek wday)
{
cal->setFirstDayOfWeek(wday);

View File

@ -42,9 +42,6 @@ public:
void show();
protected:
virtual bool event(QEvent* );
private:
QCalendarWidget *cal;
};

View File

@ -47,7 +47,7 @@
/**
* @file lxqtclock.cpp
* @brief implements LxQtclock and LxQtclockgui
* @brief implements LXQtclock and LXQtclockgui
* @author Christopher "VdoP" Regali
* @author Kuzma Shapran
*/
@ -75,15 +75,15 @@ public:
/**
* @brief constructor
*/
LxQtClock::LxQtClock(const ILxQtPanelPluginStartupInfo &startupInfo):
LXQtClock::LXQtClock(const ILXQtPanelPluginStartupInfo &startupInfo):
QObject(),
ILxQtPanelPlugin(startupInfo),
ILXQtPanelPlugin(startupInfo),
mAutoRotate(true),
mTextStyle{new DownscaleFontStyle},
mCurrentCharCount(0)
{
mMainWidget = new QWidget();
mRotatedWidget = new LxQt::RotatedWidget(*(new QWidget()), mMainWidget);
mRotatedWidget = new LXQt::RotatedWidget(*(new QWidget()), mMainWidget);
mContent = mRotatedWidget->content();
mContent->setStyle(mTextStyle.data());
mTimeLabel = new QLabel(mContent);
@ -121,12 +121,12 @@ LxQtClock::LxQtClock(const ILxQtPanelPluginStartupInfo &startupInfo):
/**
* @brief destructor
*/
LxQtClock::~LxQtClock()
LXQtClock::~LXQtClock()
{
delete mMainWidget;
}
QDateTime LxQtClock::currentDateTime()
QDateTime LXQtClock::currentDateTime()
{
return QDateTime(mUseUTC ? QDateTime::currentDateTimeUtc() : QDateTime::currentDateTime());
}
@ -135,7 +135,7 @@ QDateTime LxQtClock::currentDateTime()
* @brief updates the time
* Color and font settings can be configured in Qt CSS
*/
void LxQtClock::updateTime()
void LXQtClock::updateTime()
{
//XXX: do we need this with PreciseTimer ?
if (currentDateTime().time().msec() > 500)
@ -144,7 +144,7 @@ void LxQtClock::updateTime()
showTime();
}
void LxQtClock::showTime()
void LXQtClock::showTime()
{
QDateTime now{currentDateTime()};
int new_char_count;
@ -170,7 +170,7 @@ void LxQtClock::showTime()
}
}
void LxQtClock::restartTimer()
void LXQtClock::restartTimer()
{
if (mClockTimer->isActive())
mClockTimer->stop();
@ -181,7 +181,7 @@ void LxQtClock::restartTimer()
QTimer::singleShot(delay, Qt::PreciseTimer, this, SLOT(updateTime()));
}
void LxQtClock::settingsChanged()
void LXQtClock::settingsChanged()
{
mFirstDayOfWeek = settings()->value("firstDayOfWeek", -1).toInt();
if (-1 == mFirstDayOfWeek)
@ -227,7 +227,7 @@ void LxQtClock::settingsChanged()
}
}
void LxQtClock::realign()
void LXQtClock::realign()
{
QSize size{QWIDGETSIZE_MAX, QWIDGETSIZE_MAX};
Qt::Corner origin = Qt::TopLeftCorner;
@ -235,16 +235,16 @@ void LxQtClock::realign()
{
switch (panel()->position())
{
case ILxQtPanel::PositionTop:
case ILxQtPanel::PositionBottom:
case ILXQtPanel::PositionTop:
case ILXQtPanel::PositionBottom:
origin = Qt::TopLeftCorner;
break;
case ILxQtPanel::PositionLeft:
case ILXQtPanel::PositionLeft:
origin = Qt::BottomLeftCorner;
break;
case ILxQtPanel::PositionRight:
case ILXQtPanel::PositionRight:
origin = Qt::TopRightCorner;
break;
}
@ -277,9 +277,9 @@ void LxQtClock::realign()
}
}
void LxQtClock::activated(ActivationReason reason)
void LXQtClock::activated(ActivationReason reason)
{
if (reason != ILxQtPanelPlugin::Trigger)
if (reason != ILXQtPanelPlugin::Trigger)
return;
if (!mCalendarPopup->isVisible())
@ -294,12 +294,12 @@ void LxQtClock::activated(ActivationReason reason)
}
}
QDialog * LxQtClock::configureDialog()
QDialog * LXQtClock::configureDialog()
{
return new LxQtClockConfiguration(*settings());
return new LXQtClockConfiguration(*settings());
}
bool LxQtClock::eventFilter(QObject *watched, QEvent *event)
bool LXQtClock::eventFilter(QObject *watched, QEvent *event)
{
if (watched == mMainWidget)
{

View File

@ -43,12 +43,12 @@ class QDialog;
class QTimer;
class QProxyStyle;
class LxQtClock : public QObject, public ILxQtPanelPlugin
class LXQtClock : public QObject, public ILXQtPanelPlugin
{
Q_OBJECT
public:
LxQtClock(const ILxQtPanelPluginStartupInfo &startupInfo);
~LxQtClock();
LXQtClock(const ILXQtPanelPluginStartupInfo &startupInfo);
~LXQtClock();
virtual Flags flags() const { return PreferRightAlignment | HaveConfigDialog ; }
QString themeId() const { return "Clock"; }
@ -71,7 +71,7 @@ private:
QTimer* mClockTimer;
QWidget *mMainWidget;
QWidget *mContent;
LxQt::RotatedWidget* mRotatedWidget;
LXQt::RotatedWidget* mRotatedWidget;
QLabel* mTimeLabel;
QLabel* mDateLabel;
QString mClockFormat;
@ -92,13 +92,13 @@ private:
};
class LxQtClockPluginLibrary: public QObject, public ILxQtPanelPluginLibrary
class LXQtClockPluginLibrary: public QObject, public ILXQtPanelPluginLibrary
{
Q_OBJECT
// Q_PLUGIN_METADATA(IID "lxde-qt.org/Panel/PluginInterface/3.0")
Q_INTERFACES(ILxQtPanelPluginLibrary)
Q_INTERFACES(ILXQtPanelPluginLibrary)
public:
ILxQtPanelPlugin *instance(const ILxQtPanelPluginStartupInfo &startupInfo) const { return new LxQtClock(startupInfo);}
ILXQtPanelPlugin *instance(const ILXQtPanelPluginStartupInfo &startupInfo) const { return new LXQtClock(startupInfo);}
};

View File

@ -75,9 +75,9 @@ namespace
};
}
LxQtClockConfiguration::LxQtClockConfiguration(QSettings &settings, QWidget *parent) :
LXQtClockConfiguration::LXQtClockConfiguration(QSettings &settings, QWidget *parent) :
QDialog(parent),
ui(new Ui::LxQtClockConfiguration),
ui(new Ui::LXQtClockConfiguration),
mSettings(settings),
oldSettings(settings),
mOldIndex(1)
@ -109,20 +109,20 @@ LxQtClockConfiguration::LxQtClockConfiguration(QSettings &settings, QWidget *par
connect(ui->firstDayOfWeekCB, SIGNAL(activated(int)), SLOT(saveSettings()));
}
LxQtClockConfiguration::~LxQtClockConfiguration()
LXQtClockConfiguration::~LXQtClockConfiguration()
{
delete ui;
}
static int currentYear = QDate::currentDate().year();
void LxQtClockConfiguration::addDateFormat(const QString &format)
void LXQtClockConfiguration::addDateFormat(const QString &format)
{
if (ui->dateFormatCOB->findData(QVariant(format)) == -1)
ui->dateFormatCOB->addItem(QDate(currentYear, 1, 1).toString(format), QVariant(format));
}
void LxQtClockConfiguration::createDateFormats()
void LXQtClockConfiguration::createDateFormats()
{
ui->dateFormatCOB->clear();
@ -200,7 +200,7 @@ void LxQtClockConfiguration::createDateFormats()
ui->dateFormatCOB->addItem(QString("Custom (%1) ...").arg(QDate(currentYear, 1, 1).toString(mCustomDateFormat)), QVariant(mCustomDateFormat));
}
void LxQtClockConfiguration::loadSettings()
void LXQtClockConfiguration::loadSettings()
{
QString systemDateLocale = QLocale::system().dateFormat(QLocale::ShortFormat).toUpper();
QString systemTimeLocale = QLocale::system().timeFormat(QLocale::ShortFormat).toUpper();
@ -237,7 +237,7 @@ void LxQtClockConfiguration::loadSettings()
ui->firstDayOfWeekCB->setCurrentIndex(dynamic_cast<FirstDayCombo&>(*(ui->firstDayOfWeekCB->model())).findIndex(mSettings.value("firstDayOfWeek", -1).toInt()));
}
void LxQtClockConfiguration::saveSettings()
void LXQtClockConfiguration::saveSettings()
{
QString timeFormat(ui->ampmClockCB->isChecked() ? "h:mm AP" : "HH:mm");
@ -263,7 +263,7 @@ void LxQtClockConfiguration::saveSettings()
mSettings.setValue("firstDayOfWeek", dynamic_cast<QStandardItemModel&>(*ui->firstDayOfWeekCB->model()).item(ui->firstDayOfWeekCB->currentIndex(), 0)->data(Qt::UserRole));
}
void LxQtClockConfiguration::dialogButtonsAction(QAbstractButton *btn)
void LXQtClockConfiguration::dialogButtonsAction(QAbstractButton *btn)
{
if (ui->buttons->buttonRole(btn) == QDialogButtonBox::ResetRole)
{
@ -276,7 +276,7 @@ void LxQtClockConfiguration::dialogButtonsAction(QAbstractButton *btn)
}
}
void LxQtClockConfiguration::dateFormatActivated(int index)
void LXQtClockConfiguration::dateFormatActivated(int index)
{
if (index == ui->dateFormatCOB->count() - 1)
{

View File

@ -38,21 +38,21 @@
#include <LXQt/Settings>
namespace Ui {
class LxQtClockConfiguration;
class LXQtClockConfiguration;
}
class LxQtClockConfiguration : public QDialog
class LXQtClockConfiguration : public QDialog
{
Q_OBJECT
public:
explicit LxQtClockConfiguration(QSettings &settings, QWidget *parent = 0);
~LxQtClockConfiguration();
explicit LXQtClockConfiguration(QSettings &settings, QWidget *parent = 0);
~LXQtClockConfiguration();
private:
Ui::LxQtClockConfiguration *ui;
Ui::LXQtClockConfiguration *ui;
QSettings &mSettings;
LxQt::SettingsCache oldSettings;
LXQt::SettingsCache oldSettings;
/*
Read settings from conf file and put data into controls.

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>LxQtClockConfiguration</class>
<widget class="QDialog" name="LxQtClockConfiguration">
<class>LXQtClockConfiguration</class>
<widget class="QDialog" name="LXQtClockConfiguration">
<property name="geometry">
<rect>
<x>0</x>
@ -167,7 +167,7 @@
<connection>
<sender>buttons</sender>
<signal>accepted()</signal>
<receiver>LxQtClockConfiguration</receiver>
<receiver>LXQtClockConfiguration</receiver>
<slot>accept()</slot>
<hints>
<hint type="sourcelabel">
@ -183,7 +183,7 @@
<connection>
<sender>buttons</sender>
<signal>rejected()</signal>
<receiver>LxQtClockConfiguration</receiver>
<receiver>LXQtClockConfiguration</receiver>
<slot>reject()</slot>
<hints>
<hint type="sourcelabel">

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.
Icon=preferences-system-time

View File

@ -10,7 +10,7 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>
<source>Clock Settings</source>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,9 +10,9 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<source>LXQt Clock Settings</source>
<translation type="vanished">إعدادات ساعة ريزر</translation>
</message>
<message>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,9 +10,9 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<source>LXQt Clock Settings</source>
<translation type="vanished">Nastavení hodin</translation>
</message>
<message>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,9 +10,9 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<source>LXQt Clock Settings</source>
<translation type="vanished">Nastavení hodin</translation>
</message>
<message>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,9 +10,9 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<source>LXQt Clock Settings</source>
<translation type="vanished">LXQt Ur-Indstillinger</translation>
</message>
<message>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,10 +10,10 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<translation type="vanished">LxQt Urindstillinger</translation>
<source>LXQt Clock Settings</source>
<translation type="vanished">LXQt Urindstillinger</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>

View File

@ -10,7 +10,7 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>
<source>Clock Settings</source>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.
@ -8,5 +8,5 @@ Comment=Displays the current time. Comes with a calendar.
# Translations
Comment[it_IT]=Orologio e calendario
Name[it_IT]=Orologio
Comment[el]=Ρολόι και ημερολόγιο
Name[el]=Ρολόι

View File

@ -1,24 +1,24 @@
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE TS>
<TS version="2.1" language="el_GR">
<TS version="2.1" language="el">
<context>
<name>FirstDayCombo</name>
<message>
<location filename="../lxqtclockconfiguration.cpp" line="50"/>
<source>&lt;locale based&gt;</source>
<translation type="unfinished"></translation>
<translation>&lt;locale based&gt;</translation>
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<translation type="vanished">Ρυθμίσεις ρολογιού LxQt</translation>
<source>LXQt Clock Settings</source>
<translation type="vanished">Ρυθμίσεις ρολογιού LXQt</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>
<source>Clock Settings</source>
<translation type="unfinished"></translation>
<translation>Ρυθμίσεις του ρολογιού</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="20"/>
@ -38,47 +38,47 @@
<message>
<location filename="../lxqtclockconfiguration.ui" line="40"/>
<source>&amp;Use UTC</source>
<translation type="unfinished"></translation>
<translation>&amp;Χρήση της UTC</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="59"/>
<source>Date &amp;format</source>
<translation type="unfinished"></translation>
<translation>Μορφή &amp;ημερομηνίας</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="76"/>
<source>&amp;Do not show date</source>
<translation type="unfinished"></translation>
<translation>&amp;Να μην εμφανίζεται η ημερομηνία</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="86"/>
<source>Show date &amp;before time</source>
<translation type="unfinished"></translation>
<translation>Εμφάνιση της ημερομηνίας &amp;πριν την ώρα</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="93"/>
<source>Show date &amp;after time</source>
<translation type="unfinished"></translation>
<translation>Εμφάνιση της ημερομηνίας &amp;μετά την ώρα</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="100"/>
<source>Show date below time on new &amp;line</source>
<translation type="unfinished"></translation>
<translation>Εμφάνιση της ημερομηνίας κάτω από την ώρα σε νέα &amp;γραμμή</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="107"/>
<source>First day of week in calendar</source>
<translation type="unfinished"></translation>
<translation>Η πρώτη ημέρα της εβδομάδας στο ημερολόγιο</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="124"/>
<source>Orientation</source>
<translation type="unfinished"></translation>
<translation>Προσανατολισμός</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="130"/>
<source>Auto&amp;rotate when the panel is vertical</source>
<translation type="unfinished"></translation>
<translation>Αυτόματη περιστρο&amp;φή όταν ο πίνακας είναι τοποθετημένος κατακόρυφα</translation>
</message>
<message>
<source>&amp;Font</source>
@ -152,7 +152,7 @@
<message>
<location filename="../lxqtclockconfiguration.cpp" line="284"/>
<source>Input custom date format</source>
<translation type="unfinished"></translation>
<translation>Εισαγωγή προσαρμοσμένης μορφής ημερομηνίας</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.cpp" line="284"/>
@ -175,7 +175,25 @@ will also be treated as text and not be used as an expression.
Custom date format:</source>
<translation type="unfinished"></translation>
<translation>Οι ερμηνευμενες ακολουθίες της μορφής της ημερομηνίας είναι:
d η ημέρα ως αριθμός δίχως το αρχικό μηδενικό (1 ως 31)
dd η ημέρα ως αριθμός με το αρχικό μηδενικό (01 ως 31)
ddd η συντομογραφημένη τοπικοποιημένη ονομασία της ημέρας (π.χ. «Δευ» ως «Κυρ»).
dddd η μακριά τοπικοποιημένη ονομασία της ημέρας (π.χ. «Δευτέρα» ως «Κυριακή»).
M ο μήνας ως αριθμός δίχως το αρχικό μηδενικό (1-12)
MM ο μήνας ως αριθμός με το αρχικό μηδενικό (01-12)
MMM η συντομογραφημένη τοπικοποιημένη ονομασία του μήνα (π.χ. «Ιαν» ως «Δεκ»).
MMMM η μακριά τοπικοποιημένη ονομασία του μήνα (π.χ. «Ιανουάριος» ως «Δεκέμβριος»).
yy το έτος ως διψήφιος αριθμός (00-99)
yyyy το έτος ως τετραψήφιος αριθμός
Όλοι οι λοιποί χαρακτήρες εισόδου θα διαχειριστούν ως κείμενο.
Οποιαδήποτε ακολουθία χαρακτήρων που εγκλείονται σε μονά εισαγωγικά (&apos;)
θα διαχειρίζονται επίσης ως κείμενο και δεν θα χρησιμοποιούνται ως έκφραση.
Προσαρμοσμένη μορφή ημερομηνίας:</translation>
</message>
</context>
</TS>

View File

@ -1,12 +0,0 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.
#TRANSLATIONS_DIR=../translations
# Translations
Comment[el_GR]=Ρολόι και ημερολόγιο
Name[el_GR]=Ρολόι

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,10 +10,10 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<translation type="vanished">Agordoj de horloĝo de LxQt</translation>
<source>LXQt Clock Settings</source>
<translation type="vanished">Agordoj de horloĝo de LXQt</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,10 +10,10 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<translation type="vanished">Configuración del reloj de LxQt</translation>
<source>LXQt Clock Settings</source>
<translation type="vanished">Configuración del reloj de LXQt</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>

View File

@ -10,10 +10,10 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<translation type="vanished">Configuración de Reloj LxQt</translation>
<source>LXQt Clock Settings</source>
<translation type="vanished">Configuración de Reloj LXQt</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>

View File

@ -1,6 +1,6 @@
[Desktop Entry]
Type=Service
ServiceTypes=LxQtPanel/Plugin
ServiceTypes=LXQtPanel/Plugin
Name=Date & time
Comment=Displays the current time. Comes with a calendar.

View File

@ -10,10 +10,10 @@
</message>
</context>
<context>
<name>LxQtClockConfiguration</name>
<name>LXQtClockConfiguration</name>
<message>
<source>LxQt Clock Settings</source>
<translation type="vanished">Configuración de Reloj LxQt</translation>
<source>LXQt Clock Settings</source>
<translation type="vanished">Configuración de Reloj LXQt</translation>
</message>
<message>
<location filename="../lxqtclockconfiguration.ui" line="14"/>

Some files were not shown because too many files have changed in this diff Show More