[prev in list] [next in list] [prev in thread] [next in thread]
List: kfm-devel
Subject: Re: Review Request 112589: Use the Nepomuk Query Builder widget to add syntax-highlighting in Dolphi
From: "Frank Reininghaus" <frank78ac () googlemail ! com>
Date: 2013-09-08 22:50:57
Message-ID: 20130908225057.15701.19246 () vidsolbach ! de
[Download RAW message or body]
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/112589/#review39614
-----------------------------------------------------------
Thanks for the patch!
I would say that the code looks reasonable (I'm not really familiar with \
the search code though). I've added a few small comments inline.
Hm, my kde-devel user's Dolphin also uses filenamesearch at the moment, \
even if Nepomuk is enabled. It does work fine in the 4.11.1 packages \
provided by OpenSuse though. Strange. I think it's due to some \
misconfiguration or some obsolete files here - I should try to wipe all \
config and build files, then rebuild and see if that helps.
But maybe there are people with working Nepomuk search inside Dolphin who \
can test it sooner than I can.
BTW, is there a Bugzilla component for the new parser? Some users will \
report any issues with it as Dolphin bugs, and I'd like to know where to \
assign these reports to.
dolphin/src/search/dolphinsearchbox.cpp
<http://git.reviewboard.kde.org/r/112589/#comment29189>
This can be removed if you make m_queryParser a QScopedPointer.
dolphin/src/search/dolphinsearchbox.cpp
<http://git.reviewboard.kde.org/r/112589/#comment29187>
Wouldn't it make sense for your QueryBuilder to offer a convenience \
function clear()? Most other widgets where the user can enter text have \
such a function.
dolphin/src/search/dolphinsearchbox.cpp
<http://git.reviewboard.kde.org/r/112589/#comment29190>
const
dolphin/src/search/dolphinsearchbox.cpp
<http://git.reviewboard.kde.org/r/112589/#comment29188>
I'm wondering if this function could get a name that makes it more \
obvious what it is about. Maybe "updateSearchInputParsing" or something \
like that?
In the places where this slot is called directly, \
"slotWhatGroupClicked" looks a bit weird ;-)
- Frank Reininghaus
On Sept. 8, 2013, 11:58 a.m., Denis Steckelmacher wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/112589/
> -----------------------------------------------------------
>
> (Updated Sept. 8, 2013, 11:58 a.m.)
>
>
> Review request for Dolphin.
>
>
> Description
> -------
>
> When Dolphin is compiled with Nepomuk support, this patch replaces the \
> plain line edit in which the user enters a search query with the new \
> auto-completed QueryBuilder widget.
> The user interface of the widget is shown in \
> http://steckdenis.be/static/images/dolphin-query-builder.png .
> The QueryBuilder widget can be found in the "steckdenis-gsoc2013" branch \
> of nepomuk-widgets. You will also need the "steckdenis-gsoc2013" branch \
> of nepomuk-core. This patch is not yet ready for merging as we have to \
> wait that my other branches get merged in nepomuk-core and \
> nepomuk-widgets. Some small changes in the API of the QueryBuilder are \
> still possible.
>
> Diffs
> -----
>
> dolphin/src/search/dolphinsearchbox.h f3cc535
> dolphin/src/search/dolphinsearchbox.cpp ef9c2bf
>
> Diff: http://git.reviewboard.kde.org/r/112589/diff/
>
>
> Testing
> -------
>
> Compiling with the CMake variable WITH_NepomukWidgets set to ON is \
> possible and the resulting Dolphin works as expected (the query builder \
> widget is displayed and queries can be entered in it). When this variable \
> is set to OFF, Dolphin still builds and runs correctly, except that there \
> is no auto-completion available.
> The only problem is that even without the patch (and Nepomuk enabled \
> system-wide and at compile time), Dolphin does not seem to use Nepomuk \
> queries. Every search operation is slow and there is a huge amount of \
> disk activity. Nepomuk queries like "modified last week" work perfectly \
> well in KRunner. This problem (likely due to a misconfiguration on my \
> desktop as it is present in Dolphin master and Dolphin 4.11, with \
> Nepomuk-Core master or 4.11) prevents me from testing that queries \
> entered in the query builder actually work. Can somebody with a working \
> dolphin test that ?
>
> Thanks,
>
> Denis Steckelmacher
>
>
[Attachment #3 (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://git.reviewboard.kde.org/r/112589/">http://git.reviewboard.kde.org/r/112589/</a>
</td>
</tr>
</table>
<br />
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Thanks for the patch!
I would say that the code looks reasonable (I'm not really familiar \
with the search code though). I've added a few small comments inline.
Hm, my kde-devel user's Dolphin also uses filenamesearch at the moment, \
even if Nepomuk is enabled. It does work fine in the 4.11.1 packages \
provided by OpenSuse though. Strange. I think it's due to some \
misconfiguration or some obsolete files here - I should try to wipe all \
config and build files, then rebuild and see if that helps.
But maybe there are people with working Nepomuk search inside Dolphin who \
can test it sooner than I can.
BTW, is there a Bugzilla component for the new parser? Some users will \
report any issues with it as Dolphin bugs, and I'd like to know where \
to assign these reports to.</pre> <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/112589/diff/1/?file=188172#file188172line84" \
style="color: black; font-weight: bold; text-decoration: \
underline;">dolphin/src/search/dolphinsearchbox.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; ">DolphinSearchBox::DolphinSearchBox(QWidget* parent) :</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">83</font></th> <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "> <span \
class="k">delete</span> <span class="n">m_queryParser</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;">This can be removed if you make m_queryParser a \
QScopedPointer.</pre> </div>
<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/112589/diff/1/?file=188172#file188172line202" \
style="color: black; font-weight: bold; text-decoration: \
underline;">dolphin/src/search/dolphinsearchbox.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 DolphinSearchBox::keyReleaseEvent(QKeyEvent* event)</pre></td>
</tr>
</tbody>
<tbody>
<tr>
<th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">197</font></th> <td bgcolor="#fdfebc" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> \
<span class="n">m_searchInput</span><span class="o">-></span><span \
class="n"><span class="hl">clear</span></span><span class="p"><span \
class="hl">()</span>;</span></pre></td> <th bgcolor="#e9eaa8" \
style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" \
align="right"><font size="2">201</font></th> <td bgcolor="#fdfebc" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "> \
<span class="n">m_searchInput</span><span class="o">-></span><span \
class="n"><span class="hl">setText</span></span><span class="p"><span \
class="hl">(</span></span><span class="n"><span \
class="hl">QString</span></span><span class="p"><span \
class="hl">())</span>;</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;">Wouldn't it make sense for your QueryBuilder to offer a \
convenience function clear()? Most other widgets where the user can enter \
text have such a function.</pre> </div>
<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/112589/diff/1/?file=188172#file188172line231" \
style="color: black; font-weight: bold; text-decoration: \
underline;">dolphin/src/search/dolphinsearchbox.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 DolphinSearchBox::slotConfigurationChanged()</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">230</font></th> <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "> <span \
class="n">QString</span> <span class="n">text</span> <span \
class="o">=</span> <span class="n">m_searchInput</span><span \
class="o">-></span><span class="n">text</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;">const</pre> </div>
<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/112589/diff/1/?file=188172#file188172line247" \
style="color: black; font-weight: bold; text-decoration: \
underline;">dolphin/src/search/dolphinsearchbox.cpp</a> <span \
style="font-weight: normal;">
(Diff revision 1)
</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">246</font></th> <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "><span \
class="kt">void</span> <span class="n">DolphinSearchBox</span><span \
class="o">::</span><span class="n">slotWhatGroupClicked</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;">I'm wondering if this function could get a name that makes \
it more obvious what it is about. Maybe \
"updateSearchInputParsing" or something like that?
In the places where this slot is called directly, \
"slotWhatGroupClicked" looks a bit weird ;-)</pre> </div>
<br />
<p>- Frank</p>
<br />
<p>On September 8th, 2013, 11:58 a.m. UTC, Denis Steckelmacher 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 Dolphin.</div>
<div>By Denis Steckelmacher.</div>
<p style="color: grey;"><i>Updated Sept. 8, 2013, 11:58 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;">When Dolphin is compiled with Nepomuk support, this patch \
replaces the plain line edit in which the user enters a search query with \
the new auto-completed QueryBuilder widget.
The user interface of the widget is shown in \
http://steckdenis.be/static/images/dolphin-query-builder.png .
The QueryBuilder widget can be found in the "steckdenis-gsoc2013" \
branch of nepomuk-widgets. You will also need the \
"steckdenis-gsoc2013" branch of nepomuk-core. This patch is not \
yet ready for merging as we have to wait that my other branches get merged \
in nepomuk-core and nepomuk-widgets. Some small changes in the API of the \
QueryBuilder are still possible.</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;">Compiling with the CMake variable WITH_NepomukWidgets set to \
ON is possible and the resulting Dolphin works as expected (the query \
builder widget is displayed and queries can be entered in it). When this \
variable is set to OFF, Dolphin still builds and runs correctly, except \
that there is no auto-completion available.
The only problem is that even without the patch (and Nepomuk enabled \
system-wide and at compile time), Dolphin does not seem to use Nepomuk \
queries. Every search operation is slow and there is a huge amount of disk \
activity. Nepomuk queries like "modified last week" work \
perfectly well in KRunner. This problem (likely due to a misconfiguration \
on my desktop as it is present in Dolphin master and Dolphin 4.11, with \
Nepomuk-Core master or 4.11) prevents me from testing that queries entered \
in the query builder actually work. Can somebody with a working dolphin \
test that ?</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>dolphin/src/search/dolphinsearchbox.h <span style="color: \
grey">(f3cc535)</span></li>
<li>dolphin/src/search/dolphinsearchbox.cpp <span style="color: \
grey">(ef9c2bf)</span></li>
</ul>
<p><a href="http://git.reviewboard.kde.org/r/112589/diff/" \
style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic