Re: [Development] Undeprecating QPointer

2012-03-02 Thread Olivier Goffart
On Friday 02 March 2012 10:27:56 Thiago Macieira wrote:
 Hello
 
 QPointer was ported to a QWeakPointer backend and deprecated early in Qt 5
 history. However, QPointer is used throughout our code and, I can expect, in
 user code too. Replacing it with QWeakPointer is just monkey work, adding
 .data() everywhere and buying us no better safety (because no one will
 bother to verify that the pointer could be got at that point). After the
 port to QWeakPointer, QPointer is no longer slow either.
 
 I'd like to suggest we un-deprecate it and bring it back to full status.

I agree.
I have been trying to compile qtbase without the deprecated symbols, and two 
issues remains that i could not solve: QPointer, and QWheelEvent's deprecated 
member.

For QPointer, the task is indeed to big and I think it is best not to 
deprecate it.

The alternative would be to add operator- and operator T* to QWeakPointer, 
which would allow do do simply s/QPointer/QWeakPointer/g
I personaly beleive this would actually be the best option.

 At the same time, I'd like to suggest we discourage using QWeakPointer for
 tracking QObjects, instead leaving it to its original purpose of being the
 weak reference counterpart to QSharedPointer.

Indeed, we should not have two class with the same purpose. So if QPointer 
stays, QWeakPointer have to leave.

 I'm not going as far as suggesting we deprecate the QWeakPointer(QObject*)
 constructor yet. I need to do a bit of research on how a future
 QSharedPointer  QWeakPointer with full enable_shared_from_this and
 QObject tracking would look like.

One problem: QPointer use QWeakPointer inline, meaning it can hardly be done 
without QWeakPointer in the future.


___
Development mailing list
Development@qt-project.org
http://lists.qt-project.org/mailman/listinfo/development


[Development] QDoc can't ignore Q_PROPERTY

2012-03-02 Thread Denis Shienkov
Hi all.

Is it possible to ignore the macro Q_PROPERTY when generating documentation 
QDoc?

If I add  *.qdocconf
..
Cpp.ignoretokens += \
Q_PROPERTY
..
or
..
Cpp.ignoredirectives += \
Q_PROPERTY
..
it has no effect.

The fact is that if the names of class methods and the same properties names - 
then QDoc ignores the description for the methods.

Is there any solution for this?

Best regards,
Denis

___
Development mailing list
Development@qt-project.org
http://lists.qt-project.org/mailman/listinfo/development


Re: [Development] QDoc can't ignore Q_PROPERTY

2012-03-02 Thread Thiago Macieira
On sexta-feira, 2 de março de 2012 18.01.15, Denis Shienkov wrote:
 The fact is that if the names of class methods and the same properties names
 - then QDoc ignores the description for the methods.

That's intentional. You document the property. The getter and setter methods
do not need to be documented.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
 Intel Sweden AB - Registration Number: 556189-6027
 Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden


signature.asc
Description: This is a digitally signed message part.
___
Development mailing list
Development@qt-project.org
http://lists.qt-project.org/mailman/listinfo/development