public CanvasForm()
        {
            InitializeComponent();

            factory = new ContentEditorFactory();
            factory.Initialize(@"SOFTWARE\Microsoft\Windows Live\Test Canvas", new CanvasLogger(), new CanvasTarget(), new CanvasSettingsProvider());
            editor = factory.CreateEditor(new CanvasSite(panelCanvas), null, "<html><head></head><body><div>{post-body}</div></body></html>", MshtmlOptions.DEFAULT_DLCTL);
            editor.DisableSpelling();

            panelCanvas.SizeChanged += new EventHandler(panelCanvas_SizeChanged);
        }
        public override void OpenContentEditor(List <ItemVersionUri> itemVersionUris, LoadItemsOptions options)
        {
            Assert.ArgumentNotNull(itemVersionUris, nameof(itemVersionUris));
            Assert.ArgumentNotNull(options, nameof(options));

            var document = new StringBuilder();

            foreach (var uri in itemVersionUris)
            {
                document.Append(uri);
            }

            var window = ContentEditorFactory.CreateEditor(document.ToString(), options.NewTab);

            if (window == null)
            {
                AppHost.Output.Log("Failed to open Content Editor window");
                return;
            }

            window.LoadItems(itemVersionUris, options);
        }