diff options
Diffstat (limited to 'src/pdf_formatter.cc')
| -rw-r--r-- | src/pdf_formatter.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/pdf_formatter.cc b/src/pdf_formatter.cc index 0ec77c4b..3e4e5c09 100644 --- a/src/pdf_formatter.cc +++ b/src/pdf_formatter.cc @@ -24,7 +24,9 @@ #include <fmt/format.h> +using std::string; using std::unique_ptr; +using std::vector; using namespace dcp; @@ -234,7 +236,7 @@ PDFFormatter::wrapped_text(float x, float first_line_indent, float font_size, dc void -PDFFormatter::list_item(std::string const& text, boost::optional<std::string> type) +PDFFormatter::list_item(std::string const& text, boost::optional<std::string> type, vector<string> const& details) { float const indent = 16 * _indent; float constexpr dot_radius = 1.5; @@ -253,6 +255,9 @@ PDFFormatter::list_item(std::string const& text, boost::optional<std::string> ty } wrapped_text(indent, dot_radius * 6, font_size, colour, text, (page_width - horizontal_margin * 2) * dpi, font_size * 1.2); + for (auto const& detail: details) { + wrapped_text(indent + 16, dot_radius * 6, font_size, colour, text, (page_width - horizontal_margin * 2) * dpi, font_size * 1.2); + } } |
