Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Visual Studio and custom User Type Names  (Read 3650 times)

0 Members and 1 Guest are viewing this topic.

Jove

  • Full Member
  • ***
  • Posts: 114
    • View Profile
    • http://www.jestofevekites.com/
Visual Studio and custom User Type Names
« on: December 26, 2011, 09:47:16 pm »
Guys, has anyone sucessfully managed to make your own type names in VS (2010) show up as blue?

You know, like defining a Uint8 or a sf::Vector2f so they appear as blue in your project like the standard types do?

It's only a little thing, but it would make the code that much more readable, don't you agree?

I've searched the topic way back and again tonight, still can't find a satisfactory solution. I'm not the best programmer, but I'm a sucker for clean, readable formatting.
{much better code}

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Visual Studio and custom User Type Names
« Reply #1 on: December 26, 2011, 10:30:57 pm »
I don't know if it's still valid for Visual Studio 2010, but with Visual Studio 2008 you can add your own types to the usertype.dat file.

You can also try the Visual Assist plugin, if I remember correctly it highlights all user types automatically.
Laurent Gomila - SFML developer

Jove

  • Full Member
  • ***
  • Posts: 114
    • View Profile
    • http://www.jestofevekites.com/
Visual Studio and custom User Type Names
« Reply #2 on: December 26, 2011, 10:50:06 pm »
Yeah, I have come across the usertype.dat file on my travels, but this seems to be related to older versions; can't find the file on newer versions.

I will check out the plugin you mentioned in case that does the job.
{much better code}

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Visual Studio and custom User Type Names
« Reply #3 on: December 27, 2011, 12:57:06 am »
You have to pay for Visual Assist, but it's worth the money for sure. It offers extremely nice features and refactoring tools which make boilerplate coding far more comfortable :)
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

Silvah

  • Guest
Visual Studio and custom User Type Names
« Reply #4 on: December 27, 2011, 05:28:13 pm »
Quote from: "Laurent"
I don't know if it's still valid for Visual Studio 2010, but with Visual Studio 2008 you can add your own types to the usertype.dat file.
It looks like it's not, VS 2010 apparently ignores this file entirely.

Quote from: "Nexus"
You have to pay for Visual Assist, but it's worth the money for sure.
It would be, if you couldn't have these features for free :P

It's worth noting that VA X (and all VS plugins in general) requires least VS Professional, it won't work in the Express edition.

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Visual Studio and custom User Type Names
« Reply #5 on: December 27, 2011, 05:56:47 pm »
Quote from: "Silvah"
It would be, if you couldn't have these features for free :P
I have used Eclipse for Java some time ago, and the eternal loading times and delays annoyed me constantly. Maybe this has been improved meanwhile. I don't know how well Eclipse's C++ support is and if it really offers the same features as Visual Studio + Visual Assist X (e.g. debugger), maybe I'll test it one day... :)
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

 

anything