Part 4 of the new GSoC printing module from Gehad. Adds: 1) Better greyscale conversations when "print in color" is de-selected. Due to a QPrinter->setColorMode() bug we are forced to rasterize the entire page (profile, tables, everything) when in greyscale. We have faced some limitations here including the fact that Profile2 support for custom color tables is incomplete. Consider this the cheaper solution and if the GSoC timeframe allows it, we can invest more time into attempting proper greyscale vector prints using the custom color table and so on.
2) A preview graphic in the "Template edit" dialog When editing a template, gitting "Apply will allow you to review your changes in the dialog itself. 3) Custom CSS colors and color themes Basically you can save your preferred color scheme, containing a set of common colors and use it for all templates. Also, you can edit a template itself directly and use a hardcoded color e.g. #fafafa for backgrounds. 4) More generic fixes... ATM this is useable, but the stock templates aren't pretty yet; an important thing on the TODO list is to get the already present templates to look similar to what we in the previous print module (i.e. user-ready). Feedback on the usability itself will soon be needed from the community! ATM, given you have libgrantlee installed you can try building with NO_PRINTING=0 and submit feedback to one of the related ML threads. ------ The following changes since commit 05109b2d6c7e8ef816b1290c583492dec78b3f07: Don't hide location completion when user types space (2015-07-18 13:39:19 -0700) are available in the git repository at: g...@github.com:neolit123/subsurface.git custom-print for you to fetch changes up to 599920c6cfd87a213634097045e29f592390438b: Printing: export grayscale filter value to template (2015-07-20 15:29:05 +0300) ---------------------------------------------------------------- Gehad elrobey (24): Printing: overwrite the old custom template file Printing: show confirmation message before overwriting the template Printing: enhance the one_dive per page template Printing: handle memory leak in printer class Printing: refactoring printer class Printing: change QPrinter to parent class QPaintDevice Printing: check for different printing modes Printing: add preview to TemplateEdit dialog Printing: save only if data is changed in template_options Printing: add apply button to TemplateEdit class Printing: update preview on apply settings Printing: update preview on field changes Printing: add colors tab to edit window Printing: show colors in edit tab Printing: implement edit buttons in color tab Printing: save custom color palette to QSettings Printing: export color settings to grantlee Printing: make templates support custom colors Printing: add custom color palette Printing: change 'Discard' to 'Cancel' button Printing: add default case to switch Printing: transfer profile to QImage if grayscale Printing: add css filter to templates Printing: export grayscale filter value to template printer.cpp | 109 +++++++++++----- printer.h | 15 ++- printing_templates/one_dive.html | 44 ++++--- printing_templates/two_dives.html | 10 +- qt-ui/printdialog.cpp | 33 ++++- qt-ui/printoptions.h | 25 +++- qt-ui/templateedit.cpp | 140 ++++++++++++++++++-- qt-ui/templateedit.h | 9 +- qt-ui/templateedit.ui | 261 ++++++++++++++++++++++++++++++++++---- templatelayout.cpp | 3 + templatelayout.h | 21 +++ 11 files changed, 581 insertions(+), 89 deletions(-) _______________________________________________ subsurface mailing list subsurface@subsurface-divelog.org http://lists.subsurface-divelog.org/cgi-bin/mailman/listinfo/subsurface