示例#1
0
        void radRichTextBox_Loaded(object sender, RoutedEventArgs e)
        {
            RadDocument document   = new RadDocument();
            string      randomText = @"On the Insert tab, the galleries include items that are designed to coordinate with the overall look of your document. You can use these galleries to insert tables, headers, footers, lists, cover pages, and other document building blocks. When you create pictures, charts, or diagrams, they also coordinate with your current document look";

            document.Insert(randomText, document.StyleRepository[RadDocumentDefaultStyles.NormalStyleName]);

            this.radRichTextBox.Document = (RadDocument)document.CreateDeepCopy();
            this.radRichTextBox.Document.Sections.First.Headers.Default.Body = document;
        }
示例#2
0
        void radRichTextBox_Loaded(object sender, RoutedEventArgs e)
        {
            RadDocument document = new RadDocument();
            string randomText = @"On the Insert tab, the galleries include items that are designed to coordinate with the overall look of your document. You can use these galleries to insert tables, headers, footers, lists, cover pages, and other document building blocks. When you create pictures, charts, or diagrams, they also coordinate with your current document look";

            RadDocumentEditor documentEditor = new RadDocumentEditor(document);
            documentEditor.Insert(randomText);

            this.radRichTextBox.Document = (RadDocument)document.CreateDeepCopy();
            this.radRichTextBox.Document.Sections.First.Headers.Default.Body = document;
        }