Telerik Forums
UI for WPF Forum
1 answer
150 views

Hello,

Is there an option I can enable in the RadTabControl like the one shown below for creating new tabs?

If not, is there a easy way to add a custom "+" button to the toolbar area?

Stenly
Telerik team
 answered on 12 Apr 2022
1 answer
344 views

I'm not sure if it's possible but what i want to achieve is when a user changes the selecteditem they get a question it they are sure if they want to change the selection. If they say ok, no problem, but in the other cases i want to 'cancel' the selectionchanged and keep the currently selecteditem.

I can stop the event with the e.handled = true but it still changes the selected item.

Is there anything i can do to reach this behaviour?
I've seens there is no cancel on the evenArgs so that's not an option.

 

Stenly
Telerik team
 answered on 12 Apr 2022
1 answer
135 views

I have a activeX control added to WindowsFormsHost which in turn loaded inside a RadPane. Everything works fine, but once you make the Radpane float. then its empty. Am I missing some settings here?

Martin Ivanov
Telerik team
 answered on 12 Apr 2022
1 answer
209 views

Hello,

I have a need to customize the header part of the RadPanelBarItems, by adding a checkbox (see below). When I make this change, the text color used for that particular RadPanelBarItem (in this case "Five") is not the same as the defaults (during mouse over or selection).

How can I get the default behavior of the Black color font when selected (or mouse over) on my customized RadPanelBarItem. The only thing I need to do is add a checkbox to the header as shown.

In the picture below items "One", "Two", "Three" and "Four" use default behavior. "Five" has the customized header.

Thanks in advance

Mouse over or selected "Five". Notice the "White" font does not change to Black.

Mouse over or selected "Two". Notice that the font changes to "Black" - desired behavior

 

   <telerik:RadPanelBar>
            <telerik:RadPanelBarItem Header="One">
            </telerik:RadPanelBarItem>
            <telerik:RadPanelBarItem Header="Two">
            </telerik:RadPanelBarItem>
            <telerik:RadPanelBarItem Header="Three" />
            <telerik:RadPanelBarItem Header="Four" />

            <telerik:RadPanelBarItem>
                <telerik:RadPanelBarItem.Header>
                    <Grid>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="*"/>
                            <ColumnDefinition Width="Auto"/>
                        </Grid.ColumnDefinitions>
                        <TextBlock Grid.Column="0" Text="Five" />
                        <CheckBox Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center"/>
                    </Grid>
                </telerik:RadPanelBarItem.Header>
            </telerik:RadPanelBarItem>
        </telerik:RadPanelBar>
Dilyan Traykov
Telerik team
 answered on 11 Apr 2022
1 answer
169 views

How do I change the color under the dates?

I tried to change colors in all sorts of styles but could not find which style was responsible for it

Would appreciate help

Stenly
Telerik team
 answered on 11 Apr 2022
0 answers
117 views

Use RadGridView and RadDropDownList controls to create the user control of the parent form, and then create a sub-form user control named AbutBodyMtdPageBase to inherit the parent form, and create a new UserControl named AbutBodyTpMtdPage, and then drag the sub-form user control of AbutBodyMtdPageBase to enter AbutBodyTpMtdPage, create a new Form form, drag AbutBodyTpMtdPage into the Form, and the RadGridView form does not display data during program execution.
The above descriptions are all created user controls, and finally a new Form is created.

Xingyu
Top achievements
Rank 1
 updated question on 11 Apr 2022
0 answers
116 views

Hello,

I've a strange issue with a treelistview.

Only when the scrollbar is at the bottom, add a new item is not "detected"  (works fine 1 /2 times and break after..., scroll to another position and add a new item works fine).

I can't reproduce the issue with an external basic "sample" , (and the issue is reproduced only for one of the two instance I have)

Basically is something like this:

public class ViewModel
{
   ObservableCollection<ItemToAdd> Items;

   void OnNewItems(ICollection<ItemToAdd> newitems)
   {
      Foreach(item in newitems)
      {
         var parentNode  = Items.where( x => x = newitem)
         parentNode?.Children.Add(item)
      }
   }
}

publicclassItemToAdd
{
   ObservableCollection <ItemToAdd> Childrens
}
<telerik:RadTreeListView x:Name="Tree"
                                 ItemsSource="{Binding Items}"
                                 CanUserFreezeColumns="False" 
                                 RowIndicatorVisibility="Collapsed" 
                                 ColumnWidth="auto" 
                                 AutoGenerateColumns="False" 
                                 IsDragDropEnabled="True"
                                 IsDropPreviewLineEnabled="False"
                                 ShowColumnHeaders="True"
                                 RowStyle="{StaticResource RowStyle}" 
                                 SelectionMode="Extended" 
                                 GridLinesVisibility="None"
                                 IsExpandedBinding="{Binding IsExpandedInTree, Mode=TwoWay}"">

...

            <telerik:RadTreeListView.ChildTableDefinitions>
                <telerik:TreeListViewTableDefinition ItemsSource="{Binding Children}" />
            </telerik:RadTreeListView.ChildTableDefinitions>
        </telerik:RadTreeListView>

Here my tree is like this:

> Main node
    > Sub Node level 1
         >Sub Node level 2
         >Sub Node level 2
    > Sub Node level 1
         >Sub Node level 2
         >Sub Node level 2
    > Sub Node level 1
         >Sub Node level 2
         >Sub Node level 2

It seems that disabling Virtualization solve the issue but I don't want to do this.

Any idea?

Thanks!!

Emy
Top achievements
Rank 1
 asked on 08 Apr 2022
1 answer
191 views

Hi,

In our project we have a document editor that borrows from the code of the telerik editor found here: https://github.com/telerik/xaml-sdk/blob/master/RichTextBox/TelerikEditor/TelerikEditor.xaml. After the release allowing shapes to be added we have been receiving requests to add the ability for the use to input shapes using the our editor in the same way it is shown here: https://docs.telerik.com/devtools/wpf/controls/radrichtextbox/features/shapes/shapes. After a lot of searching through forums and the documentation on shapes I have found no way to implement this feature. Could someone advise me on how to add the shapes dropdown to the ribbon of the editor, and whether or not that is all the code I will need to allow a user to add/manipulate the predefined shapes? The documentation says that "In the Insert tab, you will find a list containing various predefined shapes you can choose between". I haven't found a way to add this to our editor or even where it resides in the telerik editor. Any help would be greatly appreciated.

Dimitar
Telerik team
 answered on 08 Apr 2022
1 answer
383 views

Hi,

I have created a gridview with a rowdetail that uses the rowdetailstemplateselector to show a different row depending on an itemsource property. I would like to control rowdetailsvisibiltiy based on a property of the item. Is there an example for this and or could you point me to what event I would need to use to control the the rowdetailsvisiblity on a per row basis?

Thanks

Rob

Martin Ivanov
Telerik team
 answered on 08 Apr 2022
1 answer
123 views

Tried extending the a custom tooltip tagger to recognize multiple words/tooltips but no luck. Below is my custom tooltip tagger, any thoughts on where I am going wrong?


using System.Collections.Generic;
using Telerik.Windows.SyntaxEditor.Core.Editor;
using Telerik.Windows.SyntaxEditor.Core.Tagging;
using Telerik.Windows.SyntaxEditor.Core.Text;

namespace QuickMeasuresPro
{
    class DAXTooltipTagger : TaggerBase<ToolTipTag>
    {
        private string searchWord;

        private static readonly string[] Keywords = new string[]
        {
            "APPROXIMATEDISTINCTCOUNT","AVERAGE","AVERAGEA","AVERAGEX"
        };

        private static readonly string[] Tooltips = new string[]
        {
            "APPROXIMATEDISTINCTCOUNT(<columnName>)\r\nReturns the approximate number of rows that contain distinct values in a column.",
            "AVERAGE(<column>)\r\nReturns the average (arithmetic mean) of all the numbers in a column.",
            "AVERAGEA(<column>)\r\nReturns the average (arithmetic mean) of the values in a column.",
            "AVERAGEX(<table>,<expression>)\r\nCalculates the average (arithmetic mean) of a set of expressions evaluated over a table.",
        };

        public DAXTooltipTagger(ITextDocumentEditor editor)
            : base(editor)
        {
        }

        public override IEnumerable<TagSpan<ToolTipTag>> GetTags(NormalizedSnapshotSpanCollection spans)
        {
            if (string.IsNullOrEmpty(this.searchWord))
            {
                yield break;
            }

            TextSnapshot snapshot = this.Document.CurrentSnapshot;
            foreach (TextSnapshotSpan snapshotSpan in spans)
            {
                string lineString = snapshotSpan.GetText();
                int i = 0;
                foreach (string keyword in Keywords)
                {
                    string tooltip = Tooltips[i];
                    i++;
                    int index = lineString.IndexOf(keyword);
                    while (index != -1)
                    {
                        TextSnapshotSpan tempSnapshotSpan = new TextSnapshotSpan(snapshot,
                            new Span(snapshotSpan.Start + index, keyword.Length));

                        yield return new TagSpan<ToolTipTag>(tempSnapshotSpan, new ToolTipTag(tooltip));

                        index = lineString.IndexOf(keyword, index + keyword.Length);
                    }
                }
            }
        }

        public void UpdateSearchWord(string newSearchWord)
        {
            this.searchWord = newSearchWord;
            this.CallOnTagsChanged(this.Document.CurrentSnapshot.Span);
        }
    }
}

Petar Mladenov
Telerik team
 answered on 08 Apr 2022
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
WatermarkTextBox
DesktopAlert
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
ProgressBar
Sparkline
LayoutControl
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?