[Qt-interest] 答复: capture screen
Carsten Breuer
CarstenBreuerQt at textwork.de
Tue Jun 15 23:51:43 CEST 2010
Hi Scott,
hi all,
> However, when you have a function isHidden(), and inside the class you store a variable to store if its hidden, and you call it isHidden, without a prefix (f,s, m_ etc etc )
>
> Your function will have to look like..
> bool className::isHidden() const
> {
> return this->isHidden;
> }
Right. I like the microsoft approach very much and use it
for all my classes. So all members are prefixed with a m_.
All pointers are prefixed with m_p_.
> Frankly, I HATE in Qt where they do this, and it gets done a ton.. But Ive learned to live with it...
> In my view, The formatting of function names and methods should be different then member variables for just this reason.
Your are perfectly right. I have also my problems with
the QT naming conventions, because i use:
loadFromFile <-- Private or protected function.
LoadFromFile <-- Public function.
Best Regards,
Carsten
>
> Scott
More information about the Qt-interest-old
mailing list