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


<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 KDevelop.</div>
<div>By AndrĂ© Stein.</div>


<p style="color: grey;"><i>Updated Nov. 11, 2012, 3:52 p.m.</i></p>



<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Changes</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;">Here's my take on this.

It's looking a bit better now but at least the placement is still bogus and will require some API changes I think.

Right now, it looks like codeassistant.cpp in the C++ language plugin in kdevelop handles quite a lot, like e.g. when to hide the assistant etc. That logic should be moved to the assistant itself, paired with a notion of a "cursor location". Right now, if you add whitespaces before the declaration-about-to-be-created the popup won't update properly. Same here e.g., with '|' denoting the cursor position:

<pre>
     |                    i = 0;
</pre>

The popup will be shown below the | which is wrong.

So we'll need to adapt the API, do you feel up for that task?</pre>
  </td>
 </tr>
</table>




<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;">I improved (at least IMO) the appearance of the assistant popup while editing code:
- I changed the layout of the popup to be vertically. Sometimes there are many actions in the popup which gives a rather crowded look. Additionally it sometimes doesn't fit on small screens (at least not on my 13" notebook).
- The placement has been changed to be oriented at the current cursor's position. The popup is placed 2 lines _under_ the currently edited line. If a line is edited at the bottom of the editor and the popup wouldn't fit into the window, it is placed _above_ the current line. That way a nasty magic number in the code can be removed too.

All in all I think this gives a better user experience. I had the feeling that some users didn't even see the popup because it was placed at the editor's bottom and so was out of the current "code focus". Additionally the vertical layout matches the behaviour which is seen in other IDEs like Qt Creator or Eclipse.</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;">Manual testing.</pre>
  </td>
 </tr>
</table>




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

 <li>shell/assistantpopup.h <span style="color: grey">(42c55e4)</span></li>

 <li>shell/assistantpopup.cpp <span style="color: grey">(44a4538)</span></li>

 <li>shell/uicontroller.cpp <span style="color: grey">(2c0400f)</span></li>

</ul>

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



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

<div>

 <a href="http://git.reviewboard.kde.org/r/107277/s/817/"><img src="http://git.reviewboard.kde.org/media/uploaded/images/2012/11/10/under_400x100.png" style="border: 1px black solid;" alt="Popup under code" /></a>

 <a href="http://git.reviewboard.kde.org/r/107277/s/818/"><img src="http://git.reviewboard.kde.org/media/uploaded/images/2012/11/10/above_400x100.png" style="border: 1px black solid;" alt="Popup when space is limited (above)" /></a>

</div>


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




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