<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/103677/">http://git.reviewboard.kde.org/r/103677/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<p style="margin-top: 0;">On January 12th, 2012, 8:01 a.m., <b>Thorsten Zachmann</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/103677/diff/1/?file=46456#file46456line2130" style="color: black; font-weight: bold; text-decoration: underline;">libs/kotext/styles/KoCharacterStyle.cpp</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; ">void KoCharacterStyle::saveOdf(KoGenStyle &style) 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">2130</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> <span class="k">if</span> <span class="p">(</span><span class="n">variant</span><span class="p">.</span><span class="n">isNull</span><span class="p">()</span> <span class="o">&&</span> <span class="n">d</span><span class="o">-></span><span class="n">hardCodedDefaultStyle</span><span class="p">.</span><span class="n">contains</span><span class="p">(</span><span class="n">key</span><span class="p">))</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">2131</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> <span class="n">variant</span> <span class="o">=</span> <span class="n">d</span><span class="o">-></span><span class="n">hardCodedDefaultStyle</span><span class="p">.</span><span class="n">value</span><span class="p">(</span><span class="n">key</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;">This change seems to be wrong as it will return stuff that should not be returned here.</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;">Well, these hard coded default are applied when the style is applied. And since this function does not return only what is defined in that particular style but also moves up the parenting chain, i think these properties should also be returned. If not, there is a discrepancy between what the styles apply on a format and what the style returns as a value:
If I have:
QTextCharFormat format;
style->applyStyle(format);
Then format.property(some hard coded property) returns a value, but style.value(that same property) is undefined. I don't find this discrepancy logical.</pre>
<br />
<p>- Pierre</p>
<br />
<p>On January 11th, 2012, 11:11 p.m., Pierre Stirnweiss 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 Pierre Stirnweiss.</div>
<p style="color: grey;"><i>Updated Jan. 11, 2012, 11:11 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;">Merge request.
Merge branch textshape_stylesWidget_pierreSt into master.
The branch provides a replacement for the style selection widgets. The new provided widgets are a subclass of QComboBox.
They provide a style preview both in the main area and in the dropdown menu.
The dropdown menu provides a "show style manager" button, which call the whole style management dialog.
The dropdown also provides a "delete style" button, although this is for the moment disabled/commented out, because deleting a style is not currently really supported.
The combo also allows to create a style based on the current text format if it does not correspond to the original style (ie. the user changed a property).</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;">The functionality exclusively linked to the comboBox seems to be working properly. Some defects have been identified (like no paragraph style is selected at startup), but these are actually outside the scope of this widget and affecting the current widget also.</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>libs/kotext/KoTextEditor.h <span style="color: grey">(94bf433)</span></li>
<li>libs/kotext/KoTextEditor.cpp <span style="color: grey">(9f242e6)</span></li>
<li>libs/kotext/styles/KoCharacterStyle.cpp <span style="color: grey">(f9e0741)</span></li>
<li>libs/kotext/styles/KoParagraphStyle.h <span style="color: grey">(12ab672)</span></li>
<li>libs/textlayout/CMakeLists.txt <span style="color: grey">(af6d64a)</span></li>
<li>libs/textlayout/FrameIterator.h <span style="color: grey">(c73d580)</span></li>
<li>libs/textlayout/KoStyleThumbnailer.h <span style="color: grey">(8645089)</span></li>
<li>libs/textlayout/KoStyleThumbnailer.cpp <span style="color: grey">(3529bbb)</span></li>
<li>plugins/textshape/CMakeLists.txt <span style="color: grey">(fad7c04)</span></li>
<li>plugins/textshape/TextTool.h <span style="color: grey">(f8de126)</span></li>
<li>plugins/textshape/TextTool.cpp <span style="color: grey">(f6822bd)</span></li>
<li>plugins/textshape/dialogs/SimpleCharacterWidget.h <span style="color: grey">(ad944a5)</span></li>
<li>plugins/textshape/dialogs/SimpleCharacterWidget.cpp <span style="color: grey">(6b2bb66)</span></li>
<li>plugins/textshape/dialogs/SimpleCharacterWidget.ui <span style="color: grey">(e4f6d3b)</span></li>
<li>plugins/textshape/dialogs/SimpleParagraphWidget.h <span style="color: grey">(bc167b4)</span></li>
<li>plugins/textshape/dialogs/SimpleParagraphWidget.cpp <span style="color: grey">(cbfacfe)</span></li>
<li>plugins/textshape/dialogs/SimpleParagraphWidget.ui <span style="color: grey">(b2e9adf)</span></li>
<li>plugins/textshape/dialogs/StylesCombo.h <span style="color: grey">(PRE-CREATION)</span></li>
<li>plugins/textshape/dialogs/StylesCombo.cpp <span style="color: grey">(PRE-CREATION)</span></li>
<li>plugins/textshape/dialogs/StylesComboPreview.h <span style="color: grey">(PRE-CREATION)</span></li>
<li>plugins/textshape/dialogs/StylesComboPreview.cpp <span style="color: grey">(PRE-CREATION)</span></li>
<li>plugins/textshape/dialogs/StylesDelegate.h <span style="color: grey">(f5d216f)</span></li>
<li>plugins/textshape/dialogs/StylesDelegate.cpp <span style="color: grey">(d1021f5)</span></li>
<li>plugins/textshape/dialogs/StylesModel.h <span style="color: grey">(dbd17b4)</span></li>
<li>plugins/textshape/dialogs/StylesModel.cpp <span style="color: grey">(94deb24)</span></li>
<li>plugins/textshape/dialogs/StylesWidget.cpp <span style="color: grey">(4f31a01)</span></li>
<li>plugins/textshape/dialogs/TableOfContentsStyleModel.cpp <span style="color: grey">(48ee7c3)</span></li>
</ul>
<p><a href="http://git.reviewboard.kde.org/r/103677/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>