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

List:       kwrite-devel
Subject:    Re: Review Request 111551: Add the option to retain empty line indentation in "Normal" indentation m
From:       "Joseph Wenninger" <kde () jowenn ! at>
Date:       2014-09-21 12:08:45
Message-ID: 20140921120845.6971.83097 () probe ! kde ! org
[Download RAW message or body]

--===============3795198295788938412==
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 7bit


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/111551/#review67128
-----------------------------------------------------------


I think the original intent of the code was to skip all lines, that consist only of \
whitespaces (or nothing at all). That's something you would want e.g. for python \
coding. The code is broken tough, since whitepsaces are also contained in the line \
lenghth. Therefor a line containing whitespaces is treated the same way as a line \
containing some other text. I don't think an additional flag is needed, but a clear \
seperation between whitepsace and not whitespace characters.

- Joseph Wenninger


On Juli 17, 2013, 4:58 nachm., Luke San Antonio wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/111551/
> -----------------------------------------------------------
> 
> (Updated Juli 17, 2013, 4:58 nachm.)
> 
> 
> Review request for Kate.
> 
> 
> Bugs: 314395
> http://bugs.kde.org/show_bug.cgi?id=314395
> 
> 
> Repository: kate
> 
> 
> Description
> -------
> 
> Bug 314395 describes how, in "Normal" indentation mode, the editor basically \
> ignores blank lines assuming that no indentation is not worth using. This patch \
> does not change the default behavior, but instead adds an option and a modeline to \
> force the editor, when on "Normal" indentation mode, to forgo this assumption. When \
> enabled, no indentation is still indentation... Check out the bug report for more \
> details if you want! 
> Looking at it now, it seems like a stupid feature. However, most editors and IDEs \
> don't have this feature, so as intelligent and time-saving as it might be, it's \
> very possible it will annoy programmers who aren't used to it. In fact, it already \
> caused a bug report! So I thought, why not, there's no harm in adding the option! 
> Anyway, the patch updates the documentation too! So...
> - Luke
> 
> 
> Diffs
> -----
> 
> part/dialogs/indentationconfigwidget.ui 6d1fc087718729a7c9d3f653002e1dcfa9471132 
> doc/kate/configuring-part.docbook 26fde08c51085955f2eeaa58ce1348454c2aab4f 
> part/dialogs/katedialogs.cpp ac13153d15a9dad72784a97329f84d67033ecd7f 
> part/document/katedocument.cpp 040fdfc96bb854e1658ea069f726a01888667278 
> part/utils/kateautoindent.cpp d9ccd644e743806d350345d8d406ff44a4300d45 
> part/utils/kateconfig.h 2d3c291c52154083eb1c8297346e108dd055ca10 
> part/utils/kateconfig.cpp 3a22c4c93e1e2ca565498feb61ab383f14c27e33 
> part/variableeditor/variablelineedit.cpp 6198903885eab7c15516c53da21fd354dc405fca 
> 
> Diff: https://git.reviewboard.kde.org/r/111551/diff/
> 
> 
> Testing
> -------
> 
> I've been using this patch on top of kate's master branch with no problems.
> 
> 
> Thanks,
> 
> Luke San Antonio
> 
> 


--===============3795198295788938412==
MIME-Version: 1.0
Content-Type: text/html; charset="utf-8"
Content-Transfer-Encoding: 7bit




<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="12" style="border: 1px #c9c399 \
solid; border-radius: 6px; -moz-border-radius: 6px; -webkit-border-radius: 6px;">  \
<tr>  <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="https://git.reviewboard.kde.org/r/111551/">https://git.reviewboard.kde.org/r/111551/</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;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">I \
think the original intent of the code was to skip all lines, that consist only of \
whitespaces (or nothing at all). That's something you would want e.g. for python \
coding. The code is broken tough, since whitepsaces are also contained in the line \
lenghth. Therefor a line containing whitespaces is treated the same way as a line \
containing some other text. I don't think an additional flag is needed, but a clear \
seperation between whitepsace and not whitespace characters.</p></pre>  <br />









<p>- Joseph Wenninger</p>


<br />
<p>On Juli 17th, 2013, 4:58 nachm. UTC, Luke San Antonio wrote:</p>









<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="12" style="border: \
1px #888a85 solid; border-radius: 6px; -moz-border-radius: 6px; \
-webkit-border-radius: 6px;">  <tr>
  <td>

<div>Review request for Kate.</div>
<div>By Luke San Antonio.</div>


<p style="color: grey;"><i>Updated Juli 17, 2013, 4:58 nachm.</i></p>







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


 <a href="http://bugs.kde.org/show_bug.cgi?id=314395">314395</a>


</div>



<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt;">Repository: </b>
kate
</div>


<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;">Bug 314395 describes how, in &quot;Normal&quot; indentation mode, the \
editor basically ignores blank lines assuming that no indentation is not worth using. \
This patch does not change the default behavior, but instead adds an option and a \
modeline to force the editor, when on &quot;Normal&quot; indentation mode, to forgo \
this assumption. When enabled, no indentation is still indentation... Check out the \
bug report for more details if you want!

Looking at it now, it seems like a stupid feature. However, most editors and IDEs \
don&#39;t have this feature, so as intelligent and time-saving as it might be, \
it&#39;s very possible it will annoy programmers who aren&#39;t used to it. In fact, \
it already caused a bug report! So I thought, why not, there&#39;s no harm in adding \
the option!

Anyway, the patch updates the documentation too! So...
- Luke</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;">I&#39;ve been using this patch on top of kate&#39;s master branch with \
no problems.</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>part/dialogs/indentationconfigwidget.ui <span style="color: \
grey">(6d1fc087718729a7c9d3f653002e1dcfa9471132)</span></li>

 <li>doc/kate/configuring-part.docbook <span style="color: \
grey">(26fde08c51085955f2eeaa58ce1348454c2aab4f)</span></li>

 <li>part/dialogs/katedialogs.cpp <span style="color: \
grey">(ac13153d15a9dad72784a97329f84d67033ecd7f)</span></li>

 <li>part/document/katedocument.cpp <span style="color: \
grey">(040fdfc96bb854e1658ea069f726a01888667278)</span></li>

 <li>part/utils/kateautoindent.cpp <span style="color: \
grey">(d9ccd644e743806d350345d8d406ff44a4300d45)</span></li>

 <li>part/utils/kateconfig.h <span style="color: \
grey">(2d3c291c52154083eb1c8297346e108dd055ca10)</span></li>

 <li>part/utils/kateconfig.cpp <span style="color: \
grey">(3a22c4c93e1e2ca565498feb61ab383f14c27e33)</span></li>

 <li>part/variableeditor/variablelineedit.cpp <span style="color: \
grey">(6198903885eab7c15516c53da21fd354dc405fca)</span></li>

</ul>

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






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








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


--===============3795198295788938412==--



_______________________________________________
KWrite-Devel mailing list
KWrite-Devel@kde.org
https://mail.kde.org/mailman/listinfo/kwrite-devel


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

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