<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/105873/">http://git.reviewboard.kde.org/r/105873/</a>
     </td>
    </tr>
   </table>
   <br />









<div>




<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/105873/diff/2/?file=76072#file76072line76" style="color: black; font-weight: bold; text-decoration: underline;">plugins/vectorshape/VectorShapeFactory.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 2)

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

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">bool VectorShapeFactory::supports(const KoXmlElement & e, KoShapeLoadingContext &context) const</pre></td>

  </tr>
 </tbody>




 
 



 <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">76</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">                <span class="c1">// guessing of svm files returns application/octet-stream so also test on that</span></pre></td>
  </tr>

  <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">77</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">                <span class="c1">// see sundaram.fedorapeople.org%2Fpresentations%2Ffedora-fail-learn.odp</span></pre></td>
  </tr>

  <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">78</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">                <span class="n">mimetype</span> <span class="o">==</span> <span class="n">QLatin1String</span><span class="p">(</span><span class="s">"application/octet-stream"</span><span class="p">)</span> <span class="o">||</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Another possible fix might be to install the magic data for SVM to the mimetype database, so SVM gets detected and a proper (unofficial) mimetype gets returned.

Will investigate.</pre>
</div>
<br />



<p>- Friedrich W. H.</p>


<br />
<p>On August 5th, 2012, 10:14 a.m., Thorsten Zachmann wrote:</p>






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

<div>Review request for Calligra.</div>
<div>By Thorsten Zachmann.</div>


<p style="color: grey;"><i>Updated Aug. 5, 2012, 10:14 a.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;">In the commit 9efb4e33f2729080b1f1f24bb18970499a21f2b9 unfortunately a regression was introduced so that loading of vector shapes generated by OO/LO/MSO and our filters no longer work. Unfortunately this commit is also in the 2.5 release. This can be seen e.g. with the following documents:

sundaram.fedorapeople.org%2Fpresentations%2Ffedora-fail-learn.odp
jeffcoweb.jeffco.k12.co.us%2Fhigh%2Fchatfield%2Fdepartments%2Fbusiness%2Fbanking_finance%2Funit_Plan_Budget.odp
drwho.virtadpt.net%2Ffiles%2FNOVALUG-Tor.odp

but much much more of our test documents are effected. There is also a crash in the last document due to which I noticed the problem and started investigating.

The problem is that our filters and the other apps create mimetypes that se no longer load with the above mentioned commit. 

This patch fixes the filter to use the new mimetypes when converting files and adding other mimetypes that are written be e.g. OO or guessed by the mimetype guesser of some of the files.

Additionally fixed by this patch is to not load the first child element twice as when the first loading failed it makes no sense to try it a second time. 
It also fixes a problem that the formula shape and the chart shape tried to load every embedded document even if it had the wrong mimetype.

I think this should be backported to 2.5 and put into the release as it is quite a big regressions since the RC

</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;">Run cstester and now the vector shapes are back and additionally some additional vector shapes are now loaded correctly.</pre>
  </td>
 </tr>
</table>




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

 <li>filters/libmso/pictures.cpp <span style="color: grey">(26158df)</span></li>

 <li>libs/flake/KoShapeRegistry.cpp <span style="color: grey">(9a3712f)</span></li>

 <li>libs/odf/KoOdfLoadingContext.cpp <span style="color: grey">(8b0d44e)</span></li>

 <li>plugins/chartshape/ChartShapeFactory.cpp <span style="color: grey">(b3a5014)</span></li>

 <li>plugins/formulashape/KoFormulaShapeFactory.cpp <span style="color: grey">(7ce11fd)</span></li>

 <li>plugins/vectorshape/VectorShapeFactory.cpp <span style="color: grey">(f9ce5af)</span></li>

</ul>

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




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








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