When trying to show the RadRichTextBox' LineNumberingDialog, nothing is displayed. This happens when using the NoXaml Telerik dlls and themes other than Windows11. The dialog is shown only in the Windows11 theme.
To work this around, add the following two lines in the App.xaml resources.
<Application x:Class="WpfApp1.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:WpfApp1"
xmlns:telerikDialogs="clr-namespace:Telerik.Windows.Controls.RichTextBoxUI.Dialogs;assembly=Telerik.Windows.Controls.RichTextBox"
StartupUri="MainWindow.xaml">
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="/Telerik.Windows.Themes.Fluent;component/Themes/System.Windows.xaml"/>
<ResourceDictionary Source="/Telerik.Windows.Themes.Fluent;component/Themes/Telerik.Windows.Controls.xaml"/>
<ResourceDictionary Source="/Telerik.Windows.Themes.Fluent;component/Themes/Telerik.Windows.Controls.ImageEditor.xaml"/>
<ResourceDictionary Source="/Telerik.Windows.Themes.Fluent;component/Themes/Telerik.Windows.Controls.Navigation.xaml"/>
<ResourceDictionary Source="/Telerik.Windows.Themes.Fluent;component/Themes/Telerik.Windows.Controls.Input.xaml"/>
<ResourceDictionary Source="/Telerik.Windows.Themes.Fluent;component/Themes/Telerik.Windows.Controls.RibbonView.xaml"/>
<ResourceDictionary Source="/Telerik.Windows.Themes.Fluent;component/Themes/Telerik.Windows.Controls.RichTextBox.xaml"/>
</ResourceDictionary.MergedDictionaries>
<Style TargetType="telerikDialogs:LineNumberingDialog" BasedOn="{StaticResource RadWindowStyle}"/>
<Style TargetType="telerikDialogs:LineNumberingDistanceNumericUpDown" BasedOn="{StaticResource RadNumericUpDownStyle}"/>
</ResourceDictionary>
</Application.Resources>
</Application>
Add information about the selection in the SelectionChanged event arguments.
- We need to differentiate from mouse event to keyboard event. But since the EventArgs is empty we are not able to differentiate.
The numeric box that allows you to select the "to" page in the PrintPreviewControl is clipped when the "Pages:" and "to" strings are translated to a language where these words are longer. For example, this reproduces with Dutch culture which uses the "Pagina's:" and "naar" texts.
To work this around, you can get the Grid panel that hosts the content and increase the Width of one of its ColumnDefinitions.
private void PrintPreviewControl_Loaded(object sender, RoutedEventArgs e)
{
var printPreview = (PrintPreviewControl)sender;
var rootGrid = printPreview.FindChildByType<Grid>();
rootGrid.ColumnDefinitions[0].Width = new GridLength(355);
}
The center text alignment is lost when the last paragraph is copied and pasted.
Steps to reproduce:
- Enter some text and center it.
- Copy and paste it into another document.
Actual: the aligmennt is lost
Expected: the alignment should be preserved
A XamlParseException is raised when the theme's resource dictionaries are not merged in App.xaml. The missing resource is the RepeatButtonStyle resource.
To work this around, merge the resource dictionaries for the theme in the Resources collection of the App.xaml file.
Currently, the RadExpressionEditor control shows a wavy underline and a red color to indicate that an error is present.
We could introduce API to modify this behavior, which will ultimately be used by the ChangeUnderlineDecoration and ChangeUnderlinesColor methods of the internal RadRichTextBox control.
One of the following two exceptions occur when the BindingOperations.EnableCollectionSynchronization() is used with the ItemsSource of RadTreeListView:
When using the EnableCollectionSynchronization, the corresponding items control should allow updates of the ItemsSource collection on different threads. This is valid if the requirements to use the EnableCollectionSynchronization method are met.
The exception stack traces are:
InvalidOperationException
at System.ThrowHelper.ThrowInvalidOperationException_InvalidOperation_EnumFailedVersion() in /_/src/libraries/System.Private.CoreLib/src/System/ThrowHelper.cs:line 432
at System.Collections.Generic.List`1.Enumerator.MoveNext() in /_/src/libraries/System.Private.CoreLib/src/System/Collections/Generic/List.cs:line 1130
at System.Linq.Enumerable.SelectEnumerableIterator`2.MoveNext()
at Telerik.Windows.Data.EnumerableExtensions.<SelectRecursive>d__15`1.MoveNext()
at System.Linq.Enumerable.SelectEnumerableIterator`2.MoveNext()
at Telerik.Windows.Data.HierarchicalCollectionViewBase.PopulateInternalList(IQueryable view)
at Telerik.Windows.Data.QueryableCollectionView.get_InternalList()
at Telerik.Windows.Data.HierarchicalCollectionViewBase.get_InternalCount()
at Telerik.Windows.Data.DataItemCollection.get_Item(Int32 index)
at Telerik.Windows.Controls.GridView.Rows.GetRowItemsAtRange(Int32 startIndex, Int32 endIndex)
at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.FlatLayoutStrategy.RealizeRows(Int32 startIndex, Int32 endIndex, Double& verticalOffset, HashSet`1& realizedRows)
at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.FlatLayoutStrategy.MeasureOverride(Size availableSize)
at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.MeasureOverride(Size availableSize)
NullReferenceException at Telerik.Windows.Data.QueryableCollectionView.InternalGetItemAt(Int32 index) in Telerik.Windows.Data\QueryableCollectionView.cs:line 3081 at Telerik.Windows.Controls.GridView.Rows.GetRowItemsAtRange(Int32 startIndex, Int32 endIndex) at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.FlatLayoutStrategy.RealizeRows(Int32 startIndex, Int32 endIndex, Double& verticalOffset, HashSet`1& realizedRows) at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.FlatLayoutStrategy.MeasureOverride(Size availableSize) at Telerik.Windows.Controls.GridView.GridViewVirtualizingPanel.MeasureOverride(Size availableSize)
To work this around dispatch the updates of the ItemsSource collection to the main UI thread.
Dispatcher.BeginInvoke(new Action(() =>
{
// add/remove items from the source collection
}));
The attached image shows the issue.