This is a migrated thread and some comments may be shown as answers.

ImageAdornerUi not visible

4 Answers 151 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 11 Apr 2020, 01:19 PM

Hi,

I'm battling with an issue where the ImageAdornerUi is not visible when viewing in a WPF window in a VSTO project.  I can create a standalone WPF app and the adorner is visible, but in the VSTO project with the same code, it's not.  I'm assuming that this is a resource resolution issue, but I coming up short on finding the actual problem. 

I'm attaching two images that show the difference between the two project types, and also have a bare bones VSTO (Excel) project that I can send if that would be helpful.

I don't believe this is just an issue with ImageAdornerUi as other UI elements such as the Insert Hyperlink and Font dialogs also fail to appear.

Are you able to shed any light on what I'm doing wrong here please?

Many thanks

John

4 Answers, 1 is accepted

Sort by
0
Tanya
Telerik team
answered on 15 Apr 2020, 01:08 PM

Hi John,

It seems like you are using the implicit styling mechanism and the NoXaml binaries to apply the desired theming to the control. This approach requires some of the resources to be merged on application level. To better describe, the windows and popups that the users can open from RadRichTextBox are loaded on a visual tree different than the one of the control. That said, these additional windows don't have access to the resources of RadRichTextBox and its parent window.

Is there any particular reason for using the NoXaml assemblies? If you don't need to implement specific style customizations, I would suggest you use the StyleManager to apply the desired theme.

Regards,
Tanya
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
0
John
Top achievements
Rank 1
answered on 17 Apr 2020, 01:31 PM

Hello Tanya,

Thanks very much for your reply.  That has helped track this down.

I'm using the NoXaml binaries on the basis of the smaller size, but I think I've discovered my problem, which is the having no application object in the hosted VSTO environment.  I was just trying to reference a global merged resource dictionary, but have since wrapped this in an Application (in xaml) object and am newing this up in the ThisAddIn startup method as per the approaches in a Dr.Wpf article and an SO answer:

http://drwpf.com/blog/2007/10/05/managing-application-resources-when-wpf-is-hosted/

https://stackoverflow.com/questions/50363992/excel-vsto-use-resourcedictionary-which-is-in-separate-assembly

So with the creation of the Application object and merging the xaml resources in its dictionary I'm now getting the image adorner and hyperlink dialog etc.

Thanks again for your help.

John

0
Timo
Top achievements
Rank 1
answered on 29 Oct 2020, 09:11 AM

Hi,

are there any known issues about the adorners not being shown when using .NetCore?

I have two simple sample projects. One with .NetCore 3.1, one with .Net 4.8.

On my machine, I do not see the image resize adorners when starting the .NetCore solution. But they are visible when starting the .Net 4.8 solution.

What do I need to do so that my .NetCore project behaves similarly to the .Net 4.8 project?

I would like to share these projects with you, but uploading zip files is prevented...

0
Tanya
Telerik team
answered on 29 Oct 2020, 04:09 PM

Hi Timo,

Yes, the .NET Core version of the control has a known limitation related to the image adorner: RichTextBox: Image adorner is not properly ported and it is not supported in NetCore. Currently, I cannot provide you with a workaround for enabling the adorner. This issue is with high priority in our backlog and has good chances to be fixed in the upcoming release. Please, make sure you are following the item so we can notify you when its status changes.

Hope this information is useful.

Regards,
Tanya
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
RichTextBox
Asked by
John
Top achievements
Rank 1
Answers by
Tanya
Telerik team
John
Top achievements
Rank 1
Timo
Top achievements
Rank 1
Share this question
or