Advance Wayland and KDE package bring-up
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
include(ECMAddTests)
|
||||
include(ECMMarkAsTest)
|
||||
|
||||
find_package(Qt6 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Test)
|
||||
|
||||
remove_definitions(-DQT_NO_CAST_FROM_ASCII)
|
||||
|
||||
macro(kconfigwidgets_executable_tests)
|
||||
foreach(_testname ${ARGN})
|
||||
add_executable(${_testname} ${_testname}.cpp)
|
||||
target_link_libraries(${_testname} Qt6::Test KF6::ConfigWidgets)
|
||||
ecm_mark_as_test(${_testname})
|
||||
endforeach(_testname)
|
||||
endmacro()
|
||||
|
||||
kconfigwidgets_executable_tests(
|
||||
kcolorschemedemo
|
||||
klanguagebuttontest
|
||||
kcommandbartest
|
||||
)
|
||||
|
||||
add_executable(kcodecactiontest kcodecactiontest.cpp)
|
||||
target_link_libraries(kcodecactiontest Qt6::Test KF6::ConfigWidgets)
|
||||
ecm_mark_as_test(kcodecactiontest)
|
||||
|
||||
## kcolorutilsdemo
|
||||
|
||||
set(kcolorUtilsDemoSources kcolorutilsdemo.cpp kimageframe.cpp)
|
||||
qt_wrap_ui(kcolorUtilsDemoSources kcolorutilsdemo.ui)
|
||||
add_executable(kcolorutilsdemo ${kcolorUtilsDemoSources})
|
||||
ecm_mark_as_test(kcolorutilsdemo)
|
||||
target_link_libraries(kcolorutilsdemo KF6::ConfigWidgets KF6::GuiAddons)
|
||||
|
||||
## krecentfilesactiontest (manual)
|
||||
|
||||
set(krecentfilesactionTestSources krecentfilesactiontest.cpp)
|
||||
qt_wrap_ui(krecentfilesactionTestSources krecentfilesactiontest.ui)
|
||||
add_executable(krecentfilesactiontest ${krecentfilesactionTestSources})
|
||||
ecm_mark_as_test(krecentfilesactiontest)
|
||||
target_link_libraries(krecentfilesactiontest KF6::ConfigWidgets)
|
||||
@@ -0,0 +1,74 @@
|
||||
#include "kcodecactiontest.h"
|
||||
|
||||
#include <QApplication>
|
||||
#include <QMenuBar>
|
||||
#include <QToolBar>
|
||||
|
||||
#include <QDebug>
|
||||
|
||||
#include <kcodecaction.h>
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
QApplication::setApplicationName(QStringLiteral("kcodecactiontest"));
|
||||
QApplication app(argc, argv);
|
||||
|
||||
CodecActionTest *test = new CodecActionTest;
|
||||
test->show();
|
||||
|
||||
return app.exec();
|
||||
}
|
||||
|
||||
CodecActionTest::CodecActionTest(QWidget *parent)
|
||||
: QMainWindow(parent)
|
||||
, m_comboCodec(new KCodecAction(QStringLiteral("Combo Codec Action"), this))
|
||||
, m_buttonCodec(new KCodecAction(QStringLiteral("Button Codec Action"), this))
|
||||
{
|
||||
// clang-format off
|
||||
m_comboCodec->setToolBarMode(KCodecAction::ComboBoxMode);
|
||||
connect(m_comboCodec, &KSelectAction::actionTriggered, this, &CodecActionTest::actionTriggered);
|
||||
connect(m_comboCodec, &KSelectAction::indexTriggered, this, &CodecActionTest::indexTriggered);
|
||||
connect(m_comboCodec, &KSelectAction::textTriggered, this, &CodecActionTest::textTriggered);
|
||||
connect(m_comboCodec, &KCodecAction::codecNameTriggered, this, &CodecActionTest::nameTriggered);
|
||||
|
||||
m_buttonCodec->setToolBarMode(KCodecAction::MenuMode);
|
||||
connect(m_buttonCodec, &KSelectAction::actionTriggered, this, &CodecActionTest::actionTriggered);
|
||||
connect(m_buttonCodec, &KSelectAction::indexTriggered, this, &CodecActionTest::indexTriggered);
|
||||
connect(m_buttonCodec, &KSelectAction::textTriggered, this, &CodecActionTest::textTriggered);
|
||||
connect(m_buttonCodec, &KCodecAction::codecNameTriggered, this, &CodecActionTest::nameTriggered);
|
||||
// clang-format on
|
||||
|
||||
menuBar()->addAction(m_comboCodec);
|
||||
menuBar()->addAction(m_buttonCodec);
|
||||
|
||||
QToolBar *toolBar = addToolBar(QStringLiteral("Test"));
|
||||
toolBar->addAction(m_comboCodec);
|
||||
toolBar->addAction(m_buttonCodec);
|
||||
}
|
||||
|
||||
void CodecActionTest::actionTriggered(QAction *action)
|
||||
{
|
||||
qDebug() << action;
|
||||
}
|
||||
|
||||
void CodecActionTest::indexTriggered(int index)
|
||||
{
|
||||
qDebug() << index;
|
||||
}
|
||||
|
||||
void CodecActionTest::textTriggered(const QString &text)
|
||||
{
|
||||
qDebug() << text;
|
||||
}
|
||||
|
||||
void CodecActionTest::nameTriggered(const QByteArray &codecName)
|
||||
{
|
||||
qDebug() << codecName;
|
||||
}
|
||||
|
||||
void CodecActionTest::slotActionTriggered(bool state)
|
||||
{
|
||||
qDebug() << sender() << " state " << state;
|
||||
}
|
||||
|
||||
#include "moc_kcodecactiontest.cpp"
|
||||
@@ -0,0 +1,28 @@
|
||||
#ifndef KCODECACTION_TEST_H
|
||||
#define KCODECACTION_TEST_H
|
||||
|
||||
#include <QMainWindow>
|
||||
|
||||
#include "kcodecaction.h"
|
||||
|
||||
class CodecActionTest : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
CodecActionTest(QWidget *parent = nullptr);
|
||||
|
||||
public Q_SLOTS:
|
||||
void actionTriggered(QAction *action);
|
||||
void indexTriggered(int index);
|
||||
void textTriggered(const QString &text);
|
||||
void nameTriggered(const QByteArray &name);
|
||||
|
||||
void slotActionTriggered(bool state);
|
||||
|
||||
private:
|
||||
KCodecAction *m_comboCodec;
|
||||
KCodecAction *m_buttonCodec;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,68 @@
|
||||
/*
|
||||
This file is part of the KDE project
|
||||
SPDX-FileCopyrightText: 2013 Martin Gräßlin <mgraesslin@kde.org>
|
||||
|
||||
SPDX-License-Identifier: LGPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#include <KActionMenu>
|
||||
#include <kcolorschememanager.h>
|
||||
#include <kcolorschememenu.h>
|
||||
|
||||
#include <QApplication>
|
||||
#include <QDialog>
|
||||
#include <QDialogButtonBox>
|
||||
#include <QListView>
|
||||
#include <QMainWindow>
|
||||
#include <QMenu>
|
||||
#include <QMenuBar>
|
||||
#include <QToolButton>
|
||||
#include <QVBoxLayout>
|
||||
|
||||
class KColorSchemeDemo : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
KColorSchemeDemo()
|
||||
: QMainWindow(nullptr)
|
||||
{
|
||||
KColorSchemeManager *manager = KColorSchemeManager::instance();
|
||||
QListView *view = new QListView(this);
|
||||
view->setModel(manager->model());
|
||||
connect(view, &QListView::activated, manager, &KColorSchemeManager::activateScheme);
|
||||
manager->setAutosaveChanges(true);
|
||||
|
||||
QDialogButtonBox *box = new QDialogButtonBox(QDialogButtonBox::Close, this);
|
||||
connect(box, &QDialogButtonBox::rejected, qApp, &QApplication::quit);
|
||||
|
||||
QToolButton *button = new QToolButton(box);
|
||||
button->setIcon(QIcon::fromTheme(QStringLiteral("fill-color")));
|
||||
button->setMenu(KColorSchemeMenu::createMenu(manager, button)->menu());
|
||||
box->addButton(button, QDialogButtonBox::InvalidRole);
|
||||
|
||||
QWidget *w = new QWidget();
|
||||
QVBoxLayout *layout = new QVBoxLayout(w);
|
||||
layout->addWidget(view);
|
||||
layout->addWidget(box);
|
||||
|
||||
setCentralWidget(w);
|
||||
|
||||
QMenu *menu = new QMenu("Menu", this);
|
||||
menu->addAction(KColorSchemeMenu::createMenu(manager, this));
|
||||
menuBar()->addMenu(menu);
|
||||
}
|
||||
~KColorSchemeDemo() override
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
QApplication app(argc, argv);
|
||||
|
||||
KColorSchemeDemo *d = new KColorSchemeDemo;
|
||||
d->show();
|
||||
return app.exec();
|
||||
}
|
||||
|
||||
#include "kcolorschemedemo.moc"
|
||||
@@ -0,0 +1,193 @@
|
||||
/*
|
||||
SPDX-FileCopyrightText: 2009 Matthew Woehlke <mw_triad@users.sourceforge.net>
|
||||
|
||||
SPDX-License-Identifier: GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#include "kcolorutilsdemo.h"
|
||||
#include <KColorUtils>
|
||||
#include <kcolorscheme.h>
|
||||
|
||||
#include <QApplication>
|
||||
|
||||
KColorUtilsDemo::KColorUtilsDemo(QWidget *parent)
|
||||
: QWidget(parent)
|
||||
, _leOutImg(128, 128, QImage::Format_RGB32)
|
||||
, _mtMixOutImg(128, 16, QImage::Format_RGB32)
|
||||
, _mtTintOutImg(128, 16, QImage::Format_RGB32)
|
||||
{
|
||||
_noUpdate = true;
|
||||
setupUi(this);
|
||||
_noUpdate = false;
|
||||
|
||||
inputSpinChanged();
|
||||
targetSpinChanged();
|
||||
}
|
||||
|
||||
void KColorUtilsDemo::inputChanged()
|
||||
{
|
||||
qreal hue;
|
||||
qreal chroma;
|
||||
qreal luma;
|
||||
KColorUtils::getHcy(inColor->color(), &hue, &chroma, &luma);
|
||||
ifHue->setValue(hue);
|
||||
ifChroma->setValue(chroma);
|
||||
ifLuma->setValue(luma);
|
||||
ifGray->setValue(qGray(inColor->color().rgb()));
|
||||
|
||||
lumaChanged();
|
||||
mixChanged();
|
||||
shadeChanged();
|
||||
}
|
||||
|
||||
void KColorUtilsDemo::lumaChanged()
|
||||
{
|
||||
QColor base = inColor->color();
|
||||
|
||||
for (int y = 0; y < 128; ++y) {
|
||||
qreal k = qreal(y - 64) / 64.0;
|
||||
|
||||
for (int x = 0; x < 128; ++x) {
|
||||
qreal c;
|
||||
|
||||
QColor r;
|
||||
if (leOpLighten->isChecked()) {
|
||||
c = qreal(128 - x) / 64.0;
|
||||
r = KColorUtils::lighten(base, k, c);
|
||||
} else if (leOpDarken->isChecked()) {
|
||||
c = qreal(x) / 64.0;
|
||||
r = KColorUtils::darken(base, -k, c);
|
||||
} else {
|
||||
c = qreal(x - 64) / 64.0;
|
||||
r = KColorUtils::shade(base, k, c);
|
||||
}
|
||||
_leOutImg.setPixel(x, y, r.rgb());
|
||||
}
|
||||
}
|
||||
|
||||
leOut->setImage(_leOutImg);
|
||||
}
|
||||
|
||||
void KColorUtilsDemo::mixChanged()
|
||||
{
|
||||
QColor base = inColor->color();
|
||||
QColor target = mtTarget->color();
|
||||
|
||||
for (int x = 0; x < 128; ++x) {
|
||||
qreal k = qreal(x) / 128.0;
|
||||
|
||||
QRgb m = KColorUtils::mix(base, target, k).rgb();
|
||||
QRgb t = KColorUtils::tint(base, target, k).rgb();
|
||||
|
||||
for (int y = 0; y < 16; ++y) {
|
||||
_mtMixOutImg.setPixel(x, y, m);
|
||||
_mtTintOutImg.setPixel(x, y, t);
|
||||
}
|
||||
}
|
||||
|
||||
mtMixOut->setImage(_mtMixOutImg);
|
||||
mtTintOut->setImage(_mtTintOutImg);
|
||||
}
|
||||
|
||||
void setBackground(QWidget *widget, const QColor &color)
|
||||
{
|
||||
QPalette palette = widget->palette();
|
||||
palette.setColor(widget->backgroundRole(), color);
|
||||
widget->setPalette(palette);
|
||||
|
||||
QString name = color.name();
|
||||
name += " (" + QString::number(color.red()) + ", " + QString::number(color.green()) + ", " + QString::number(color.blue()) + QLatin1Char(')');
|
||||
widget->setToolTip(name);
|
||||
}
|
||||
|
||||
#define SET_SHADE(_n, _c, _cn, _ch) setBackground(ss##_n, KColorScheme::shade(_c, KColorScheme::_n##Shade, _cn, _ch));
|
||||
|
||||
void KColorUtilsDemo::shadeChanged()
|
||||
{
|
||||
qreal cn = ssContrast->value();
|
||||
qreal ch = ssChroma->value();
|
||||
|
||||
QColor base = inColor->color();
|
||||
setBackground(ssOut, base);
|
||||
setBackground(ssBase, base);
|
||||
SET_SHADE(Light, base, cn, ch);
|
||||
SET_SHADE(Midlight, base, cn, ch);
|
||||
SET_SHADE(Mid, base, cn, ch);
|
||||
SET_SHADE(Dark, base, cn, ch);
|
||||
SET_SHADE(Shadow, base, cn, ch);
|
||||
}
|
||||
|
||||
void updateSwatch(KColorButton *s, const QSpinBox *r, const QSpinBox *g, const QSpinBox *b)
|
||||
{
|
||||
s->setColor(QColor(r->value(), g->value(), b->value()));
|
||||
}
|
||||
|
||||
void updateSpins(const QColor &c, QSpinBox *r, QSpinBox *g, QSpinBox *b)
|
||||
{
|
||||
r->setValue(c.red());
|
||||
g->setValue(c.green());
|
||||
b->setValue(c.blue());
|
||||
}
|
||||
|
||||
void KColorUtilsDemo::inputSpinChanged()
|
||||
{
|
||||
if (_noUpdate) {
|
||||
return;
|
||||
}
|
||||
_noUpdate = true;
|
||||
|
||||
updateSwatch(inColor, inRed, inGreen, inBlue);
|
||||
inputChanged();
|
||||
|
||||
_noUpdate = false;
|
||||
}
|
||||
|
||||
void KColorUtilsDemo::targetSpinChanged()
|
||||
{
|
||||
if (_noUpdate) {
|
||||
return;
|
||||
}
|
||||
_noUpdate = true;
|
||||
|
||||
updateSwatch(mtTarget, mtRed, mtGreen, mtBlue);
|
||||
mixChanged();
|
||||
|
||||
_noUpdate = false;
|
||||
}
|
||||
|
||||
void KColorUtilsDemo::inputSwatchChanged(const QColor &color)
|
||||
{
|
||||
if (_noUpdate) {
|
||||
return;
|
||||
}
|
||||
_noUpdate = true;
|
||||
|
||||
updateSpins(color, inRed, inGreen, inBlue);
|
||||
inputChanged();
|
||||
|
||||
_noUpdate = false;
|
||||
}
|
||||
|
||||
void KColorUtilsDemo::targetSwatchChanged(const QColor &color)
|
||||
{
|
||||
if (_noUpdate) {
|
||||
return;
|
||||
}
|
||||
_noUpdate = true;
|
||||
|
||||
updateSpins(color, mtRed, mtGreen, mtBlue);
|
||||
mixChanged();
|
||||
|
||||
_noUpdate = false;
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
QApplication app(argc, argv);
|
||||
|
||||
KColorUtilsDemo *d = new KColorUtilsDemo;
|
||||
d->show();
|
||||
return app.exec();
|
||||
}
|
||||
|
||||
#include "moc_kcolorutilsdemo.cpp"
|
||||
@@ -0,0 +1,38 @@
|
||||
/*
|
||||
SPDX-FileCopyrightText: 2009 Matthew Woehlke <mw_triad@users.sourceforge.net>
|
||||
|
||||
SPDX-License-Identifier: GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#ifndef KCOLORUTILSDEMO_H
|
||||
#define KCOLORUTILSDEMO_H
|
||||
|
||||
#include "ui_kcolorutilsdemo.h"
|
||||
|
||||
class KColorUtilsDemo : public QWidget, Ui::form
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
KColorUtilsDemo(QWidget *parent = nullptr);
|
||||
~KColorUtilsDemo() override
|
||||
{
|
||||
}
|
||||
|
||||
public Q_SLOTS:
|
||||
void inputChanged();
|
||||
void lumaChanged();
|
||||
void mixChanged();
|
||||
void shadeChanged();
|
||||
|
||||
void inputSpinChanged();
|
||||
void inputSwatchChanged(const QColor &);
|
||||
|
||||
void targetSpinChanged();
|
||||
void targetSwatchChanged(const QColor &);
|
||||
|
||||
protected:
|
||||
QImage _leOutImg, _mtMixOutImg, _mtTintOutImg;
|
||||
bool _noUpdate;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,967 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>form</class>
|
||||
<widget class="QWidget" name="form">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>428</width>
|
||||
<height>344</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>KColorUtils Demo</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_9">
|
||||
<item row="0" column="0">
|
||||
<widget class="QGroupBox" name="gInput">
|
||||
<property name="title">
|
||||
<string>Input</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_7">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label_14">
|
||||
<property name="text">
|
||||
<string>Red</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QSpinBox" name="inRed">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>128</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_15">
|
||||
<property name="text">
|
||||
<string>Green</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QSpinBox" name="inGreen">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>128</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_16">
|
||||
<property name="text">
|
||||
<string>Blue</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QSpinBox" name="inBlue">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>128</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="KColorButton" name="inColor">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1" rowspan="2">
|
||||
<widget class="QTabWidget" name="tabs">
|
||||
<property name="tabPosition">
|
||||
<enum>QTabWidget::West</enum>
|
||||
</property>
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="tabLuma">
|
||||
<attribute name="title">
|
||||
<string>&Luma Effects</string>
|
||||
</attribute>
|
||||
<layout class="QGridLayout" name="gridLayout_8">
|
||||
<item row="0" column="0">
|
||||
<widget class="QGroupBox" name="gleOp">
|
||||
<property name="title">
|
||||
<string>Operation</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QRadioButton" name="leOpDarken">
|
||||
<property name="text">
|
||||
<string>Darken</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QRadioButton" name="leOpLighten">
|
||||
<property name="text">
|
||||
<string>Lighten</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QRadioButton" name="leOpShade">
|
||||
<property name="text">
|
||||
<string>Shade</string>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QGroupBox" name="gleOut">
|
||||
<property name="title">
|
||||
<string>Output</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_4">
|
||||
<item row="0" column="0">
|
||||
<widget class="KImageFrame" name="leOut">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>144</width>
|
||||
<height>144</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="frameShape">
|
||||
<enum>QFrame::StyledPanel</enum>
|
||||
</property>
|
||||
<property name="frameShadow">
|
||||
<enum>QFrame::Sunken</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tab_2">
|
||||
<attribute name="title">
|
||||
<string>&Mix/Tint</string>
|
||||
</attribute>
|
||||
<layout class="QGridLayout" name="gridLayout_11">
|
||||
<item row="0" column="0">
|
||||
<widget class="QGroupBox" name="gmtTarget">
|
||||
<property name="title">
|
||||
<string>Target</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_5">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label_11">
|
||||
<property name="text">
|
||||
<string>Red</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QSpinBox" name="mtRed">
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>128</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_12">
|
||||
<property name="text">
|
||||
<string>Green</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QSpinBox" name="mtGreen">
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>128</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_13">
|
||||
<property name="text">
|
||||
<string>Blue</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QSpinBox" name="mtBlue">
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>128</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="KColorButton" name="mtTarget"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QGroupBox" name="gmtMixOut">
|
||||
<property name="title">
|
||||
<string>Mix Output</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_10">
|
||||
<item row="0" column="0">
|
||||
<widget class="KImageFrame" name="mtMixOut">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="frameShape">
|
||||
<enum>QFrame::StyledPanel</enum>
|
||||
</property>
|
||||
<property name="frameShadow">
|
||||
<enum>QFrame::Sunken</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QGroupBox" name="gmtTintOut">
|
||||
<property name="title">
|
||||
<string>Tint Output</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_3">
|
||||
<item row="0" column="0">
|
||||
<widget class="KImageFrame" name="mtTintOut">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="frameShape">
|
||||
<enum>QFrame::StyledPanel</enum>
|
||||
</property>
|
||||
<property name="frameShadow">
|
||||
<enum>QFrame::Sunken</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tab">
|
||||
<attribute name="title">
|
||||
<string>&Scheme Shade</string>
|
||||
</attribute>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="gssParam">
|
||||
<property name="title">
|
||||
<string>Parameters</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_6">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Contrast</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QDoubleSpinBox" name="ssContrast">
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<double>-1.000000000000000</double>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<double>1.000000000000000</double>
|
||||
</property>
|
||||
<property name="singleStep">
|
||||
<double>0.010000000000000</double>
|
||||
</property>
|
||||
<property name="value">
|
||||
<double>0.700000000000000</double>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="text">
|
||||
<string>Chroma Adjust</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QDoubleSpinBox" name="ssChroma">
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<double>-1.000000000000000</double>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<double>1.000000000000000</double>
|
||||
</property>
|
||||
<property name="singleStep">
|
||||
<double>0.010000000000000</double>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="gssOut">
|
||||
<property name="title">
|
||||
<string>Output</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<property name="rightMargin">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="horizontalSpacing">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label_8">
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_3">
|
||||
<property name="text">
|
||||
<string>Light</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_4">
|
||||
<property name="text">
|
||||
<string>Midlight</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="label_10">
|
||||
<property name="text">
|
||||
<string>Base</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QLabel" name="label_5">
|
||||
<property name="text">
|
||||
<string>Mid</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QLabel" name="label_6">
|
||||
<property name="text">
|
||||
<string>Dark</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QLabel" name="label_7">
|
||||
<property name="text">
|
||||
<string>Shadow</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="0">
|
||||
<widget class="QLabel" name="label_9">
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1" rowspan="8">
|
||||
<widget class="QFrame" name="ssOut">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>120</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="frameShape">
|
||||
<enum>QFrame::StyledPanel</enum>
|
||||
</property>
|
||||
<property name="frameShadow">
|
||||
<enum>QFrame::Sunken</enum>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<property name="spacing">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QWidget" name="ssLight" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>16</width>
|
||||
<height>16</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QWidget" name="ssMidlight" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>16</width>
|
||||
<height>16</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QWidget" name="ssBase" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>16</width>
|
||||
<height>16</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QWidget" name="ssMid" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>16</width>
|
||||
<height>16</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QWidget" name="ssDark" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>16</width>
|
||||
<height>16</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QWidget" name="ssShadow" native="true">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>16</width>
|
||||
<height>16</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="autoFillBackground">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
<zorder>label_8</zorder>
|
||||
<zorder>label_3</zorder>
|
||||
<zorder>label_4</zorder>
|
||||
<zorder>label_10</zorder>
|
||||
<zorder>label_5</zorder>
|
||||
<zorder>label_6</zorder>
|
||||
<zorder>label_7</zorder>
|
||||
<zorder>label_9</zorder>
|
||||
<zorder>ssOut</zorder>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QGroupBox" name="gInfo">
|
||||
<property name="title">
|
||||
<string>Information</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label_17">
|
||||
<property name="text">
|
||||
<string>Hue</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QDoubleSpinBox" name="ifHue">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="decimals">
|
||||
<number>3</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_19">
|
||||
<property name="text">
|
||||
<string>Chroma</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QDoubleSpinBox" name="ifChroma">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="decimals">
|
||||
<number>3</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_18">
|
||||
<property name="text">
|
||||
<string>Luma</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QDoubleSpinBox" name="ifLuma">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="decimals">
|
||||
<number>3</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QLabel" name="label_20">
|
||||
<property name="text">
|
||||
<string>Gray Value</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QSpinBox" name="ifGray">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
<zorder>label_17</zorder>
|
||||
<zorder>ifHue</zorder>
|
||||
<zorder>label_19</zorder>
|
||||
<zorder>ifChroma</zorder>
|
||||
<zorder>label_18</zorder>
|
||||
<zorder>ifLuma</zorder>
|
||||
<zorder>label_20</zorder>
|
||||
<zorder>ifGray</zorder>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<customwidgets>
|
||||
<customwidget>
|
||||
<class>KColorButton</class>
|
||||
<extends>QPushButton</extends>
|
||||
<header>kcolorbutton.h</header>
|
||||
</customwidget>
|
||||
<customwidget>
|
||||
<class>KImageFrame</class>
|
||||
<extends>QFrame</extends>
|
||||
<header>kimageframe.h</header>
|
||||
<container>1</container>
|
||||
</customwidget>
|
||||
</customwidgets>
|
||||
<resources/>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>inRed</sender>
|
||||
<signal>valueChanged(int)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>inputSpinChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>126</x>
|
||||
<y>52</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>inGreen</sender>
|
||||
<signal>valueChanged(int)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>inputSpinChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>126</x>
|
||||
<y>84</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>inBlue</sender>
|
||||
<signal>valueChanged(int)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>inputSpinChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>126</x>
|
||||
<y>116</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>inColor</sender>
|
||||
<signal>changed(QColor)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>inputSwatchChanged(QColor)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>126</x>
|
||||
<y>146</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>leOpDarken</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>lumaChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>307</x>
|
||||
<y>60</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>leOpLighten</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>lumaChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>307</x>
|
||||
<y>88</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>leOpShade</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>lumaChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>307</x>
|
||||
<y>116</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>mtRed</sender>
|
||||
<signal>valueChanged(int)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>targetSpinChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>353</x>
|
||||
<y>129</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>mtGreen</sender>
|
||||
<signal>valueChanged(int)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>targetSpinChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>353</x>
|
||||
<y>161</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>mtBlue</sender>
|
||||
<signal>valueChanged(int)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>targetSpinChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>353</x>
|
||||
<y>193</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>mtTarget</sender>
|
||||
<signal>changed(QColor)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>targetSwatchChanged(QColor)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>353</x>
|
||||
<y>222</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>ssContrast</sender>
|
||||
<signal>valueChanged(double)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>shadeChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>362</x>
|
||||
<y>60</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>ssChroma</sender>
|
||||
<signal>valueChanged(double)</signal>
|
||||
<receiver>form</receiver>
|
||||
<slot>shadeChanged()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>362</x>
|
||||
<y>92</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>209</x>
|
||||
<y>171</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>inputChanged()</slot>
|
||||
<slot>inputSpinChanged()</slot>
|
||||
<slot>inputSwatchChanged(QColor)</slot>
|
||||
<slot>targetSpinChanged()</slot>
|
||||
<slot>targetSwatchChanged(QColor)</slot>
|
||||
<slot>lumaChanged()</slot>
|
||||
<slot>mixChanged()</slot>
|
||||
<slot>shadeChanged()</slot>
|
||||
</slots>
|
||||
</ui>
|
||||
@@ -0,0 +1,186 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2021 Waqar Ahmed <waqar.17a@gmail.com>
|
||||
*
|
||||
* SPDX-License-Identifier: LGPL-2.0-or-later
|
||||
*/
|
||||
#include <KCommandBar>
|
||||
#include <QMainWindow>
|
||||
|
||||
#include <QAction>
|
||||
#include <QApplication>
|
||||
#include <QDebug>
|
||||
#include <QMenu>
|
||||
#include <QPlainTextEdit>
|
||||
#include <QToolBar>
|
||||
#include <QVBoxLayout>
|
||||
|
||||
class Window;
|
||||
|
||||
/**
|
||||
* Fwd decl
|
||||
* A helper function to generate a QAction
|
||||
*/
|
||||
static QAction *genAction(Window *p, const QString &icon, int i, const int shortcut = Qt::CTRL);
|
||||
|
||||
class Window : public QMainWindow
|
||||
{
|
||||
public:
|
||||
Window(QWidget *parent = nullptr)
|
||||
: QMainWindow(parent)
|
||||
, pe(this)
|
||||
{
|
||||
setCentralWidget(&pe);
|
||||
|
||||
auto toolBar = new QToolBar(this);
|
||||
this->addToolBar(toolBar);
|
||||
|
||||
auto qo1 = toolBar->addAction(QStringLiteral("Open Command Bar"));
|
||||
connect(qo1, &QAction::triggered, this, [this] {
|
||||
KCommandBar *bar = new KCommandBar(this);
|
||||
bar->setActions(getActions());
|
||||
bar->show();
|
||||
});
|
||||
|
||||
auto qo2 = toolBar->addAction(QStringLiteral("Open Command Bar (RTL)"));
|
||||
connect(qo2, &QAction::triggered, this, [this] {
|
||||
KCommandBar *bar = new KCommandBar(this);
|
||||
bar->setActions(getRTLActions());
|
||||
bar->show();
|
||||
});
|
||||
}
|
||||
|
||||
QAction *getMenu()
|
||||
{
|
||||
QMenu *file = new QMenu(this);
|
||||
file->setTitle(QStringLiteral("File"));
|
||||
|
||||
auto createActionAndConnect = [file, this](const char *name) {
|
||||
auto a = file->addAction(QString::fromUtf8(name));
|
||||
connect(a, &QAction::triggered, [a, this] {
|
||||
pe.appendPlainText(a->text() + QStringLiteral(" triggered"));
|
||||
});
|
||||
};
|
||||
|
||||
createActionAndConnect("File Menu action 1");
|
||||
createActionAndConnect("File Menu act 2");
|
||||
return file->menuAction();
|
||||
}
|
||||
|
||||
QAction *getAboutToShowMenu()
|
||||
{
|
||||
QMenu *menu = new QMenu(this);
|
||||
menu->setTitle(QStringLiteral("Tool"));
|
||||
|
||||
connect(menu, &QMenu::aboutToShow, this, [this, menu] {
|
||||
if (!menu->actions().isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
auto createActionAndConnect = [menu, this](const char *name) {
|
||||
auto a = menu->addAction(QString::fromUtf8(name));
|
||||
connect(a, &QAction::triggered, [a, this] {
|
||||
pe.appendPlainText(a->text() + QStringLiteral(" triggered"));
|
||||
});
|
||||
};
|
||||
|
||||
createActionAndConnect("About to show action 1");
|
||||
createActionAndConnect("About to show 2");
|
||||
});
|
||||
return menu->menuAction();
|
||||
}
|
||||
|
||||
QList<KCommandBar::ActionGroup> getActions()
|
||||
{
|
||||
QList<KCommandBar::ActionGroup> acts(4);
|
||||
|
||||
/**
|
||||
* Menus with actions
|
||||
*/
|
||||
acts[0].actions = {getAboutToShowMenu(), getMenu()};
|
||||
|
||||
int i = 0;
|
||||
acts[1].name = QStringLiteral("First Menu Group");
|
||||
for (; i < 2; ++i) {
|
||||
acts[1].actions.append(genAction(this, QStringLiteral("folder"), i));
|
||||
}
|
||||
acts[1].actions[0]->setShortcut(QStringLiteral("G"));
|
||||
acts[1].actions[1]->setCheckable(true);
|
||||
acts[1].actions[1]->setShortcut(QStringLiteral("Ctrl++"));
|
||||
|
||||
acts[2].name = QStringLiteral("Second Menu Group - Disabled acts");
|
||||
for (; i < 4; ++i) {
|
||||
auto act = genAction(this, QStringLiteral("zoom-out"), i);
|
||||
act->setText(QStringLiteral("Disabled Act %1").arg(i));
|
||||
act->setEnabled(false);
|
||||
acts[2].actions.append(act);
|
||||
}
|
||||
|
||||
acts[3].name = QStringLiteral("Third Menu Group");
|
||||
for (; i < 6; ++i) {
|
||||
acts[3].actions.append(genAction(this, QStringLiteral("security-low"), i, Qt::CTRL | Qt::ALT));
|
||||
}
|
||||
acts[3].actions[0]->setCheckable(true);
|
||||
acts[3].actions[0]->setShortcut(QStringLiteral("Ctrl+,, Ctrl++, Ctrl+K"));
|
||||
|
||||
return acts;
|
||||
}
|
||||
|
||||
// Use ./bin/kcommandbartest -reverse to test this
|
||||
QList<KCommandBar::ActionGroup> getRTLActions()
|
||||
{
|
||||
QList<KCommandBar::ActionGroup> acts(2);
|
||||
|
||||
acts[0].name = QStringLiteral("مینو گروپ");
|
||||
acts[0].actions = {new QAction(QIcon::fromTheme("folder"), QStringLiteral("یہ فولڈر ایکشن ہے"), this),
|
||||
new QAction(QIcon::fromTheme("folder"), QStringLiteral("یہ ایک اور فولڈر ایکشن ہے"), this)};
|
||||
acts[0].actions[1]->setCheckable(true);
|
||||
acts[0].actions[1]->setShortcut(QStringLiteral("Ctrl+Shift++"));
|
||||
|
||||
acts[1].name = QStringLiteral("گروپ");
|
||||
acts[1].actions = {new QAction(QIcon::fromTheme("zoom-out"), QStringLiteral("یہ فولڈر ایکشن ہے"), this),
|
||||
new QAction(QIcon::fromTheme("security-low"), QStringLiteral("یہ ایک اور فولڈر ایکشن ہے"), this)};
|
||||
acts[1].actions[1]->setCheckable(true);
|
||||
acts[1].actions[1]->setShortcut(QStringLiteral("Ctrl+-"));
|
||||
|
||||
return acts;
|
||||
}
|
||||
|
||||
QPlainTextEdit *textEdit()
|
||||
{
|
||||
return &pe;
|
||||
}
|
||||
|
||||
private:
|
||||
QPlainTextEdit pe;
|
||||
};
|
||||
|
||||
static QAction *genAction(Window *p, const QString &icon, int i, const int shortcut)
|
||||
{
|
||||
QString text = QStringLiteral("A long long Action name %1").arg(i++);
|
||||
QAction *action = new QAction(QIcon::fromTheme(icon), text, p);
|
||||
QObject::connect(action, &QAction::triggered, [action, p] {
|
||||
p->textEdit()->appendPlainText(action->text() + QStringLiteral(" triggered"));
|
||||
});
|
||||
|
||||
static int key = Qt::Key_1;
|
||||
key++;
|
||||
// Reset
|
||||
if (key == Qt::Key_BraceRight) {
|
||||
key = Qt::Key_1;
|
||||
}
|
||||
const auto ss = shortcut | key;
|
||||
action->setShortcut(ss);
|
||||
return action;
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
QApplication app(argc, argv);
|
||||
QApplication::setApplicationName(QStringLiteral("kcommandbartest"));
|
||||
|
||||
Window *window = new Window();
|
||||
window->resize(1024, 600);
|
||||
window->show();
|
||||
|
||||
return app.exec();
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
/*
|
||||
SPDX-FileCopyrightText: 2009 Matthew Woehlke <mw_triad@users.sourceforge.net>
|
||||
|
||||
SPDX-License-Identifier: GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#include "kimageframe.h"
|
||||
#include <QPainter>
|
||||
#include <QStyle>
|
||||
#include <QStyleOption>
|
||||
|
||||
KImageFrame::KImageFrame(QWidget *parent)
|
||||
: QFrame(parent)
|
||||
, _w(0)
|
||||
, _h(0)
|
||||
{
|
||||
}
|
||||
|
||||
void KImageFrame::setImage(const QImage &img)
|
||||
{
|
||||
_img = img;
|
||||
_w = img.width();
|
||||
_h = img.height();
|
||||
update();
|
||||
}
|
||||
|
||||
void KImageFrame::paintEvent(QPaintEvent *)
|
||||
{
|
||||
QPainter p(this);
|
||||
QStyleOptionFrame opt;
|
||||
QRect rf(frameRect());
|
||||
QRect ri(0, 0, _w, _h);
|
||||
|
||||
opt.rect = rf;
|
||||
opt.state = QStyle::State_Sunken;
|
||||
|
||||
style()->drawPrimitive(QStyle::PE_Frame, &opt, &p, this);
|
||||
|
||||
ri.moveCenter(rf.center());
|
||||
p.drawImage(ri, _img);
|
||||
|
||||
p.end();
|
||||
}
|
||||
|
||||
#include "moc_kimageframe.cpp"
|
||||
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
SPDX-FileCopyrightText: 2009 Matthew Woehlke <mw_triad@users.sourceforge.net>
|
||||
|
||||
SPDX-License-Identifier: GPL-2.0-or-later
|
||||
*/
|
||||
|
||||
#ifndef KIMAGEFRAME_H
|
||||
#define KIMAGEFRAME_H
|
||||
|
||||
#include <QFrame>
|
||||
|
||||
class KImageFrame : public QFrame
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
KImageFrame(QWidget *parent = nullptr);
|
||||
~KImageFrame() override
|
||||
{
|
||||
}
|
||||
|
||||
public Q_SLOTS:
|
||||
void setImage(const QImage &);
|
||||
|
||||
protected Q_SLOTS:
|
||||
void paintEvent(QPaintEvent *) override;
|
||||
|
||||
protected:
|
||||
QImage _img;
|
||||
int _w, _h;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,21 @@
|
||||
/*
|
||||
This file is part of the KDE libraries
|
||||
SPDX-FileCopyrightText: 2013 David Faure <faure+bluesystem@kde.org>
|
||||
|
||||
SPDX-License-Identifier: LGPL-2.0-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
|
||||
*/
|
||||
|
||||
#include "klanguagebutton.h"
|
||||
|
||||
#include <QApplication>
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
QApplication::setApplicationName(QStringLiteral("KLanguageButtonTest"));
|
||||
QApplication app(argc, argv);
|
||||
|
||||
KLanguageButton button;
|
||||
button.loadAllLanguages();
|
||||
button.show();
|
||||
return app.exec();
|
||||
}
|
||||
@@ -0,0 +1,103 @@
|
||||
/*
|
||||
This file is part of the KDE libraries
|
||||
SPDX-FileCopyrightText: 2014 Gregor Mi <codeminister@publicstatic.de>
|
||||
|
||||
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
|
||||
*/
|
||||
|
||||
#include "krecentfilesactiontest.h"
|
||||
|
||||
#include <QApplication>
|
||||
#include <QDebug>
|
||||
|
||||
#include "krecentfilesaction.h"
|
||||
#include "kstandardaction.h"
|
||||
#include <KConfigGroup>
|
||||
#include <KSharedConfig>
|
||||
|
||||
#include "ui_krecentfilesactiontest.h"
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
QApplication app(argc, argv);
|
||||
KRecentFilesActionTest mainWindow;
|
||||
mainWindow.show();
|
||||
return app.exec();
|
||||
}
|
||||
|
||||
class KRecentFilesActionTestPrivate
|
||||
{
|
||||
public:
|
||||
Ui::MainWindow *uiMainWindow;
|
||||
KRecentFilesAction *recentFiles;
|
||||
|
||||
public:
|
||||
void notifyOutputAvailable()
|
||||
{
|
||||
uiMainWindow->labelOutputAvailable->setText(uiMainWindow->labelOutputAvailable->text() + QLatin1Char('A'));
|
||||
qDebug() << recentFiles->items();
|
||||
}
|
||||
|
||||
KConfigGroup testConfigGroup()
|
||||
{
|
||||
return KConfigGroup(KSharedConfig::openConfig(), "RecentFilesActionTest");
|
||||
}
|
||||
};
|
||||
|
||||
KRecentFilesActionTest::KRecentFilesActionTest()
|
||||
: d(new KRecentFilesActionTestPrivate)
|
||||
{
|
||||
d->uiMainWindow = new Ui::MainWindow();
|
||||
d->uiMainWindow->setupUi(this);
|
||||
|
||||
d->recentFiles = KStandardAction::openRecent(this, &KRecentFilesActionTest::urlSelected, this);
|
||||
|
||||
connect(d->uiMainWindow->pbAddUrl, &QPushButton::clicked, this, &KRecentFilesActionTest::addUrl);
|
||||
connect(d->uiMainWindow->pbLoadEntries, &QPushButton::clicked, this, &KRecentFilesActionTest::loadEntries);
|
||||
connect(d->uiMainWindow->pbSaveEntries, &QPushButton::clicked, this, &KRecentFilesActionTest::saveEntries);
|
||||
|
||||
d->uiMainWindow->menuFile->addAction(d->recentFiles);
|
||||
|
||||
// loadEntries();
|
||||
}
|
||||
|
||||
KRecentFilesActionTest::~KRecentFilesActionTest()
|
||||
{
|
||||
// saveEntries();
|
||||
|
||||
delete d->uiMainWindow;
|
||||
delete d;
|
||||
}
|
||||
|
||||
void KRecentFilesActionTest::urlSelected(const QUrl &url)
|
||||
{
|
||||
qDebug() << "urlSelected" << url;
|
||||
d->notifyOutputAvailable();
|
||||
}
|
||||
|
||||
void KRecentFilesActionTest::addUrl()
|
||||
{
|
||||
QString url = d->uiMainWindow->lineEditUrl->text();
|
||||
qDebug() << "addUrl" << url;
|
||||
|
||||
d->recentFiles->addUrl(QUrl(url));
|
||||
|
||||
d->notifyOutputAvailable();
|
||||
d->uiMainWindow->lineEditUrl->setText(url + QLatin1Char('a'));
|
||||
}
|
||||
|
||||
void KRecentFilesActionTest::loadEntries()
|
||||
{
|
||||
d->notifyOutputAvailable();
|
||||
qDebug() << "recentFiles->loadEntries()";
|
||||
d->recentFiles->loadEntries(d->testConfigGroup());
|
||||
d->notifyOutputAvailable();
|
||||
}
|
||||
|
||||
void KRecentFilesActionTest::saveEntries()
|
||||
{
|
||||
qDebug() << "recentFiles->saveEntries()";
|
||||
d->recentFiles->saveEntries(d->testConfigGroup());
|
||||
}
|
||||
|
||||
#include "moc_krecentfilesactiontest.cpp"
|
||||
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
This file is part of the KDE libraries
|
||||
SPDX-FileCopyrightText: 2014 Gregor Mi <codeminister@publicstatic.de>
|
||||
|
||||
SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
|
||||
*/
|
||||
|
||||
#ifndef KCONFIGWIDGETS_TESTS_KRECENTFILESACTIONTEST_H
|
||||
#define KCONFIGWIDGETS_TESTS_KRECENTFILESACTIONTEST_H
|
||||
|
||||
#include <QMainWindow>
|
||||
|
||||
class KRecentFilesActionTestPrivate;
|
||||
|
||||
class KRecentFilesActionTest : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
KRecentFilesActionTest();
|
||||
|
||||
~KRecentFilesActionTest() override;
|
||||
|
||||
public Q_SLOTS:
|
||||
void addUrl();
|
||||
void loadEntries();
|
||||
void saveEntries();
|
||||
void urlSelected(const QUrl &url);
|
||||
|
||||
private:
|
||||
KRecentFilesActionTestPrivate *const d;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,140 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>MainWindow</class>
|
||||
<widget class="QMainWindow" name="MainWindow">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>434</width>
|
||||
<height>201</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>KRecentFilesAction Test</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="centralwidget">
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Look in the File menu to use the Open Recent menu</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="pbAddUrl">
|
||||
<property name="text">
|
||||
<string>Add URL</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEditUrl">
|
||||
<property name="text">
|
||||
<string>~/tmp/test1.txt</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_3">
|
||||
<property name="text">
|
||||
<string>Add URL to recent file list</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="text">
|
||||
<string>Note that nonexisting entries will not be restored.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<item>
|
||||
<widget class="QPushButton" name="pbLoadEntries">
|
||||
<property name="text">
|
||||
<string>LoadEntries</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pbSaveEntries">
|
||||
<property name="text">
|
||||
<string>SaveEntries</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<widget class="QLabel" name="label1">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>New console output:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="labelOutputAvailable">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
||||
<horstretch>1</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>A</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QMenuBar" name="menubar">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>434</width>
|
||||
<height>19</height>
|
||||
</rect>
|
||||
</property>
|
||||
<widget class="QMenu" name="menuFile">
|
||||
<property name="title">
|
||||
<string>File</string>
|
||||
</property>
|
||||
</widget>
|
||||
<addaction name="menuFile"/>
|
||||
</widget>
|
||||
<widget class="QStatusBar" name="statusbar"/>
|
||||
</widget>
|
||||
<resources/>
|
||||
<connections/>
|
||||
</ui>
|
||||
Reference in New Issue
Block a user