[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 0bb6ff8 7/9: Reformat and reuse if-with-initi
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 0bb6ff8 7/9: Reformat and reuse if-with-initializer |
Date: |
Wed, 19 Sep 2018 09:19:34 -0400 (EDT) |
branch: master
commit 0bb6ff85cf5f65bd4d22d16d6a1a3b3bb18efead
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Reformat and reuse if-with-initializer
Shortened an overlong line, using essentially the same format as
for-statements elsewhere in lmi. Applied the same technique in a
nearly identical instance.
---
ledger_pdf_generator_wx.cpp | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/ledger_pdf_generator_wx.cpp b/ledger_pdf_generator_wx.cpp
index 8f1c9e4..510fc2c 100644
--- a/ledger_pdf_generator_wx.cpp
+++ b/ledger_pdf_generator_wx.cpp
@@ -1048,8 +1048,10 @@ class page_with_marginals : public logical_page
,oe_only_measure
);
- auto const& upper_template = get_upper_footer_template_name();
- if(!upper_template.empty())
+ if
+ (auto const& upper_template = get_upper_footer_template_name()
+ ;!upper_template.empty()
+ )
{
footer_height += writer.output_html
(frame_horz_margin
@@ -1093,7 +1095,10 @@ class page_with_marginals : public logical_page
// present lower part.
auto y = footer_top_;
- if(auto const& upper_template = get_upper_footer_template_name();
!upper_template.empty())
+ if
+ (auto const& upper_template = get_upper_footer_template_name()
+ ;!upper_template.empty()
+ )
{
y += pdf_dc.GetCharHeight();
- [lmi-commits] [lmi] master updated (ec872ae -> 05129d0), Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 3149080 4/9: Reformat some very long lines, Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 1c240f6 1/9: Add missing piece of PDF context to class pdf_illustration, Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 8cccd20 5/9: Note a mystery, Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 00e5909 3/9: Explicitly use base-class accessor, Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 71ad6f2 8/9: Deal more explicitly with pointers, Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 05129d0 9/9: Adjust whitespace for vertical alignment, Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 0bb6ff8 7/9: Reformat and reuse if-with-initializer,
Greg Chicares <=
- [lmi-commits] [lmi] master e5194ea 6/9: Adjust whitespace for vertical alignment, Greg Chicares, 2018/09/19
- [lmi-commits] [lmi] master 5f53cca 2/9: Appropriately treat font sizes as static data, Greg Chicares, 2018/09/19