Is it possible to change this behaviour so that the popup is always displayed without zoom render transform? just like when using the ItemInformationAdorner.AdditionalContent?
7 Answers, 1 is accepted
The Popup within the MindMap example is placed inside the Shape's ControlTemplate and so it is part of the zoom-able visual tree. This is just for the sample, but I would recommend you to do it using the Selection adorner or to modify the Settings Pane control to suits your need. (Actually the Settings Pane is usually added to the ItemInformationAdorner.AdditionalContent. For the next release of the samples we'll also improve this behaviour.
Please let us know if you have further questions.
Miro Miroslavov
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Is that possible?
The ItemInformationAdorner is placed on the same size as the Selection Adorner, meaning that currently the only way to make it appears on one item is to use Single selection instead of multiple.
So if this is not an option, we have only two options right now - to reverse scale/zoom it (if you go the Mindmap way), which could be somehow hard to do. Or the other option is to change the diagram template and there is a way to add there a new adorner that you can later place only on single shapes. Actually you can do that outside the Diagram - you can handle the Selection event and place a popup (or floating canvas) next to the selected shape. You can easily get the actual position of the Shape and just place your adorning thing there.
In the meanwhile, I'll add a work item so that we must provide an API for easier way of doing this.
Please let us know if any of these solutions work for you, or you need further assistance.
Miro Miroslavov
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
One way to achieve this is to change the DropDown button in the MindMap shape's styles with a toggle button:
<
telerik:RadGeometryToggleButton
x:Name
=
"settingsPaneButton"
IsChecked
=
"{Binding RelativeSource={RelativeSource TemplatedParent}, Path=IsSettingsOpen, Mode=TwoWay}"
Style
=
"{StaticResource SettingsPaneToggle}"
/>
this
.AddHandler(RadGeometryToggleButton.CheckedEvent,
new
RoutedEventHandler(OnChecked));
this
.AddHandler(RadGeometryToggleButton.UncheckedEvent,
new
RoutedEventHandler(OnUnchecked));
private
void
OnUnchecked(
object
sender, RoutedEventArgs e)
{
var button = e.OriginalSource
as
RadGeometryToggleButton;
if
(button !=
null
&& button.Name ==
"settingsPaneButton"
)
{
...
}
}
private
void
OnChecked(
object
sender, RoutedEventArgs e)
{
var button = e.OriginalSource
as
RadGeometryToggleButton;
if
(button !=
null
&& button.Name ==
"settingsPaneButton"
)
{
...
}
}
I've attached a sample project demonstrating this approach for the MindMap's Root and FirstLevel shapes so could you please examine it and tell us if this is what you're looking for.
Regards,
Zarko
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.