Sample for GtkHTML.
svn path=/trunk/gtk-sharp/; revision=26585
This commit is contained in:
parent
7c488bead4
commit
5cd8d37664
1 changed files with 24 additions and 0 deletions
24
sample/gtk-html-sample.cs
Normal file
24
sample/gtk-html-sample.cs
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
using Gtk;
|
||||||
|
using GtkSharp;
|
||||||
|
using System;
|
||||||
|
// mcs -r gtkhtml-sharp -r gtk-sharp gtk-html-sample.cs
|
||||||
|
|
||||||
|
class HTMLSample {
|
||||||
|
static int Main (string [] args)
|
||||||
|
{
|
||||||
|
HTML html;
|
||||||
|
Window win;
|
||||||
|
Application.Init ();
|
||||||
|
html = new HTML ();
|
||||||
|
win = new Window ("Test");
|
||||||
|
win.Add (html);
|
||||||
|
HTMLStream s = html.Begin ("text/html");
|
||||||
|
s.Write ("<html><body>");
|
||||||
|
s.Write ("Hello world!");
|
||||||
|
html.End (s, HTMLStreamStatus.Ok);
|
||||||
|
win.ShowAll ();
|
||||||
|
Application.Run ();
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue