23 #include <QDialogButtonBox> 24 #include <QVBoxLayout> 27 #include <QScrollArea> 36 setWindowTitle(
tr(
"À propos de QElectrotech",
"window title"));
37 setFixedSize (1200, 600);
43 QTabWidget *tabs =
new QTabWidget();
44 tabs -> addTab(
aboutTab(),
tr(
"À &propos",
"tab title"));
45 tabs -> addTab(
authorsTab(),
tr(
"A&uteurs",
"tab title"));
48 tabs -> addTab(
titleTab(),
tr(
"&Version",
"tab title"));
49 tabs -> addTab(
licenseTab(),
tr(
"&Accord de licence",
"tab title"));
51 QDialogButtonBox *buttons =
new QDialogButtonBox(QDialogButtonBox::Close);
52 connect(buttons, SIGNAL(accepted()),
this, SLOT(accept()));
53 connect(buttons, SIGNAL(rejected()),
this, SLOT(accept()));
55 QVBoxLayout *vlayout =
new QVBoxLayout(
this);
56 vlayout->addWidget(tabs);
57 vlayout->addWidget(buttons);
59 QScrollArea* scrollArea =
new QScrollArea(
this);
60 scrollArea->setWidgetResizable(
true);
61 scrollArea->setFixedSize (1090, 590);
62 scrollArea->setWidget(tabs);
76 QLabel *title =
new QLabel(
"<span style=\"font-weight:0;font-size:16pt;\">QElectroTech V " +
QET::displayedVersion +
"</span>");
77 QString compilation_info =
"<br />" +
tr(
"Compilation : ");
80 compilation_info +=
" CLANG " + QString(__clang_version__ );
81 compilation_info +=
" - built with Qt " + QString(QT_VERSION_STR);
82 compilation_info +=
" - Date : " + QString(__DATE__);
83 compilation_info +=
" : " + QString(__TIME__);
84 compilation_info +=
" - run with Qt "+ QString(qVersion());
85 compilation_info +=
" using" + QString(
" %1 thread(s)").arg(QThread::idealThreadCount());
86 compilation_info +=
"<br>" " OS : " + QString(QSysInfo::kernelType());
87 compilation_info +=
" - " + QString(QSysInfo::currentCpuArchitecture());
88 compilation_info +=
" - Version : " + QString(QSysInfo::prettyProductName());
89 compilation_info +=
"</br>" " - Kernel : " + QString(QSysInfo::kernelVersion());
91 compilation_info +=
" GCC " + QString(__VERSION__);
92 compilation_info +=
" - built with Qt " + QString(QT_VERSION_STR);
93 compilation_info +=
" - Date : " + QString(__DATE__);
94 compilation_info +=
" : " + QString(__TIME__);
95 compilation_info +=
" - run with Qt "+ QString(qVersion());
96 compilation_info +=
" using" + QString(
" %1 thread(s)").arg(QThread::idealThreadCount());
97 compilation_info +=
"<br>" " OS : " + QString(QSysInfo::kernelType());
98 compilation_info +=
" - " + QString(QSysInfo::currentCpuArchitecture());
99 compilation_info +=
" - Version : " + QString(QSysInfo::prettyProductName());
100 compilation_info +=
"</br>" " - Kernel : " + QString(QSysInfo::kernelVersion());
103 title -> setAlignment(Qt::AlignCenter);
104 title -> setText(title->text() + compilation_info);
105 title -> setTextFormat(Qt::RichText);
106 title ->setTextInteractionFlags(Qt::TextSelectableByMouse);
114 QLabel *about =
new QLabel(
115 tr(
"QElectroTech, une application de réalisation de schémas électriques.",
"about tab, description line") +
117 tr(
"2006-2019 Les développeurs de QElectroTech",
"about tab, developers line") +
119 "<a href=\"https://qelectrotech.org/\">https://qelectrotech.org/</a>" 121 tr(
"Contact : <a href=\"mailto:qet@lists.tuxfamily.org\">qet@lists.tuxfamily.org</a>",
"about tab, contact line")
123 about -> setAlignment(Qt::AlignCenter);
124 about -> setOpenExternalLinks(
true);
125 about -> setTextFormat(Qt::RichText);
134 QLabel *authors =
new QLabel();
135 addAuthor(authors,
"Benoît Ansieau",
"benoit@qelectrotech.org",
tr(
"Idée originale"));
136 addAuthor(authors,
"Laurent Trinques",
"scorpio@qelectrotech.org",
tr(
"Développement"));
137 addAuthor(authors,
"Joshua Claveau",
"Joshua@qelectrotech.org",
tr(
"Développement"));
138 addAuthor(authors,
"Davi Fochi",
"davi@fochi.com.br",
tr(
"Développement"));
139 addAuthor(authors,
"Ronny Desmedt",
"r.desmedt@live.be",
tr(
"Convertisseur DXF"));
140 addAuthor(authors,
"Raul Roda",
"raulroda8@gmail.com",
tr(
"Plugin Bornier"));
141 addAuthor(authors,
"Abhishek Bansal",
"abhishek@qelectrotech.org",
tr(
"Développement"));
146 authors -> setOpenExternalLinks(
true);
147 authors -> setTextFormat(Qt::RichText);
149 QWidget *authors_widget =
new QWidget();
150 QHBoxLayout *authors_layout =
new QHBoxLayout(authors_widget);
151 authors_layout -> addWidget(authors, 0, Qt::AlignCenter);
152 return(authors_widget);
159 QLabel *translators =
new QLabel();
161 addAuthor(translators,
"Alfredo Carreto",
"electronicos_mx@yahoo.com.mx",
tr(
"Traduction en espagnol"));
162 addAuthor(translators,
"Edgar Robles Najar",
"tgo.edrobles@gmail.com",
tr(
"Traduction en espagnol"));
163 addAuthor(translators,
"Yuriy Litkevich",
"yuriy@qelectrotech.org",
tr(
"Traduction en russe"));
164 addAuthor(translators,
"Evgeny Kozlov",
"Evgeny.Kozlov.mailbox@gmail.com",
tr(
"Traduction en russe"));
165 addAuthor(translators,
"José Carlos Martins",
"jose@qelectrotech.org",
tr(
"Traduction en portugais"));
166 addAuthor(translators,
"Pavel Fric",
"pavelfric@seznam.cz",
tr(
"Traduction en tchèque"));
167 addAuthor(translators,
"Paweł Śmiech",
"pawel32640@gmail.com",
tr(
"Traduction en polonais"));
168 addAuthor(translators,
"Markus Budde & Jonas Stein & Noah Braden",
"news@jonasstein.de",
tr(
"Traduction en allemand"));
169 addAuthor(translators,
"Nuri",
"nuri@qelectrotech.org",
tr(
"Traduction en allemand"));
170 addAuthor(translators,
"Gabi Mandoc",
"gabriel.mandoc@gic.ro",
tr(
"Traduction en roumain"));
171 addAuthor(translators,
"Alessandro Conti & Silvio",
"silvio@qelectrotech.org",
tr(
"Traduction en italien"));
172 addAuthor(translators,
"Mohamed Souabni",
"souabnimohamed@yahoo.fr",
tr(
"Traduction en arabe"));
173 addAuthor(translators,
"Antun Maraković",
"antun.marakovic@lolaribar.hr",
tr(
"Traduction en croate"));
174 addAuthor(translators,
"Eduard Amorós",
"amoros@marmenuda.com",
tr(
"Traduction en catalan"));
175 addAuthor(translators,
"Nikos Papadopoylos",
"231036448@freemail.gr",
tr(
"Traduction en grec"));
176 addAuthor(translators,
"Yannis Gyftomitros",
"yang@hellug.gr",
tr(
"Traduction en grec"));
177 addAuthor(translators,
"Paul Van Deelen",
"shooter@home.nl",
tr(
"Traduction en néerlandais"));
178 addAuthor(translators,
"Dik Leenheer",
"dleenheer@suzerein.nl",
tr(
"Traduction en néerlandais"));
179 addAuthor(translators,
"Ronny Desmedt",
"r.desmedt@live.be",
tr(
"Traduction en flamand"));
180 addAuthor(translators,
"OSS au2mation",
"OSSau2mation@OSSau2mation.dk",
tr(
"Traduction en danois"));
181 addAuthor(translators,
"Hilario Silveira",
"hilario@soliton.com.br",
tr(
"Traduction en brézilien"));
182 addAuthor(translators,
"Aziz Karabudak",
"aziz.karabudak@argevi.com",
tr(
"Traduction en Turc"));
183 addAuthor(translators,
"Gábor Gubányi",
"gubanyig@gmail.com",
tr(
"Traduction en hongrois"));
188 translators -> setOpenExternalLinks(
true);
189 translators -> setTextFormat(Qt::RichText);
191 QWidget *translators_widget =
new QWidget();
192 QHBoxLayout *translators_layout =
new QHBoxLayout(translators_widget);
193 translators_layout -> addWidget(translators, 0, Qt::AlignCenter);
194 return(translators_widget);
201 QLabel *contributors =
new QLabel();
203 addAuthor(contributors,
"Remi Collet",
"remi@fedoraproject.org",
tr(
"Paquets Fedora et Red Hat"));
204 addAuthor(contributors,
"David Geiger",
"david.david@mageialinux-online.org",
tr(
"Paquets Mageia"));
205 addAuthor(contributors,
"Laurent Trinques",
"scorpio@qelectrotech.org",
tr(
"Paquets Debian"));
206 addAuthor(contributors,
"Denis Briand",
"debian@denis-briand.fr",
tr(
"Paquets Debian"));
207 addAuthor(contributors,
"W. Martin Borgert",
"debacle@debian.org",
tr(
"Paquets Debian"));
208 addAuthor(contributors,
"Markos Chandras",
"hwoarang@gentoo.org.",
tr(
"Paquets Gentoo"));
209 addAuthor(contributors,
"Mbit",
"",
tr(
"Paquets Gentoo"));
210 addAuthor(contributors,
"Elbert",
"",
tr(
"Paquets OS/2"));
211 addAuthor(contributors,
"zloidemon",
"",
tr(
"Paquets FreeBSD"));
212 addAuthor(contributors,
"Yoann Varenne",
"yoann@tuxfamily.org",
tr(
"Paquets MAC OS X"));
213 addAuthor(contributors,
"Chipsterjulien",
"",
tr(
"Paquets Archlinux AUR"));
214 addAuthor(contributors,
"Nuno Pinheiro",
"nuno@nuno-icons.com",
tr(
"Icônes"));
215 addAuthor(contributors,
"Cyril Frausti",
"cyril@qelectrotech.org",
tr(
"Développement"));
216 addAuthor(contributors,
"Fernando Mateu Palou de Comasema",
"fdomateu@gmail.com",
tr(
"Documentation"));
217 addAuthor(contributors,
"Arun Kishore Eswara",
"eswara.arun@gmail.com",
tr(
"Documentation"));
218 addAuthor(contributors,
"René Negre",
"runsys@qelectrotech.org",
tr(
"Développement"));
219 addAuthor(contributors,
"Nuri",
"nuri@qelectrotech.org",
tr(
"Collection d'éléments"));
220 addAuthor(contributors,
"Raul Roda",
"",
tr(
"Python plugin qet-tb-generator"));
222 contributors -> setOpenExternalLinks(
true);
223 contributors -> setTextFormat(Qt::RichText);
225 QWidget *contributors_widget =
new QWidget();
226 QHBoxLayout *contributors_layout =
new QHBoxLayout(contributors_widget);
227 contributors_layout -> addWidget(contributors, 0, Qt::AlignCenter);
228 return(contributors_widget);
235 QWidget *
license =
new QWidget();
237 QLabel *title_license =
new QLabel(
tr(
"Ce programme est sous licence GNU/GPL."));
240 QTextEdit *text_license =
new QTextEdit();
242 text_license -> setReadOnly(
true);
245 QVBoxLayout *license_layout =
new QVBoxLayout();
246 license_layout -> addWidget(title_license);
247 license_layout -> addWidget(text_license);
248 license -> setLayout(license_layout);
259 void AboutQET::addAuthor(QLabel *label,
const QString &name,
const QString &email,
const QString &work)
const {
260 QString new_text = label -> text();
262 QString author_template =
"<span style=\"text-decoration: underline;\">%1</span> : %2 <<a href=\"mailto:%3\">%3</a>>‎<br/><br/>";
265 new_text += author_template.arg(work).arg(name).arg(email);
266 label -> setText(new_text);
const QString displayedVersion
QElectroTech displayed version.
AboutQET(QWidget *=nullptr)
AboutQET::AboutQET.
QWidget * authorsTab() const
QWidget * translatorsTab() const
void addAuthor(QLabel *, const QString &, const QString &, const QString &) const
QWidget * licenseTab() const
QWidget * titleTab() const
QWidget * contributorsTab() const
QWidget * aboutTab() const