[MonoDevelop] C# smart indent enabled in svn
john.luke at gmail.com
Fri Oct 28 16:39:15 EDT 2005
I enabled the old smart indentation code for C# in svn.
It should not effect the other languages as they will retain the
default behavior of gtksourceview when smart indentation is enabled,
which is to indent the next line the same as the previous one. Also, it
does not include handling the closing braces nicely.
To try it, go to Edit-Preferences-Editor-Behavior and choose smart
indent, switch to auto-indent if it breaks and file a bug. When enough
people are happy with it, it can be enabled by default.
For language binding authors, it should be fairly self-explanatory
based on the way C# is doing it. Just add a formatter to the addin path
for your language. By default it will look in /EXT based on the
extension of the languages files.
<Extension path = "/AddIns/DefaultTextEditor/Formatter/C#">
<Class id ="CSharpFormattingStrategy" class =
Keep in mind this is an older way of doing formatting, we may want to do
it a different way, or look into updating it based on SD 2.0, and it may
need to be modified to accommodate other languages properly.
More information about the Monodevelop-list