42 QWidget* headerWidget =
new QWidget(
this);
43 headerWidget->setStyleSheet(
45 "background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, "
46 "stop:0 #2c3e50, stop:1 #34495e); "
49 headerWidget->setMinimumHeight(100);
51 QVBoxLayout* headerLayout =
new QVBoxLayout(headerWidget);
52 headerLayout->setContentsMargins(20, 20, 20, 20);
55 QLabel* titleLabel =
new QLabel(tr(
"SedSat3"), headerWidget);
56 QFont titleFont = titleLabel->font();
57 titleFont.setPointSize(24);
58 titleFont.setBold(
true);
59 titleLabel->setFont(titleFont);
60 titleLabel->setStyleSheet(
"QLabel { color: white; }");
61 titleLabel->setAlignment(Qt::AlignCenter);
64 QLabel* subtitleLabel =
new QLabel(
65 tr(
"Sediment Source Assessment Tool, version 3"),
68 QFont subtitleFont = subtitleLabel->font();
69 subtitleFont.setPointSize(11);
70 subtitleLabel->setFont(subtitleFont);
71 subtitleLabel->setStyleSheet(
"QLabel { color: #ecf0f1; }");
72 subtitleLabel->setAlignment(Qt::AlignCenter);
74 headerLayout->addWidget(titleLabel);
75 headerLayout->addWidget(subtitleLabel);
82 QWidget* infoWidget =
new QWidget(
this);
83 infoWidget->setStyleSheet(
"QWidget { background-color: white; }");
85 QVBoxLayout* infoLayout =
new QVBoxLayout(infoWidget);
86 infoLayout->setContentsMargins(20, 20, 20, 10);
87 infoLayout->setSpacing(10);
92 boldFont.setPointSize(10);
100 QLabel* authorsLabel =
new QLabel(tr(
"<b>Authors:</b>"), infoWidget);
101 authorsLabel->setFont(boldFont);
103 QLabel* authorsText =
new QLabel(
104 tr(
"Arash Massoudieh<br>"
106 "Cara Peterman Phipps"),
109 authorsText->setIndent(20);
110 authorsText->setTextFormat(Qt::RichText);
113 QLabel* descriptionLabel =
new QLabel(
114 tr(
"<b>Description:</b>"),
117 descriptionLabel->setFont(boldFont);
121 infoLayout->addSpacing(10);
122 infoLayout->addWidget(authorsLabel);
123 infoLayout->addWidget(authorsText);
124 infoLayout->addSpacing(10);
125 infoLayout->addWidget(descriptionLabel);
160 QWidget* footerWidget =
new QWidget(
this);
161 footerWidget->setStyleSheet(
"QWidget { background-color: #f8f9fa; }");
163 QVBoxLayout* footerLayout =
new QVBoxLayout(footerWidget);
164 footerLayout->setContentsMargins(20, 15, 20, 15);
165 footerLayout->setSpacing(10);
168 QLabel* copyrightLabel =
new QLabel(
169 tr(
"U.S. Geological Survey software. This software is preliminary or provisional;\n"
170 "see DISCLAIMER.md and LICENSE.md distributed with it."),
173 copyrightLabel->setAlignment(Qt::AlignCenter);
174 QFont copyrightFont = copyrightLabel->font();
175 copyrightFont.setPointSize(9);
176 copyrightLabel->setFont(copyrightFont);
177 copyrightLabel->setStyleSheet(
"QLabel { color: #6c757d; }");
180 QPushButton* closeButton =
new QPushButton(tr(
"Close"), footerWidget);
181 closeButton->setMinimumWidth(100);
182 closeButton->setStyleSheet(
184 "background-color: #3498db; "
187 "padding: 8px 16px; "
188 "border-radius: 4px; "
189 "font-weight: bold; "
191 "QPushButton:hover { "
192 "background-color: #2980b9; "
194 "QPushButton:pressed { "
195 "background-color: #21618c; "
199 connect(closeButton, &QPushButton::clicked,
this, &AboutDialog::accept);
202 QHBoxLayout* buttonLayout =
new QHBoxLayout();
203 buttonLayout->addStretch();
204 buttonLayout->addWidget(closeButton);
205 buttonLayout->addStretch();
207 footerLayout->addWidget(copyrightLabel);
208 footerLayout->addLayout(buttonLayout);