// code creates class, we create element. public __Button() { InternalDisplayObject = new IHTMLElement(ElementName); var s = InternalDisplayObject.createShadowRoot(); var button = new IHTMLButton(); button.AttachTo(s); button.onclick += delegate { InternalRaiseClick(); }; this.InternalVirtualSetContent = value => { // what aboout? shadow dom ContentElement? // X:\jsc.svn\examples\javascript\Avalon\Test\TestShadowTextBox\TestShadowTextBox\ApplicationCanvas.cs button.innerText = "" + value; }; }