[MonoDevelop] SourceEditor: ideas

Ben Motmans Ben Motmans <ben.motmans@gmail.com>
Wed, 2 Mar 2005 00:03:22 +0100

On Tue, 01 Mar 2005 17:39:07 -0500, John Luke <john.luke@gmail.com> wrote:
> I don't know about others, but I would have preferred a plain-text mail
> with image attachments if necessary for this sort of thing.
> It makes it a lot easier to quote.

yeah, sorry
my plan was to post it on the MD wiki, but there seems to be a problem
with registering a new user

> I am not sure that you understand that the current editor has the
> ability to support most of what you want added.  In fact, there is
> an existing parser for C# that can be used for error underlining,
> refactoring, highlighting etc. Some of these are already implemented
> but not quite ready to be enabled.  I think identifying more of what you
> view as the problem currently would help here.

i am aware of those things, but there are several problems with the
existing code

- it is very difficult (it's actually an ugly hack) to create extra
rulers (for example code folding)
- Although it has the ability to highlight the current line, you
cannot highlight multiple lines (completely, not the bg color of some
text), this would be very usefull for a diff viewer, ...
- end of line handing, \n <> \r\n <> \r
- small issues like, double clicking "doMD5" will only select "doMD"
- customizable right-click menu
- ...

- I'm not saying we should re-invent the wheel, it's just an idea i
was having to integrate the refactoring code more in the text editor
(actually, not in the text editor, but a layer on the textbuffer or
something like that)
- existing SD code doesn't have C# 2.0 support (again, not
re-inventing, just adding :))

> Also, you may not be aware of the previous port of the SharpDevelop
> texteditor which did many of these things in only C# code and the
> related discussion that happened when we moved from that one to the
> current gtksourceview-based one.
> The main issue with the current approach, in my opinion, is limitations
> by having mixed c/C# code to do these things.  So I would recommend
> a first approach is to either port gtksourceview to C# on top of
> Gtk.TextView or revive the old port of the SharpDevelop editor.  At the
> point
> where either of those is done it would make sense to talk about moving
> on from there.

indeed, i'm not aware of previous porting (i'm following MD
development for only 1-2 months, i don't know anything about what
happened before)

probably, i didn't make it clear enough, this is nothing more then
information gathering
making a list of everything that should be in good source editor, and
afterwards decide what could be done

-- Ben