Summary: | emacslike: fill paragraph to auto-format a paragraph | ||
---|---|---|---|
Product: | [Applications] kate | Reporter: | ronny_klein |
Component: | scripting | Assignee: | KWrite Developers <kwrite-bugs-null> |
Status: | RESOLVED INTENTIONAL | ||
Severity: | wishlist | CC: | christoph, jquelin, nicolas.girard |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | RedHat Enterprise Linux | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
ronny_klein
2004-03-31 16:54:47 UTC
What you describe here is not a key binding, it is a feature. A nice one, though. What you suggests seems to be a comnination of rewrapping the lines, and normalizing whitespace, we don't have the latter yet, and we don't suport wrapping "a paragraph" or the selection yet either. Who the f*** cares about evolution? :o I would be happy just to have a "fill paragraph" function without the whitespace normalization (although that would be nice as well). From what I can tell in Bugs 48529 and 58401, the closest current practice is to select a run of text, and then execute "Apply Word Wrap." When the desired run of text is one blank-line-delimited paragraph---trivially recognizable by the editor---this procedure is quite cumbersome (*). Ideally, there would be a [single] keystroke that reformats whatever paragraph the cursor is in. (*) - Cumbersome as it is described, but I can't get even that much relief. I don't see an "Apply Word Wrap" menu item anywhere, only "Word Wrap Document" under the Tools menu---and so far as I've fiddled around with it, it doesn't seem to have the same behavior. At the very least, the "select a run of text to limit the scope of re-wrapping" feature doesn't work for me. I'm a longtime user of NEdit and pico/nano, and "fill/justify paragraph" has always been Ctrl-J for me. It's a _very_ common operation in my course of authoring LaTeX text---basically, every time that I edit an existing paragraph, the last thing done to it is a fill. It's a little disorienting for me not to be able to do this in Kate, especially when other text editors provide the functionality as a matter of course, and when Kate as a whole is already so far beyond most other text editors :-) also available in vim with gqip key bindings. definitely a nice-to-have feature. see also bug #93398 which is the same. On Wednesday 03 May 2006 19:40, Jerome Quelin wrote:
> also available in vim with gqip key bindings.
> definitely a nice-to-have feature.
So, use that. and, bugging us about what other editors do is
counterproductive!!!!!!!!!!!!!!!!!
This remains a shortcoming in Kate, however. Because of this, Kate is not [yet] suitable for general editing of statically-wrapped text. (If LaTeX isn't a compelling enough instance of this, try e-mail messages.) Right now, if you have a paragraph with some too-short and too-long lines, you have to (1) invoke "Join Lines" enough times to get the entire paragraph on one line, and then (2) "Word Wrap Document." You're screwed if you want to preserve initial whitespace on each line (e.g. for indented paragraphs, or any kind of itemized list), or if you don't want long lines elsewhere in the document to be wrapped as well. I don't understand why such a common "fill paragraph" function is not available in Kate. Personally, I suspect that the authors want to subtly discourage the use of statically-wrapped text in general, in favor of dynamic wrapping (with one newline per paragraph). regarding comment 4: you speak about counter-productive? in my post, i: - spotted a duplicated bug, - help describing the rfe with an analogy to vim, - tell that this would be a nice feature (yes, i also voted for this bug). this is a rfe. read: "request for enhancement". i'm not saying: "kate is bullshit, it can't do X". no, i'm saying: "there is a nice feature out there, check it here, what do you think about adding it to kate". sorry if that bothers you. enough feeding the troll, i won't explain myself any further. period. This is a perfect candidate for a jscript. - go up until empty line - join lines repeatedly until next empty line This can now be very easily implemented by using our scripting api, and you can even bind shortcuts to it: http://docs.kde.org/stable/en/kdesdk/kate/advanced-editing-tools-scripting.html It would be nice, if anyone of you volunteer to implement it! *** Bug 93398 has been marked as a duplicate of this bug. *** Kate is extensible via javascript now, if you want such a feature, please send in some script we can bundle. See http://kate-editor.org/2009/10/29/extending-kate-with-scripts/ for documentation about scripting. |