[PyQt] bug in QJSEngine
Florian Bruhin
me at the-compiler.org
Sun Mar 22 20:55:23 GMT 2015
* redstone-cold <redstone-cold at 163.com> [2015-03-22 12:35:43 +0800]:
> code:
> https://bpaste.net/show/f60deff86d2b
> C++ QJSEngine evaluate the JavaScript code well,Chrome JavaScript console also can evaluate the code, but PyQt5 QJSEngine just throw out exception :SyntaxError: Syntax error
>
>
> hope to fix the bug.
This is actually a bug in your code.
If you use backslashes in strings, you have to escape them using \\
(just line in C++ too!), or use a raw string using r"""...""".
Florian
--
http://www.the-compiler.org | me at the-compiler.org (Mail/XMPP)
GPG: 916E B0C8 FD55 A072 | http://the-compiler.org/pubkey.asc
I love long mails! | http://email.is-not-s.ms/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20150322/d0828f95/attachment.sig>
More information about the PyQt
mailing list