duality icon indicating copy to clipboard operation
duality copied to clipboard

Improved HelpAdvisor display

Open AdamsLair opened this issue 11 years ago • 8 comments

  • The HelpAdvisor should feature rich text and simple text flow controls.
  • It should be "justify"-ed, because that looks better
  • Allow simple text formatting like bold, italic or underlined.
  • See if there are any renderers that can already do that
  • Looks promising: http://www.codeproject.com/Articles/32376/A-Professional-HTML-Renderer-You-Will-Use

AdamsLair avatar Jul 21 '13 19:07 AdamsLair

Hi I want to help. I'm newbie with duality and opensource. Would you like to support me? thanks :)

youssefMansour avatar Sep 13 '14 19:09 youssefMansour

Hi youssefMansour,

I'm glad you like Duality and are willing to help. Although I'm quite busy right now and thus can't give you a personal guide into both Duality and contributing, there is already a little bit of documentation available on how to use Duality and how to help. If you're new to Duality, working on actual issues is not the right spot to start, but there are a lot of other ways to help that are definitely appreciated as well!

If you need additional support, feel free to join the community, present your work and get in touch with others. :)

Regards, Adam

AdamsLair avatar Sep 14 '14 20:09 AdamsLair

Alright, I gave it a look a few months after my last comment (which contained wrong information now that I correctly tested it), and the way Duality "renders" the help text prevents HtmlRenderer from working.

What you'd need to do is either:

  • a) Pass the topic and description values to labelTopic and labelDescription;
  • b) Render the HTML in the OnPaint method

In case letter B is chosen, you should consider markdown rendering instead of HTML (or support both). Markdown for the win!

Xinayder avatar Dec 05 '15 19:12 Xinayder

In case letter B is chosen, you should consider markdown rendering instead of HTML (or support both). Markdown for the win!

The more I think about it, the more I prefer markdown as well. There are probably some good markdown renderers out there for .Net as well.

An additional requirement will be properly displaying C# XML comment markup, since most help advisor texts are generated from them. For keeping compatibility with Visual Studio and reference generators, XML comments will be required to use their own markup and unable to use markdown syntax. The advisor could then convert them to markdown before parsing it, not a problem - however, a consequence would be that the only way users could truly enter markdown help texts is for custom help advisor topics.

Probably not as awesome as one might think when reading "markdown support for help advisor text", but still :)

ilexp avatar Dec 06 '15 12:12 ilexp

Been playing around a bit, but I might need some help from @ilexp for dealing with external dependencies image

SirePi avatar Mar 23 '20 21:03 SirePi

Looks neat 👍 What do you need?

ilexp avatar Apr 04 '20 13:04 ilexp

Initially I was thinking about having to deal with external dependencies, and how to make them go in the Plugins directory on build but, if #786 goes through, maybe there is no more need for this.

Just in case though, is there something needed, or does it happen automatically if the plugin sits in a nuget package? been a while since I last did an editor plugin 😄

SirePi avatar Apr 05 '20 06:04 SirePi

If you bundle the dependencies directly in your package, they will be treated the same as the package itself and will go in the Plugins folder - which is fine and should work. If you link them as a dependency of your package, it depends on how that package is tagged. If it's a regular library, it will go to the root folder, if it's a Duality plugin, the same applies. Both cases are supported. If you're interested, this is where to look for the implementation.

ilexp avatar Apr 09 '20 12:04 ilexp