YES! I LOVE the textindent, thank you so much!!
Upps, after some testing, I discovered somethnig I'd still like to be changed :) When an empty line, let the caret remain in position, or move it "in" just as a tab would have done. Reason; I immediately set up enter to be a macro with newline and indent, so all code would immediately get indented, and then I used ctrl+enter for just newline, in case I'd ever want that. Problem was this behaviour broke rather badly since each line without previous text had the caret far to the left. Before setting up the macros, I'd only tested it on lines already containing text you see..
Andreas
On 05/11/2005, at 10.25, Andreas Wahlin wrote:
Upps, after some testing, I discovered somethnig I'd still like to be changed :) When an empty line, let the caret remain in position, or move it "in" just as a tab would have done.
Yes -- though the reason why I haven't done so yet is, that it's not that simple, since empty lines doesn't get special treatment, but are matched by the unindent line pattern -- but it's likely going to be fixed somehow.
Reason; I immediately set up enter to be a macro with newline and indent
Doesn't a normal return already give you that?
[...] Problem was this behaviour broke rather badly since each line without previous text had the caret far to the left
What you can do is record a macro that does:
1) return 2) ctrl-shift left (select to begin of line) 3) tab (overwrite selection with tabs corresponding to calculated indent)
Part #3 is basically the same as the new re-indent function, except it does keep leading whitespace on empty lines -- although the difference in behavior between this and normal return should be minimal (basically the indent next line pattern is not used with return, due to how that pattern can get cancelled based on what's on next line -- this may improve slightly in the future, but I'd think this case is limited to only a few languages, in particular C/C++).
Doesn't a normal return already give you that?
Actually not; <tag> text|</tag>
hitting enter there will produce
<tag> text </tag>
rather than
<tag> text </tag>
hope you can spot the ASCII spaces :)
What you can do is record a macro that does:
- return
- ctrl-shift left (select to begin of line)
- tab (overwrite selection with tabs corresponding to calculated
indent)
This works as advertised and the behaviour is now as far as I can see perfect! This also puts a closure to our other BIG thread on tabbing and some such, since all this also works in XML-files. This mademy weekend, or something. Thanks again!
Andreas
On 05/11/2005, at 11.19, Andreas Wahlin wrote:
Doesn't a normal return already give you that?
Actually not;
<tag> text|</tag> hitting enter there will produce [...]
Ah, didn't consider this, thanks for the example.
[...] hope you can spot the ASCII spaces :)
Like any other sane person, I read my email with a monospaced font! :)
Like any other sane person, I read my email with a monospaced font! :)
I suppose that makes me insane then :)
*coughs* just discovered another thing. When I close tags it seems they get one backspace applied to them, so to speak, to order them up better. Wouldn't it be better to replace this backspace with an indent line command instead?
Andreas
On 05/11/2005, at 11.45, Andreas Wahlin wrote:
Like any other sane person, I read my email with a monospaced font! :)
I suppose that makes me insane then :)
Yeah, I don't really think the few cases where monospace is needed, justifies switching to it in general :-p.
-- Sune.