<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
    <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/109803/">http://git.reviewboard.kde.org/r/109803/</a>
     </td>
    </tr>
   </table>
   <br />










<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 24th, 2013, 10 p.m. CEST, <b>Thomas Baumgart</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/109803/diff/4/?file=140782#file140782line45" style="color: black; font-weight: bold; text-decoration: underline;">kmymoney/plugins/csvexport/csvexporterplugin.h</a>
    <span style="font-weight: normal;">

     (Diff revision 4)

    </span>
   </th>
  </tr>
 </thead>



 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">45</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">  <span class="n">CsvExportDlg</span><span class="o">*</span>     <span class="n">m_dlg</span><span class="p">;</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Public member vars</pre>
 </blockquote>



 <p>On April 25th, 2013, 1:54 a.m. CEST, <b>Allan Anderson</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Not sure how to go about this as it is accessed from outside its class.  Contemplated using protected and friend, which I see are used elsewhere, but reading about, it's not always deemed to be good practice.  Or, use a getter here too?</pre>
 </blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Yes, that's what they are there for.</pre>
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 24th, 2013, 10 p.m. CEST, <b>Thomas Baumgart</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/109803/diff/4/?file=140785#file140785line101" style="color: black; font-weight: bold; text-decoration: underline;">kmymoney/plugins/csvexport/csvwriter.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 4)

    </span>
   </th>
  </tr>
 </thead>



 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">101</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span class="n">data</span> <span class="o">+=</span> <span class="n">type</span> <span class="o">%</span> <span class="s">"</span><span class="se">\n</span><span class="s">"</span> <span class="o">%</span> <span class="s">"</span><span class="se">\n</span><span class="s">"</span><span class="p">;</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">why not using "\n\n" instead? Your way needs one more byte of mem plus cpu time during each call.</pre>
 </blockquote>



 <p>On April 25th, 2013, 1:54 a.m. CEST, <b>Allan Anderson</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Why not, indeed?  Just harking back to your comment about using QLatin1String/Char, was that just instead of Qstring("blahblah"), or also for 
"blah" + "blah1"?  The article left me in doubt.</pre>
 </blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Concatenation using either + or % uses runtime. Having a fixed string does not. I agree, it is just a small portion of cpu time but things like that add up and one should always have an eye on them.</pre>
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On April 24th, 2013, 10 p.m. CEST, <b>Thomas Baumgart</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/109803/diff/4/?file=140785#file140785line190" style="color: black; font-weight: bold; text-decoration: underline;">kmymoney/plugins/csvexport/csvwriter.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 4)

    </span>
   </th>
  </tr>
 </thead>



 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">190</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">  <span class="n">str</span> <span class="o">+=</span> <span class="n">QLatin1Char</span><span class="p">(</span><span class="sc">'"'</span><span class="p">)</span> <span class="o">%</span> <span class="n">payee</span><span class="p">.</span><span class="n">name</span><span class="p">()</span> <span class="o">%</span> <span class="n">QLatin1String</span><span class="p">(</span><span class="s">"</span><span class="se">\"</span><span class="s">,"</span><span class="p">);</span></pre></td>
  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Here's another way to do this:

  str += QString("\"%1\",").arg(payee.name());

Don't know which one is better.</pre>
 </blockquote>



 <p>On April 25th, 2013, 1:54 a.m. CEST, <b>Allan Anderson</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I'll sleep on that.</pre>
 </blockquote>





 <p>On April 25th, 2013, 9:40 p.m. CEST, <b>Marko Käning</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Thomas' suggestion of using arguments in strings is used in many places in KMM.</pre>
 </blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Is it because Thomas (me in this case) wrote so much of that code? SCNR.</pre>
<br />




<p>- Thomas</p>


<br />
<p>On April 24th, 2013, 6:16 p.m. CEST, Allan Anderson wrote:</p>








<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('http://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
 <tr>
  <td>

<div>Review request for KMymoney.</div>
<div>By Allan Anderson.</div>


<p style="color: grey;"><i>Updated April 24, 2013, 6:16 p.m.</i></p>






<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Add CSV export capability.  Modify existing KMyMoney File menu in order to make menu item positions more logical.
</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Exported numerous checking and investment CSV files, and then imported into KMyMoney via CSV import (discovering a few minor issues in the existing KMyMoney accounts in the process.)
Ran astyle and Krazy2.</pre>
  </td>
 </tr>
</table>



<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>


 <a href="http://bugs.kde.org/show_bug.cgi?id=317614">317614</a>


</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>kmymoney/kmymoneyui.rc <span style="color: grey">(f353641)</span></li>

 <li>kmymoney/plugins/CMakeLists.txt <span style="color: grey">(81ca458)</span></li>

 <li>kmymoney/plugins/csvexport/CMakeLists.txt <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/csvexportdlg.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/csvexportdlg.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/csvexportdlg.ui <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/csvexporterplugin.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/csvexporterplugin.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/csvwriter.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/csvwriter.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/kmm_csvexport.desktop <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvexport/kmm_csvexport.rc <span style="color: grey">(PRE-CREATION)</span></li>

 <li>kmymoney/plugins/csvimport/investprocessing.cpp <span style="color: grey">(07d4d82)</span></li>

 <li>kmymoney/plugins/csvimport/kmm_csvimport.rc <span style="color: grey">(d678169)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/109803/diff/" style="margin-left: 3em;">View Diff</a></p>







  </td>
 </tr>
</table>








  </div>
 </body>
</html>