[prev in list] [next in list] [prev in thread] [next in thread] 

List:       koffice-devel
Subject:    Re: Review Request: Optimize KoXmlNS
From:       "Marijn Kruisselbrink" <m.kruisselbrink () student ! tue ! nl>
Date:       2010-10-27 6:15:28
Message-ID: 20101027061528.21576.95269 () vidsolbach ! de
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://svn.reviewboard.kde.org/r/5698/#review8378
-----------------------------------------------------------



trunk/koffice/libs/odf/KoXmlNS.h
<http://svn.reviewboard.kde.org/r/5698/#comment8696>

    Afaik having global static non-pod type objects is not such a good idea=
 (and can even cause crashes), because destruction order is not defined, an=
d destructors might rely on other global statics still being around. I thin=
k I even got some valgrind errors for some of the other global QString's we=
 have, although I can't really explain that from a quick look at the QStrin=
g source code.


- Marijn


On 2010-10-27 06:06:49, Thorsten Zachmann wrote:
> =

> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://svn.reviewboard.kde.org/r/5698/
> -----------------------------------------------------------
> =

> (Updated 2010-10-27 06:06:49)
> =

> =

> Review request for KOffice.
> =

> =

> Summary
> -------
> =

> Optimize loading speed by using QString in KoXmlNS instead of char *.
> =

> This reduces the number of conversions form char *  to QString during loa=
ding quite a lot.
> =

> =

> Diffs
> -----
> =

>   trunk/koffice/filters/kpresenter/kpr2odf/Filterkpr2odf.cpp 1188346 =

>   trunk/koffice/kspread/Cell.cpp 1188346 =

>   trunk/koffice/kspread/Sheet.cpp 1188346 =

>   trunk/koffice/libs/flake/KoFrameShape.h 1188346 =

>   trunk/koffice/libs/flake/KoFrameShape.cpp 1188346 =

>   trunk/koffice/libs/flake/KoShape.h 1188346 =

>   trunk/koffice/libs/flake/KoShape.cpp 1188346 =

>   trunk/koffice/libs/flake/KoShapeLoadingContext.h 1188346 =

>   trunk/koffice/libs/flake/KoShape_p.h 1188346 =

>   trunk/koffice/libs/odf/KoOasisSettings.h 1188346 =

>   trunk/koffice/libs/odf/KoOdfGraphicStyles.cpp 1188346 =

>   trunk/koffice/libs/odf/KoOdfLoadingContext.h 1188346 =

>   trunk/koffice/libs/odf/KoOdfLoadingContext.cpp 1188346 =

>   trunk/koffice/libs/odf/KoXmlNS.h 1188346 =

>   trunk/koffice/libs/odf/KoXmlNS.cpp 1188346 =

> =

> Diff: http://svn.reviewboard.kde.org/r/5698/diff
> =

> =

> Testing
> -------
> =

> All tests work as before. Also tested with loading of different documents=
 and all works as expected.
> =

> =

> Thanks,
> =

> Thorsten
> =

>


[Attachment #5 (text/html)]

<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://svn.reviewboard.kde.org/r/5698/">http://svn.reviewboard.kde.org/r/5698/</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://svn.reviewboard.kde.org/r/5698/diff/1/?file=40306#file40306line32" \
style="color: black; font-weight: bold; text-decoration: \
underline;">trunk/koffice/libs/odf/KoXmlNS.h</a>  <span style="font-weight: normal;">

     (Diff revision 1)

    </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; \
"></pre></td>

  </tr>
 </tbody>



 
 




 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">30</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">office</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">32</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">office</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">31</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">meta</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">33</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">meta</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">32</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">config</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">34</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">config</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">33</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">text</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">35</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">text</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">34</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">table</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">36</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">table</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">35</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">draw</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">37</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">draw</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">36</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">presentation</span><span class="p">;</span></pre></td>  <th \
bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">38</font></th>  <td bgcolor="#fdfebc" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">presentation</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">37</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">dr3d</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">39</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">dr3d</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">38</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">chart</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">40</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">chart</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">39</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">form</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">41</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">form</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">40</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">script</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">42</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">script</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">41</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">style</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">43</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">style</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">42</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">number</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">44</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">number</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">43</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">manifest</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">45</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">manifest</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">44</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">anim</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">46</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">anim</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">45</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  <th \
bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">47</font></th>  <td bgcolor="#fdfebc" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  \
</tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">46</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">math</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">48</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">math</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">47</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">svg</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">49</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">svg</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">48</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">fo</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">50</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">fo</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">49</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">dc</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">51</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">dc</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">50</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">xlink</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">52</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">xlink</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">51</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">VL</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">53</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">VL</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">52</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">smil</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">54</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">smil</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">53</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">xhtml</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">55</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">xhtml</span><span \
class="p">;</span></pre></td>  </tr>

 </tbody>





 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">54</font></th>  <td bgcolor="#ffffff" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  <th \
bgcolor="#f0f0f0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">56</font></th>  <td bgcolor="#ffffff" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  \
</tr>

 </tbody>


 
 




 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">55</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">koffice</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">57</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">koffice</span><span \
class="p">;</span></pre></td>  </tr>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">56</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="kt"><span \
class="hl">char</span></span><span class="o"><span class="hl">*</span></span><span \
class="hl"> </span><span class="k"><span class="hl">const</span></span> <span \
class="n">officeooo</span><span class="p">;</span></pre></td>  <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">58</font></th>  <td bgcolor="#fdfebc" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="k">static</span> <span class="k">const</span> <span class="n"><span \
class="hl">QString</span></span> <span class="n">officeooo</span><span \
class="p">;</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;">Afaik \
having global static non-pod type objects is not such a good idea (and can even cause \
crashes), because destruction order is not defined, and destructors might rely on \
other global statics still being around. I think I even got some valgrind errors for \
some of the other global QString&#39;s we have, although I can&#39;t really explain \
that from a quick look at the QString source code.</pre> </div>
<br />



<p>- Marijn</p>


<br />
<p>On October 27th, 2010, 6:06 a.m., Thorsten Zachmann wrote:</p>






<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('http://svn.reviewboard.kde.orgrb/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 KOffice.</div>
<div>By Thorsten Zachmann.</div>


<p style="color: grey;"><i>Updated 2010-10-27 06:06:49</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;">Optimize loading speed by using QString in KoXmlNS instead of char *.

This reduces the number of conversions form char *  to QString during loading quite a \
lot.</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;">All tests work as before. Also tested with loading of different \
documents and all works as expected.</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>trunk/koffice/filters/kpresenter/kpr2odf/Filterkpr2odf.cpp <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/kspread/Cell.cpp <span style="color: grey">(1188346)</span></li>

 <li>trunk/koffice/kspread/Sheet.cpp <span style="color: grey">(1188346)</span></li>

 <li>trunk/koffice/libs/flake/KoFrameShape.h <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/flake/KoFrameShape.cpp <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/flake/KoShape.h <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/flake/KoShape.cpp <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/flake/KoShapeLoadingContext.h <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/flake/KoShape_p.h <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/odf/KoOasisSettings.h <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/odf/KoOdfGraphicStyles.cpp <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/odf/KoOdfLoadingContext.h <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/odf/KoOdfLoadingContext.cpp <span style="color: \
grey">(1188346)</span></li>

 <li>trunk/koffice/libs/odf/KoXmlNS.h <span style="color: grey">(1188346)</span></li>

 <li>trunk/koffice/libs/odf/KoXmlNS.cpp <span style="color: \
grey">(1188346)</span></li>

</ul>

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




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








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



_______________________________________________
koffice-devel mailing list
koffice-devel@kde.org
https://mail.kde.org/mailman/listinfo/koffice-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic