<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">pt., 16 paź 2026 o 15:14 Phil Thompson <<a href="mailto:phil@riverbankcomputing.com">phil@riverbankcomputing.com</a>> napisał(a):<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 16/10/2026 13:45, Grzegorz Bokota wrote:<br>
> Will the solution also contain also change of naming in type stubs to <br>
> not<br>
> use a0, a1 etc but use proper descriptive names like "watched" and <br>
> "event"<br>
> from Qt documentation?<br>
> <a href="https://doc.qt.io/qt-6/qobject.html#eventFilter" rel="noreferrer" target="_blank">https://doc.qt.io/qt-6/qobject.html#eventFilter</a> bool<br>
> QObject::eventFilter(QObject *watched, QEvent *event)<br>
<br>
They will continue to use generated names but the arguments will be <br>
positional only so the names will never be used.</blockquote><div><br></div><div>Thanks, change of name will benefit in more readable documentation, but it still could depend more on just qt6 documentation. </div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
> Is it also possible to stop providing annotations like QObject | None <br>
> for<br>
> call parameters, even if Qt documentation suggests that it can't be <br>
> None<br>
> (also when checking PySide6 documentation, they provide plan QObject)?<br>
> I see that it comes from Qt convention to pass objects as pointers, not<br>
> references, but in reality I don't seen calling an event handler with <br>
> None<br>
> in place of Event. But type checkers still complain that the None case <br>
> is<br>
> not supported, which leads to writing obsolete code.<br>
<br>
I don't understand that last sentence. The stubs reflect the <br>
implementation and the Qt API allows you to pass None/NULL, whether or <br>
not it's a good idea. The /DisallowNone/ argument annotation can be used <br>
but that requires every call to be analysed individually.</blockquote><div><br></div><div>Does Qt itself support of `QWidget::mouseMoveEvent` with a null pointer? </div><div>I might have got such an event trigger in my Qt application? </div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Phil<br></blockquote><div><br></div><div>Regards,</div><div>Grzegorz </div></div></div>