gnucash maint: Multiple changes pushed
Geert Janssens
gjanssens at code.gnucash.org
Wed Aug 16 10:34:33 EDT 2017
Updated via https://github.com/Gnucash/gnucash/commit/1559d264 (commit)
via https://github.com/Gnucash/gnucash/commit/2bc106a7 (commit)
from https://github.com/Gnucash/gnucash/commit/190a96fa (commit)
commit 1559d2646559ef37d8fdb107bc6111f1e29c4e92
Author: christopherlam <christopher.lck at gmail.com>
Date: Thu Aug 3 18:33:36 2017 +0800
Remove clutter from generated html
diff --git a/src/report/report-system/html-document.scm b/src/report/report-system/html-document.scm
index 0afb6a3..295ba76 100644
--- a/src/report/report-system/html-document.scm
+++ b/src/report/report-system/html-document.scm
@@ -168,7 +168,7 @@
(let ((title (gnc:html-document-title doc)))
(if title
(push (list "</title>" title "<title>\n"))))
- (push "</head>\n")
+ (push "</head>")
;; this lovely little number just makes sure that <body>
;; attributes like bgcolor get included
@@ -286,7 +286,7 @@
(attr (gnc:warn "non-string attribute" attr)))))
(build-first-tag
(lambda (tag)
- (push "\n<") (push tag)
+ (push "<") (push tag)
(if attr (hash-fold add-attribute #f attr))
(if extra-attrib (for-each addextraatt extra-attrib))
(if (not end-tag?)
@@ -395,7 +395,7 @@
(lambda (obj doc)
(gnc:html-document-render-data doc obj))
;; if the object is #f, make it a placeholder
- (if obj obj " ")))
+ (if obj obj " ")))
(cond
((gnc:html-text? obj)
(set! o (gnc:make-html-object-internal
diff --git a/src/report/report-system/html-table.scm b/src/report/report-system/html-table.scm
index 59b4802..ae21218 100644
--- a/src/report/report-system/html-table.scm
+++ b/src/report/report-system/html-table.scm
@@ -702,7 +702,7 @@
#f)
#f (gnc:html-table-col-styles table))
- (push (gnc:html-document-markup-start doc "tbody" #t))
+ (push (gnc:html-document-markup-start doc "tbody" #t))
;; now iterate over the rows
(let ((rownum 0) (colnum 0))
(for-each
@@ -752,7 +752,7 @@
(set! colnum 0)
(set! rownum (+ 1 rownum))))
(reverse (gnc:html-table-data table))))
- (push (gnc:html-document-markup-end doc "tbody"))
+ (push (gnc:html-document-markup-end doc "tbody"))
;; write the table end tag and pop the table style
(push (gnc:html-document-markup-end doc "table"))
commit 2bc106a7b7163c9edbe6634683d3666a5853c933
Author: christopherlam <christopher.lck at gmail.com>
Date: Thu Aug 3 18:24:03 2017 +0800
Partial fix for bug 660027
Encapsulate table header and body with <thead> and <tbody>
and prevent page-breaks within a <tr>
diff --git a/src/report/report-system/html-fonts.scm b/src/report/report-system/html-fonts.scm
index c769f94..8ad15bd 100644
--- a/src/report/report-system/html-fonts.scm
+++ b/src/report/report-system/html-fonts.scm
@@ -159,6 +159,7 @@
"a { " account-link-font-info " }\n"
"body, p, table, tr, td { text-align: left; vertical-align: top; " text-cell-font-info " }\n"
"tr.alternate-row { background: " alternate-row-color " }\n"
+ "tr { page-break-inside: avoid !important;}\n"
"th.column-heading-left { text-align: left; " number-header-font-info " }\n"
"th.column-heading-center { text-align: center; " number-header-font-info " }\n"
"th.column-heading-right { text-align: right; " number-header-font-info " }\n"
diff --git a/src/report/report-system/html-table.scm b/src/report/report-system/html-table.scm
index 8437b29..59b4802 100644
--- a/src/report/report-system/html-table.scm
+++ b/src/report/report-system/html-table.scm
@@ -668,6 +668,7 @@
#f (gnc:html-table-col-styles table))
;; render the headers
+ (push (gnc:html-document-markup-start doc "thead" #t))
(push (gnc:html-document-markup-start doc "tr" #t))
(for-each
(lambda (hdr)
@@ -685,6 +686,7 @@
colnum))))
ch)
(push (gnc:html-document-markup-end doc "tr"))
+ (push (gnc:html-document-markup-end doc "thead"))
;; pop the col header style
(gnc:html-document-pop-style doc))))
@@ -700,6 +702,7 @@
#f)
#f (gnc:html-table-col-styles table))
+ (push (gnc:html-document-markup-start doc "tbody" #t))
;; now iterate over the rows
(let ((rownum 0) (colnum 0))
(for-each
@@ -749,6 +752,7 @@
(set! colnum 0)
(set! rownum (+ 1 rownum))))
(reverse (gnc:html-table-data table))))
+ (push (gnc:html-document-markup-end doc "tbody"))
;; write the table end tag and pop the table style
(push (gnc:html-document-markup-end doc "table"))
Summary of changes:
src/report/report-system/html-document.scm | 6 +++---
src/report/report-system/html-fonts.scm | 1 +
src/report/report-system/html-table.scm | 4 ++++
3 files changed, 8 insertions(+), 3 deletions(-)
More information about the gnucash-changes
mailing list