Telerik Forums
UI for WPF Forum
2 answers
211 views
Our WPF application contains multiple RadRichTextBox instances. When right clicking in one of the instances I expected the ContextMenu_Showing event to get fired for only the RadRichTextBox control that I right clicked. This is not the case. 

The method gets fired for each instance of the RadRichTextBox.  As a result, instead of getting one "View Source" context menu item inserted into the context menu, I get one for each RadRichTextBox control.

I am trying to implement the modification of the RadRichTextBox's context menu as indicated at the following link:
http://www.telerik.com/help/wpf/radrichtextbox-features-context-menu.html

I also modified the example as indicated in the following blog to reference the correct ContextMenu:
http://blogs.telerik.com/xamlteam/posts/10-11-17/customizing-radrichtextbox-s-contextmenu-and-selectionminitoolbar.aspx

In the Telerik public constructor I have the following code:

            Telerik.Windows.Controls.RichTextBoxUI.ContextMenu contextMenu =
                (Telerik.Windows.Controls.RichTextBoxUI.ContextMenu)this.radRichTextBox.ContextMenu;
            contextMenu.Showing += this.ContextMenu_Showing;

I also have the following methods:

        private void ContextMenu_Showing(object sender, Telerik.Windows.Controls.RichTextBoxUI.Menus.ContextMenuEventArgs e)
        {
            RadMenuItem makeViewSourceMenuItem = new RadMenuItem()
            {
                Header = "View Source"
            };
            makeViewSourceMenuItem.Click += MakeViewSourceMenuItem_Click;
            ContextMenuGroup customContextMenuGroup = new ContextMenuGroup();
            customContextMenuGroup.Add(makeViewSourceMenuItem);
            e.ContextMenuGroupCollection.Add(customContextMenuGroup);
        }        private void MakeViewSourceMenuItem_Click(object sender, RadRoutedEventArgs e)
        {
            FrmHtmlSource dialog = new FrmHtmlSource(_originalText);
            dialog.ShowDialog();
        }

All the examples I have seen involve just one instance of the RadRichTextBox.  Is there anything special I need to do to support multiple instances or is this a limitation with the RadRichTextBox control.
Ralph
Top achievements
Rank 1
 answered on 27 May 2014
1 answer
100 views
This code takes the DataContext of the Diagram and Serializes it to XML and saves it to file.  However, I want to keep the shape's properties in my own object as XML.  So, I don't want it to save to file.  I want to the read the value into my own object then Serialize my object using XmlSerialization.  Is there any other option to get diagram to give up its XML?   Can this be done using your Persistance framework?

As always, a code example is appreciated.


FileManager fileManager = new FileManager(diagram);
fileManager.SaveToFile(FileLocation.Disk);
Joel Palmer
Top achievements
Rank 2
 answered on 27 May 2014
4 answers
264 views
I want to start from your example labeled "Diagram Toolbox".  This examples has a lot of circles.  However, your containers are square.  Can you give me an example of a container that is styled as round?

Also, I need to model circles that over-lap.  Do you have a way to show the part that is overlapping as a different color and I could put some text explaining the over-lap?  For example, if I have Family1 and Family2 and I need to model how Family3 has people from both groups because of a marriage between F1 and F2, I would have 3 circles that have overlap.
Joel Palmer
Top achievements
Rank 2
 answered on 27 May 2014
1 answer
95 views
Hi there,

I realize this has been around a few times but I couldn't find a good answer here or in the demo apps, so..

How can we adjust the appearance of the WPF GridView from xaml without using Blend?
Currently we're using the "Office_Silver" theme and are pretty happy with it.

All we'd like to do is to remove the mouse-over animation for the header row and change the background and text color for the selected cells.

Shouldn't this be possible with 2-3 lines of XAML?

Thanks,
Jay
Ivan Ivanov
Telerik team
 answered on 27 May 2014
2 answers
149 views
I am building an application (WPF) that will run on systems that vary in specifications from a single monitor to multiple monitors.  I am trying to think through the navigation and screen placement of the multiple windows that the application will have.  I want to be able to place the windows on an available monitor, but I also want a consistent pattern for the user so that the window shows up where expected. 

So I am looking for any information or research on multi-monitor UX design that dives into navigation, window placement, notifications, etc. by an application.  There are lots of research and articles about small screen navigation, but nothing I have found that talks about Multi-Monitors.

Any links or ideas would be appreciated

Thanks
Paul 
Paul
Top achievements
Rank 1
 answered on 27 May 2014
1 answer
81 views
I have a couple of RadListViews - they are same except for they visualize different item collections. I need to have Draop and drop functionality to Reorder items inside list view, but I want to disallow dragging and dropping items from one list to another.

How can I accomplish this?
Kalin
Telerik team
 answered on 27 May 2014
1 answer
453 views
Hi,

I want to use the Style of Windows8 Theme for my "RadWindow", but I want to change
just the "WindowHeEaderBackground" color from blue to green.

How can I solve this easily.

Thanks a lot
Regards
Rene
Kalin
Telerik team
 answered on 27 May 2014
1 answer
194 views
I have a ListBox bound to collection of items, which each defines its Command in the ViewModel.
The SelectedItem is Bound to the ViewModel of the ListBox itself with TwoWay-Binding since I need to change Selection from Code.
Short version looks like this.

<
telerik:RadListBox ItemsSource="{Binding Items}" 
ItemTemplate
="{StaticResource ItemTemplate}" 
SelectedItem="{Binding SelectedItem, Mode=TwoWay}"
                    Command="{Binding SelectedItem.Command}"
 SelectionMode="Single"
>
Now I've encountered the problem, that if I set SelectedItem in the ViewModel to 'null', the Item thats just been DeSelected still fires its Command one more time, which I personally would consider a bug.

Also this leads to an interesting behaviour in my app...

Someone any ideas, other than to create an event Handler for Selection changed and fire the Command from CodeBehind?

Any suggestions would be much appreciated.
Thx a bunch.
Polya
Telerik team
 answered on 27 May 2014
2 answers
208 views
Hi!

At the moment, I'm writing an application using the RadRibbonWindow, a RadRibbonView and PRISM. Today I encountered a problem and I'm not sure if this is a bug or me doing something the wrong way.

The application consists of these main parts:
-The shell (A RadRibbonWindow)
-A RadRibbonView hosted inside the Window (it has the RegionManager.RegionName set to "RibbonView")
-Multiple modules each containing RadRibbonTabs (some have the ContextualGroupName where needed
-Each module is added to the region using the [ViewExport(RegionName="RibbonView")] attribute and the AutoPopulateExportedViewsBehavior
-Implicit Styles are used (Office 2013)

Now the strange part:
Only RibbonTabs having the ContextualGroupName set are visible in the RibbonView (as expected), but injected tabs having this attribute not set are not visible (I expected them to show up permanent)

Remarks:
Somewhere in this forum I read that an additional RegionAdapter is not needed in my case, because each injected usercontrol derives directly from RadRibbonTab. I think Tina mentioned this in one of her posts. Some tabs show up so I guess this is right, isn't it?
Nevertheless I experimented with RegionAdapters but had no success.

I would appreciate any help or hint getting my problem solved :) Many thanks in advance!

btw.: I'm already using Q1 2014
Hans
Top achievements
Rank 1
 answered on 27 May 2014
2 answers
132 views
I'm using DropDownButton to display Winform or HWND window, but it seems that it does not display any Winform in DropDownContent

Here is example:
<Window
    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" x:Class="MainWindow"
     xmlns:Forms32="clr-namespace:System.Windows.Forms;assembly=System.Windows.Forms"
    Title="MainWindow" Height="350" Width="525">
    <Grid>
 
        <telerik:RadDropDownButton Content="Browser" HorizontalAlignment="Left" Height="Auto" IsOpen="False" Margin="36,21,0,0" VerticalAlignment="Top" Width="Auto" DropDownWidth="800" DropDownHeight="600">
            <telerik:RadDropDownButton.DropDownContent>
                <WindowsFormsHost>
                    <Forms32:WebBrowser Url="google.com"></Forms32:WebBrowser>
                </WindowsFormsHost>
            </telerik:RadDropDownButton.DropDownContent>
        </telerik:RadDropDownButton>
         
        <telerik:RadDropDownButton Content="Button" HorizontalAlignment="Left" Height="Auto" IsOpen="False" Margin="129,21,0,0" VerticalAlignment="Top" Width="Auto">
            <telerik:RadDropDownButton.DropDownContent>
                <WindowsFormsHost>
                    <Forms32:TextBox Text="Test Text Box"></Forms32:TextBox>
                </WindowsFormsHost>
            </telerik:RadDropDownButton.DropDownContent>
        </telerik:RadDropDownButton>
 
    </Grid>
</Window>

Pov Ser
Top achievements
Rank 1
 answered on 27 May 2014
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
DataPager
PersistenceFramework
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
LayoutControl
ProgressBar
Sparkline
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
SplashScreen
Callout
Rating
Accessibility
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
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?