[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    Re: [PyQt] Qt v5.9.2 Support
From:       Phil Thompson <phil () riverbankcomputing ! com>
Date:       2017-10-31 15:26:05
Message-ID: D3846BB3-6ECF-4188-94D8-911636D3B73C () riverbankcomputing ! com
[Download RAW message or body]

On 15 Oct 2017, at 11:31 am, Florian Bruhin <me@the-compiler.org> wrote:
> 
> On Sun, Oct 15, 2017 at 10:20:15AM +0000, Phil Thompson wrote:
> > > > There are some changes in the conversions of enums which means that
> > > > invalid values can now raise an exception. If you are using correct
> > > > values then you shouldn't see any difference.
> > > 
> > > I'm not sure I follow - can you show an example of a line which didn't
> > > raise an exception before but does now?  Something like Qt.Alignment(1337)?
> > > Or passing a value which isn't in that enum to a method taking an enum?
> > 
> > Yes, both of those.
> 
> What about things like Qt::ItemDataRole which has a range (starting with
> Qt::UserRole) for custom values? If I'm reading this right, something like
> calling .data(Qt.UserRole + 1) on a QStandardItemModel would break, but really
> shouldn't.

Sorry, my mistake. The only change in enum behaviour is that an invalid integer that \
will overflow will now raise an exception.

Phil
_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
https://www.riverbankcomputing.com/mailman/listinfo/pyqt


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic