tag:blogger.com,1999:blog-203063759820106893.post8316310092834453243..comments2023-03-25T08:30:26.602-04:00Comments on A Moment of Zen: MonoDevelop Smart IndentJeffrey Stedfasthttp://www.blogger.com/profile/12271561115384429651noreply@blogger.comBlogger6125tag:blogger.com,1999:blog-203063759820106893.post-37563698327399313192007-03-07T09:38:00.000-05:002007-03-07T09:38:00.000-05:00Daniel: absolutely. I'll be sending Paolo some cod...Daniel: absolutely. I'll be sending Paolo some code written in C to do it (I've already sent him a few revisions, but they are buggy) once I work out the last remaining known bugs in the logic. The code should be easily modified to fit c, c++ or java without too much work (mostly it'll be getting rid of support for verbatim string literals since only c# has those and maybe a few minor tweaks here or there).Jeffrey Stedfasthttps://www.blogger.com/profile/12271561115384429651noreply@blogger.comtag:blogger.com,1999:blog-203063759820106893.post-51195939292027403492007-03-07T09:34:00.000-05:002007-03-07T09:34:00.000-05:00Rick, yea, you can implement a TextEditorExtension...Rick, yea, you can implement a TextEditorExtension to hook into the KeyPress event.<BR/><BR/>Be aware that you will want to pass the event up the chain, though, in order for Undo/Redo support to work properly.Jeffrey Stedfasthttps://www.blogger.com/profile/12271561115384429651noreply@blogger.comtag:blogger.com,1999:blog-203063759820106893.post-30789387910298474022007-03-07T04:01:00.000-05:002007-03-07T04:01:00.000-05:00Great, but now we should implement this in GtkSour...Great, but now we should implement this in GtkSourceView. :-)Daniel Borgmannhttps://www.blogger.com/profile/02199609537547850153noreply@blogger.comtag:blogger.com,1999:blog-203063759820106893.post-26761284276004975872007-03-07T03:34:00.000-05:002007-03-07T03:34:00.000-05:00A long time ago I wanted to do a small vi emulatio...A long time ago I wanted to do a small vi emulation plugin for Monodevelop, but there was no independent plugin way to hook into the keypress event.<BR/><BR/>Do plugins now have access to the keypress event?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-203063759820106893.post-54656976003128855372007-03-06T23:07:00.000-05:002007-03-06T23:07:00.000-05:00Haha, yea, first thing I noticed when I got assign...Haha, yea, first thing I noticed when I got assigned to MonoDevelop was "wow, this Auto-Indent needs work" - at the time I didn't realize there was a "Smart Indent" option.<BR/><BR/>Miguel and I got to talking about what sort of improvements the editor needed, and he agreed this was one of them.<BR/><BR/>Later, I discovered there was a Smart Indent feature, so I enabled it and at first I thought, "Wow, ok, this is already done... scratch that off my list." But then I started writing more code and pretty quickly discovered it was really bad, tried to fix some of the logic in the code, but I quickly decided it needed a rewrite.<BR/><BR/>I'm sure there are at least a few issues with my new code (someone just mentioned it wasn't handling his code quite right on IRC) and I know of at least 1 bug myself (it doesn't handle "default :" - e.g. if there are spaces between "default" and the ":", but that should be a trivial fix tomorrow).Jeffrey Stedfasthttps://www.blogger.com/profile/12271561115384429651noreply@blogger.comtag:blogger.com,1999:blog-203063759820106893.post-35446133423710297772007-03-06T22:08:00.000-05:002007-03-06T22:08:00.000-05:00Dude! Thank you! This has been one of my pet pee...Dude! Thank you! This has been one of my pet peeves with MD for a *long* time now.<BR/><BR/>You and Lluis keep giving me new reasons to switch from JEdit + terminal. ;-)Sandyhttps://www.blogger.com/profile/15559715601984648600noreply@blogger.com