By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,957 Members | 1,218 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,957 IT Pros & Developers. It's quick & easy.

C# VS Add-In: Modifying Solution Explorer Icons and/or Text

P: n/a
Hello everyone,

I'm working on a VS .NET add-in that will allow developers to use
Subversion software from within the IDE (much like Source Safe).
Ideally, I would like for my plug-in to be able to modify icons that are
displayed in Solution Explorer based on the file's status.

So far I've been able to retrieve data from Solution Explorer using the
UIHierarchy and related objects. Those give me access to the contents,
but not to the actual presentation. So basically, in my add-in I can
browse through the Solution Explorer and do things like save, delete,
etc... But when it comes to actually being able to modify what is
displayed on it, I can't seem to be able to do this.

Does anyone have any clue as to how I might be able to gain access to
the visual aspects of the solution explorer, and do things like putting
overlays over the current icons? If modifying the icons is too
difficult, then perhaps there is a way I could modify the text? So for
example, if I have a file in my Solution Explorer called Connect.cs, and
my version control plug-in is running, I could just change the actual
text of the file to read something like "Connect.cs [Conflict]" if that
file is in conflict state.

Any help on this would be greatly appreciated.

- Max
Nov 17 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Max Khitrov <ma*@mxserve.net> wrote:
I'm working on a VS .NET add-in that will allow developers to use
Subversion software from within the IDE (much like Source Safe).
Ideally, I would like for my plug-in to be able to modify icons that are
displayed in Solution Explorer based on the file's status.

So far I've been able to retrieve data from Solution Explorer using the
UIHierarchy and related objects. Those give me access to the contents,
but not to the actual presentation. So basically, in my add-in I can
browse through the Solution Explorer and do things like save, delete,
etc... But when it comes to actually being able to modify what is
displayed on it, I can't seem to be able to do this.

Does anyone have any clue as to how I might be able to gain access to
the visual aspects of the solution explorer, and do things like putting
overlays over the current icons? If modifying the icons is too
difficult, then perhaps there is a way I could modify the text? So for
example, if I have a file in my Solution Explorer called Connect.cs, and
my version control plug-in is running, I could just change the actual
text of the file to read something like "Connect.cs [Conflict]" if that
file is in conflict state.

Any help on this would be greatly appreciated.


I'd suggest having a look at an existing Subversion add-in such as
ankhsvn: http://ankhsvn.tigris.org/

(You might also consider either contributing to that project or a
similar one rather than re-inventing the wheel - but that depends on
your reasons for doing it. If it's for the investigation side of things
as much as anything else, it doesn't matter at all.)

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 17 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.