klayout/scripts
Matthias Köfferlein b968f2b47f
#730: providing a new Qt module named QtUiTools for QUiLoader class s… (#735)
* #730: providing a new Qt module named QtUiTools for QUiLoader class support.

* Fixed a compile error on Mac

* Added QtUiTools to some more places

* Fixed a linker issue in the QtUiTools Python lib

* On occasion fixed a infinite recursion problem in the debugger

The recursion happened because by mistake I instantiated a
QApplication inside an in-application Python script. This
crashed the debugger due to infinite recursion. This is not
a real use case but to prevent similar issues, a recursion
sentinel was added.

* Removed QCoreApplication#notify from script bindings

Reasoning: "notify" made standalone scripts using QApplication and
QUiLoader virtually impossible.

Problem description:
- When a QApplication object is instantiated, e.g. in Python, the Qt binding
  will install reimplementation hooks as the object may be dynamically
  extended.
- A notify is virtual this means the *every* "notify" call in the application
  is routed through the interpreter.
- For one thing this will slow down the application
- But as "notify" is called a zillion times this has more than this side effect.
- Specifically "notify" is called from within the QWidget constructor to
  indicate a new widget. Then, if a QDialog for example is instatiated, it's
  base class constructor will call "notify" when the object isn't ready yet.
- This has another severe side effect: as the object isn't ready yet, it gets
  registered in the Python space with the wrong class and QDialog is not visible
  as such.

To mitigate these problems, the most efficient solution is to disable "notify"
in general. There is hardly any use case in a script environment (in C++,
apart from hacking the only reasonable use case is exception handling, but
this does not apply to scripts). For providing the call functionality of
"notify" you should better use "postEvent" or "sendEvent" anyway.

So farewell QCoreApplication.notify ...

* Fixed python test for QtUiTools module

* Fixed UiTools test on Qt4 - QUiLoader needs an application object

Co-authored-by: Kazunari Sekigawa <kazunari.sekigawa@gmail.com>
2021-02-25 21:29:21 +01:00
..
deb-data Removed a .swp file checked in by mistake 2019-03-24 21:24:45 +01:00
mkqtdecl4 #730: providing a new Qt module named QtUiTools for QUiLoader class s… (#735) 2021-02-25 21:29:21 +01:00
mkqtdecl5 #730: providing a new Qt module named QtUiTools for QUiLoader class s… (#735) 2021-02-25 21:29:21 +01:00
mkqtdecl_common Updated copyright to 2021 2021-01-05 22:57:48 +01:00
rpm-data WIP: fixed dependencies 2020-02-21 23:51:04 +01:00
compile_glyphs.rb Fixed issue-241 (no TextGenerator.default_generator for pymod) 2019-03-21 23:11:52 +01:00
create_drc_samples.rb Some bug fixes, doc update, test updates. 2021-01-16 00:32:06 +01:00
deploy-win-mingw.sh Fixed #449 (added styles plugin folder) 2019-12-15 16:26:33 +01:00
extract_doc.rb Doc update, fixed DRC's 'switch' function 2021-01-15 00:31:26 +01:00
extract_user_doc.rb Updated Jenkinsfile and added user doc generation scripts. 2018-06-26 07:23:44 +02:00
extract_user_doc.sh Fixed doc generation script: needs a clean distribution dir. 2018-07-29 15:05:06 +02:00
jhf2c.pl Fixed #477 2020-01-23 18:38:41 +01:00
klayout-inst.nsis Fixed #449 (added styles plugin folder) 2019-12-15 16:26:33 +01:00
klayoutrc_drc_samples Updated DRC doc and enhanced generation of DRC doc somewhat (bigger images, no exaes etc.) 2020-09-16 23:45:26 +02:00
make_drc_lvs_doc.sh Provide new 'align' feature in LVS for automatic circuit flattening. 2019-07-23 01:12:12 +02:00
makedeb.sh Dependeny list for Ubuntu 20 2020-05-30 22:41:13 +02:00
mk_hershey_fonts.sh Fixed #477 2020-01-23 18:38:41 +01:00
mkqtdecl.sh #730: providing a new Qt module named QtUiTools for QUiLoader class s… (#735) 2021-02-25 21:29:21 +01:00