lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [lmi] master 0f885a2 116/156: Define CorpNameAbbrev60 and


From: Greg Chicares
Subject: [lmi-commits] [lmi] master 0f885a2 116/156: Define CorpNameAbbrev60 and Insured1Abbrev30 in common code
Date: Tue, 30 Jan 2018 17:22:26 -0500 (EST)

branch: master
commit 0f885a2917a3c412c4134e5c7211a5eebbd4d0b0
Author: Vadim Zeitlin <address@hidden>
Commit: Vadim Zeitlin <address@hidden>

    Define CorpNameAbbrev60 and Insured1Abbrev30 in common code
    
    These variables are not used by the regular illustrations which, for
    some reason, abbreviate both strings to 50 characters instead, but the
    former is used by 2 other illustration kinds and the latter is used by
    all 3 of the remaining ones, so it still seems worth it to define them
    in the common code.
---
 ledger_pdf_generator_wx.cpp | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/ledger_pdf_generator_wx.cpp b/ledger_pdf_generator_wx.cpp
index efae8c8..85006df 100644
--- a/ledger_pdf_generator_wx.cpp
+++ b/ledger_pdf_generator_wx.cpp
@@ -786,6 +786,9 @@ class pdf_illustration : protected html_interpolator
 
         auto const& invar = ledger_.GetLedgerInvariant();
 
+        add_abbreviated_variable("CorpName", 60);
+        add_abbreviated_variable("Insured1", 30);
+
         // Define the variables needed by contract_numbers template.
         add_variable
             ("HasMasterContract"
@@ -1787,7 +1790,8 @@ class pdf_illustration_regular : public pdf_illustration
         auto const& policy_name = invar.PolicyLegalName;
         auto const& state_abbrev = invar.GetStatePostalAbbrev();
 
-        // Define variables specific to this illustration.
+        // Define variables specific to this illustration which doesn't use the
+        // standard 60/30 lengths for whatever reason.
         add_abbreviated_variable("CorpName", 50);
         add_abbreviated_variable("Insured1", 50);
 
@@ -2330,9 +2334,6 @@ class pdf_illustration_nasd : public pdf_illustration
         auto const& invar = ledger.GetLedgerInvariant();
 
         // Define variables specific to this illustration.
-        add_abbreviated_variable("CorpName", 60);
-        add_abbreviated_variable("Insured1", 30);
-
         if(!invar.ContractName.empty())
             {
             std::string s = invar.ContractName;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]