What is the most concise (yet descriptive) way of naming a subclass that only add a specific minor thing to the parent? I encountered this case a lot in WPF, where sometime I have to add a small functionality to an out-of-the-box control for specific cases.Example: TreeView doesn't change the SelectedItem on right-click, but I have to make one that does in my application. Some possible names are TreeViewThatChangesSelectedItemOnRightClick (way too wordy andmaybe difficult to read because there is so many words concantenatedtogether)TreeView_SelectedItemChangesOnRightClick (slightlymore readable, but still too wordy and the underscore also breaks the normalconvention for class names)TreeViewThatChangesSIOnRC (non-obviousacronym), ExtendedTreeView (more concise, but doesn't describe whatit is doing. Besides, I already found a class called this in thelibrary, that I don't want to use/modify in my application).LouisTreeView, MyTreeView, etc. (doesn't describe what it is doing).It seems that I can't find a name which sounds right. What do you do in situation like this?
How to name an subclass that add a minor, detailed thing?
.net;coding style;naming;wpf;class design
If your application is supposed to use both the original, non-right-sensitive version and your own improved version, then the name absolutely has to express  what the derived class does. Otherwise everyone navigating the code base will go nuts understanding what the difference is and where it applies or not. Something like RightSensitiveTreeView is probably your best bet, even though it is already clumsy and will become much more clumsy if you ever need to express more than one extended behaviour.But if you use the extended version exclusively, there is little harm in using a euphonious, even proud name like LouisTreeView - it will stay accurate even if you add more enhancements later, since those presumably will also be used everywhere. The only thing you should not do is reuse the original name exactly and disambiguate by putting it into a different package path. That is just asking for confusion.(Disclaimer: proverbially, there are only two really hard things in computer science - cache invalidation and naming things. This is my opinion, but people will probably come forward with very different views.)