You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can create dedicated wrapper QObjects for any C++ class. This is done by deriving from PythonQtCppWrapperFactory
@@ -307,6 +329,8 @@ QtCore.QDate.currentDate()
307
329
308
330
# enum value
309
331
QtCore.QFont.UltraCondensed
332
+
# or, alternatively
333
+
QtCore.QFont.Stretch.UltraCondensed
310
334
311
335
\endcode
312
336
@@ -453,11 +477,11 @@ yourCpp = None
453
477
454
478
\page Building Building
455
479
456
-
PythonQt requires at least Qt 4.6.1 (for earlier Qt versions, you will need to run the pythonqt_generator, Qt 4.3 is the absolute minimum) and Python 2.6.x/2.7.x or Python 3.3 (or higher).
480
+
PythonQt requires at least Qt 5.0 and Python 2.7.x or Python 3.6 (or higher).
457
481
To compile PythonQt, you will need a python developer installation which includes Python's header files and
458
482
the python2x.[lib | dll | so | dynlib].
459
483
The recommended way to build PythonQt is to use the QMake-based *.pro file.
460
-
The build scripts a currently set to use Python 2.6.
484
+
The build scripts are currently set to use Python 3.10 by default.
461
485
You may need to tweak the \b build/python.prf file to set the correct Python includes and libs on your system.
462
486
463
487
\subsection Windows
@@ -468,21 +492,20 @@ the python2x.[lib | dll | so | dynlib].
468
492
Python yourself, using your compiler.
469
493
470
494
To build PythonQt, you need to set the environment variable \b PYTHON_PATH to point to the root
471
-
dir of the python installation and \b PYTHON_LIB to point to
472
-
the directory where the python lib file is located.
495
+
dir of the python installation and \b PYTHON_VERSION should state the used Python version.
473
496
474
497
When using the prebuild Python installer, this will be:
475
498
476
499
\code
477
-
> set PYTHON_PATH = c:\Python26
478
-
> set PYTHON_LIB = c:\Python26\libs
500
+
> set PYTHON_PATH = c:\Python310
501
+
> set PYTHON_VERSION = 3.10
479
502
\endcode
480
503
481
504
When using the python sources, this will be something like:
482
505
483
506
\code
484
-
> set PYTHON_PATH = c:\yourDir\Python-2.6.1\
485
-
> set PYTHON_LIB = c:\yourDir\Python-2.6.1\PCbuild8\Win32
507
+
> set PYTHON_PATH = c:\yourDir\Python-3.10.12\
508
+
> set PYTHON_VERSION = 3.10
486
509
\endcode
487
510
488
511
To build all, do the following (after setting the above variables):
@@ -522,7 +545,7 @@ the python2x.[lib | dll | so | dynlib].
522
545
You should add PythonQt/lib to your LD_LIBRARY_PATH so that the runtime
523
546
linker can find the *.so files.
524
547
525
-
\subsection MacOsX
548
+
\subsection MacOS
526
549
527
550
On Mac, Python is installed as a Framework, so you should not need to install it.
0 commit comments