0

I would like to build my own html gui editor, but I can't figure out the basic structure for the application.

Does anyone know of any sample code for building an editor? I would like to use Visual Studio 2010.

The part I don't know is how to build a wysiwyg area to display a page that is being designed.

Any help is appretiated

Tony
  • 425
  • 2
  • 4
  • 13
  • 2
    This is a very ambitious project. What have you tried or investigated already? Do you have a specification for how the WYSIWYG editor should work? – Daniel Pryden Dec 03 '10 at 19:14

3 Answers3

0

Most editors are based on the WebBrowser control that comes with Visual Studio. For more info see:

http://www.codeproject.com/KB/miscctrl/csEXWB.aspx

Or if you are more adventurous there are also solutions involving WebKit and Gecko browser engines discussed here:

Is it possible to Embed Gecko or Webkit in a Windows Form just like a WebView?

Community
  • 1
  • 1
madisonw
  • 836
  • 6
  • 7
  • Which in itself is terrible since you end up with code that is targeted at the least standards compliant browser out there. There needs to be a way to easily wrap Webkit into a .net app. – Novikov Dec 03 '10 at 19:21
0

There is also MSHTML : http://msdn.microsoft.com/en-us/library/aa753630(VS.85).aspx

The editor provided with MSHTML offers a "what you see is what you get" (WYSIWYG) HTML editing environment with a rich set of capabilities. It can be activated from C++, Visual Basic, and script. You can use a number of techniques to customize the MSHTML Editor. These techniques are available in C++ only.

Here is a .net wrapper: http://www.itwriting.com/htmleditor/index.php

The HTMLEditor is written in C#. Unlike the .Net webbrowser control, in versions prior to .NET 2.0, this is not an ActiveX control. Rather it is an ActiveX Document. Even if you are not interested in MSHTML, you may be interested in the HTMLEditor as an example of advanced .NET / COM interop. It's also not suitable for embedded web browsing - use the ActiveX for that.

However, it is a pretty cool control. It allows editing as well as read-only display, supports advanced features like print templates and edit designers, gives easy access to the HTML DOM, and lets you load HTML simply by assigning a string to a property.

gideon
  • 19,329
  • 11
  • 72
  • 113
0

SO user leppie made a very nice editor xacc.ide.

Community
  • 1
  • 1
VVS
  • 19,405
  • 5
  • 46
  • 65