Reputation: 4364
By default, Visual Studio only supports the inclusion of either a .h or .cpp file when creating a new class. I understand, though, that I can easily choose .h and rename it to .hpp to achieve the new extension that I am looking for. However, I would like to create a new template file type for this list showing .hpp files as an option so that I can easily choose such a file from the list of .h and .cpp files. Here is a picture of the visual studio file chooser:
What is the best way to add my new .hpp file type?
Upvotes: 2
Views: 4950
Reputation: 4364
I found a quick and dirty way to accomplish this; it is actually quite simple. Just create a blank .hpp file in Notepad++(So you get the correct extensions and stuff) and then drop it right into this folder:
It doesnt look as pretty as the other ones, because they are apparently pulling information from somewhere else to rename the files...but it works!
Here is what the finished product looks like(No Idea where the black icon came from)
Upvotes: 2