With visual styles, i can use
VisualStyleElement.TreeView.Glyph.Closed
and VisualStyleRenderer to draw [+] button like in TreeView.
But when user have a "Classic" style in Windows, visual styles are not supported and I still need to draw this glyph.
It is still possible to use classes like
System.Windows.Forms.CheckBoxRenderer
but I haven't found anything like this for Tre开发者_高级运维eView glyphs.
Yes, it is not possible to get that glyph. It is a simple one but you have to write the code. DrawRectangle and DrawLine. Or use a bitmap. Or make it look like the simple Vista triangles. Or don't enable ownerdraw when visual styles are off.
精彩评论