mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
HTML: Add export list only option
Exporting small dive list only or choose to export the dive list with all the dive details like the profile, Bookmarks, dive equipments and statistics. Signed-off-by: Gehad elrobey <gehadelrobey@gmail.com> Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
ccfdcca6e6
commit
e9c4259db4
5 changed files with 30 additions and 23 deletions
|
@ -79,7 +79,7 @@ void DiveLogExportDialog::exportHtmlInit(const QString &filename)
|
|||
QString json_settings = exportFiles + QDir::separator() + "settings.json";
|
||||
|
||||
exportHTMLsettings(json_settings);
|
||||
export_HTML(json_dive_data.toUtf8().data(), ui->exportSelectedDives->isChecked());
|
||||
export_HTML(json_dive_data.toUtf8().data(), ui->exportSelectedDives->isChecked(), ui->exportListOnly->isChecked());
|
||||
|
||||
QString searchPath = getSubsurfaceDataPath("theme");
|
||||
if (searchPath.isEmpty())
|
||||
|
@ -114,7 +114,8 @@ void DiveLogExportDialog::exportHTMLsettings(const QString &filename)
|
|||
QFile file(filename);
|
||||
file.open(QIODevice::WriteOnly | QIODevice::Text);
|
||||
QTextStream out(&file);
|
||||
out << "settings = {\"fontSize\":\"" << fontSize << "\",\"fontFamily\":\"" << fontFamily << "\",}";
|
||||
out << "settings = {\"fontSize\":\"" << fontSize << "\",\"fontFamily\":\"" << fontFamily << "\",\"listOnly\":\""<<
|
||||
ui->exportListOnly->isChecked() << "\",}";
|
||||
file.close();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue