Using Microsoft Pinyin IME for typing in the RichTextBox causes FatalExecutionEngineError exception.
Clicking on floating Image when the caret position is not in the viewport, changes the viewport and starts image dragging. Instead, the image should just be selected. Steps to reproduce: 1. Start with empty document 2. Insert image, make it floating (right-click on it, select Text Wrapping -> In Front Of Text) 3. Drag the image near the bottom of the document. 4. Scroll and, if needed, zoom to such a factor, so that the first paragraph is outside of the view port. 5. Select the image (keep in mind that the image shouldn't be selected - the position should be at some of the previous paragraphs) Observe: The image dragging adorner is visible and the viewport is changed. Expected: The behavior shall be the same as MS Word - the viewport shouldn't be changed, and the image should just be selected
On export to HTML tab stops are converted to non-breaking spaces ( ). Sometimes the width of the all nbsp-s becomes different than the width of the tab stop. When document which contains grid-like data is exported to HTML its columns are not aligned.
In RadRichTextBox, when i export pdf in memorystream Footers are spread.
The content of the table cells seems to be rendered in the correct position while the borders are drawn above the continues section break.
"Win32Exception (0x80004005): Not enough storage is available to process this command" is thrown when multiple RadDocument instances are created in background threads. This is due to the fact that RadDocument contains MailMergeDataSource object, which is DependencyObject. When multiple dependency objects are created in different threads, they are not property freed by thread's Dispatcher. Workaround 1: Microsoft provided workaround in a bug report here: https://connect.microsoft.com/VisualStudio/feedback/details/620588/system-componentmodel-win32exception-0x80004005-not-enough-storage-is-available-to-process-this-command , namely: ------------------------------ Put the following code: Dispatcher dispatcher = Dispatcher.CurrentDispatcher; dispatcher.BeginInvokeShutdown(DispatcherPriority.Normal); Dispatcher.Run(); anywhere in the background thread processing the RadDocument. ----------------------------- Workaround 2: Use pooling of the used threads. The problem is that Task Parallel Library (which has built-in pooling) does not use STA threads by default, but this can be achieved by using custom TaskScheduler (attached, the code is get from here: https://code.msdn.microsoft.com/ParExtSamples ): var parallelOptions = new ParallelOptions() { TaskScheduler = new StaTaskScheduler(Environment.ProcessorCount) }; Parallel.For(0, 10000, parallelOptions, cc => { var document = new DocxFormatProvider().Import(data); byte[] pdfBytes = new PdfFormatProvider().Export(document); };
Possible workaround is to change the document of RadRichTextBox.
In certain rare occasions, double-clicking a table cell may throw:
inline does not belong to this document.
at Telerik.Windows.Documents.Model.RadDocument.GetContainingAnnotationRanges[TRangeStart](Inline inline, Predicate`1 filter, Boolean inclusive)
at Telerik.Windows.Documents.Selection.MouseSelectionHandler.HandleCheckBox(InlineLayoutBox layoutBox)
at Telerik.Windows.Documents.Selection.MouseSelectionHandler.RegisterDocumentSingleMouseDown(Boolean ctrlPressed, Boolean shiftPressed, Point position, UIElement originalSource)
. . .
Depending on the current layout of the document, invoking SetPosition() for a specific location might result in positioning the caret on the line prior to the expected one.
Steps to reproduce:
radRichTextBox.Insert("one: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("two: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("tree: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("four: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("five: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("seks: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("seven: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("eitgh: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("nine: ");
radRichTextBox.Insert(Environment.NewLine);
radRichTextBox.Insert("ten: ");
radRichTextBox.Document.CaretPosition.SetPosition(radRichTextBox.Document.CaretPosition.Location); radRichTextBox.Focus();
Observed: The caret is positioned after "eitgh:"
Expected: The caret shouldn't change its position
When trying to import a document containing bookmark and BookmarkRangeEnd is after the last paragraph, a StackOverflowException is thrown in IntervalNode while trying to rebuild the document cache. (RadDocumentChildrenCache.RebuildTree()). The same could be observed if the bookmark end is last in the header/footer, between table cells in the RadDocument body, or when all paragraphs after the bookmark range end are hidden (with vanish property). Workaround: Detect the problematic annotations and remove them: foreach (var rangeStart in document.EnumerateChildrenOfType<AnnotationRangeStart>()) { if (rangeStart.End == null || rangeStart.End.Parent == null || rangeStart.End.Parent.Parent == null) { //MessageBox.Show("This indicates a problem."); rangeStart.Parent.Children.Remove(rangeStart); } } Note: Until 2017 R2 SP1 release StackOverflowException is thrown, after this release an ArgumentException should be thrown.
The invalid document can't be measured and IndexOutOfRangeException/NullReferenceException will be thrown.