History around Pascal Casing and Camel Casing


In the initial design of the Framework we had hundreds of hours of debate about naming style.  To facilitate these debates we coined a number of terms.  With Anders Heilsberg (the original designer of Turbo Pascal) a key member of the design team, it is no wonder that we chose the term Pascal Casing for the casing style popularized by the Pascal programming language.  We were somewhat cute in using the term camelCasing for the casing style that looks something like the hump on a camel.  We used the term SCREAMING CAPS to indicate an all upper case style. Luckily this style (and name) did not survive in the final guideline.


 


Pascal Casing convention capitalizes the first character of each word (including acronyms over two letters in length) as in the following examples.


PropertyDescriptor


HtmlTag



Camel Casing convention capitalizes the first character of each word except the first word, as in the following examples.


propertyDescriptor


ioStream


htmlTag

Comments (16)

  1. Phil Scott says:

    What about the Finger_Breaking_Underscore style?

  2. Brad Abrams says:

    Oh yea, We_Should_Add_That_One…

  3. Johnny Hall says:

    And don’t forget the SCREAMING_AS_YOUR_FINGERS_BREAK style, which used to be used for constants. 🙂

  4. Alex Odintsov says:

    Is it confidential information the naming convention that you guy came up with? Can it be viewed somewhere?

  5. Louis Parks says:

    Why Pascal? It would have made more sense to call them title caps (like nearly every word processor does).

  6. Brad Abrams says:

    Well, Pascal popularized the casing style, but I am open to changing it if folks think "title caps" is clearer.

  7. Johnny Hall says:

    Leave it as Pascal case. Everyone knows it now. I don’t see the need to change.

  8. And the random casing "standard" used for acronyms? What will be the name for that style? "FeelsGOoD" casing?

  9. Brad Abrams says:

    Frank, I take you you don’t like the rule where one and two letter acronyms are upper and three or more letters are Pascal?

  10. Brad, from what I have seen, with acronyms, anything goes. I assumed there is no rule. Even if API designers use your rule, how will users remember the rule when typing full bore? Not everyone uses intellisense all the time.

  11. Ken Brubaker says:

    For my own reference, I thought I’d compile a quick list of design guidelines added by Brad Abrams, et al.

  12. AML says:

    I’m sad that you did not appear to consider the newly popular hAx0rC4$1nG

  13. John Bennett says:

    What is the verdict on ID/Id?

    Is it a two-letter acronym, hence ID?

    (e.g., System.Web.UI.Control.ID and other classes in System.Web)

    Or is it a word all on its own (let’s not get into Freud…), hence Id?

    (e.g., System.Messaging.Message.Id and other classes in System.Messaging and System.Security.Cryptography)