0

Maybe some one can help me or tell me how to add an icon in the tab of a new document in "DockPanel Suite" ? Or what is the best way to do this ? Thank you in advance for your help and feedback. Regards, Daniel

(Another point. It will be nice to do that with VS2012 Light theme. Thank you in advance. Daniel)

1 Answers1

0
  1. Set DockContent.Icon to the icon you want (similar to set Icon of a normal Form).

  2. Set DockPanel.ShowDocumentIcon to true.

If you look for a sample, this Compiler project uses this feature,

https://github.com/lextudio/sharpsnmplib/tree/51773488fcb7b9714a38134187363fef5762daca/Compiler

To get VS2012 theme, make sure that

  1. You use our 3.0 NuGet package or build from development_3.0 branch, https://github.com/dockpanelsuite/dockpanelsuite/tree/development_3.0

  2. Create a new instance of VS2012LightTheme class and assign it to DockPanel.Theme.

This has been demonstrated in DockSample project of DockPanel Suite,

https://github.com/dockpanelsuite/dockpanelsuite/blob/development_3.0/DockSample/MainForm.cs

You can see the changes needed in SetSchema method.

Note that all existing DockContent objects should be cleaned before changing themes.

Lex Li
  • 60,503
  • 9
  • 116
  • 147
  • Good morning Li, Great, thank you very much for your fast response... It works well ;) Thank you again. Anyway, do you know how to operate it with the VS2012Light skin ? Of course it's the one I need. lol. Thank you in advance for your reply. Rgds, Daniel – Danie Rossel Jan 07 '14 at 07:06
  • @Li Hello Li, Thank you for your help. I appreciate. Maybe I'm not have been clear enough, sorry. Anyway, my problem now is that I cannot display icons in tabs when I use the theme VS2012Light. it works with other themes, but not with VS2012Light. Thank you in advance for your help and for your patience. Rgds, Daniel. PS. Sorry for my English – Danie Rossel Jan 08 '14 at 14:24
  • I have checked in a new change set on GitHub which fixed this issue. You might build a new copy from development_3.0 branch and test it out. – Lex Li Jan 11 '14 at 02:48
  • @Li Hello Li, Thank you, thank you... It works fine now... I realy appreciate your availability.. Again, BRAVO for your works on DockPanel Suite. Greetings – Danie Rossel Jan 11 '14 at 13:32