aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2019-06-19 10:55:11 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2019-06-19 10:56:21 +0200
commit14384c4436ae14016af50359ff9029cd939d2364 (patch)
treeb4ed8445f936dfc79d78bfe774927291dbc43868 /sources/pyside2
parent6c65516ca994e4fa024222e8861c8cb6fad41e48 (diff)
parentc0f118e4106b5d38cd828425b6533147f111cdd4 (diff)
Merge remote-tracking branch 'origin/5.13' into dev
Diffstat (limited to 'sources/pyside2')
-rw-r--r--sources/pyside2/PySide2/glue/qtcore.cpp13
-rw-r--r--sources/pyside2/doc/_themes/pysidedocs/static/pyside.css1892
-rw-r--r--sources/pyside2/doc/_themes/pysidedocs/static/pysidedocs.css477
-rw-r--r--sources/pyside2/doc/_themes/pysidedocs/theme.conf2
-rw-r--r--sources/pyside2/doc/deployment-cxfreeze.rst30
-rw-r--r--sources/pyside2/doc/deployment-fbs.rst37
-rw-r--r--sources/pyside2/doc/deployment-pyinstaller.rst80
-rw-r--r--sources/pyside2/libpyside/pyside.cpp56
-rw-r--r--sources/pyside2/tests/QtWidgets/application_test.py8
-rw-r--r--sources/pyside2/tests/pysidetest/CMakeLists.txt1
-rw-r--r--sources/pyside2/tests/pysidetest/constructor_properties_test.py64
11 files changed, 2087 insertions, 573 deletions
diff --git a/sources/pyside2/PySide2/glue/qtcore.cpp b/sources/pyside2/PySide2/glue/qtcore.cpp
index fde016548..9db4e2e82 100644
--- a/sources/pyside2/PySide2/glue/qtcore.cpp
+++ b/sources/pyside2/PySide2/glue/qtcore.cpp
@@ -1211,8 +1211,8 @@ QByteArray ba(1 + int(%2), char(0));
// @snippet qcryptographichash-adddata
// @snippet qsocketnotifier
-Shiboken::AutoDecRef socket(%PYARG_1);
-if (!socket.isNull()) {
+PyObject *socket = %PYARG_1;
+if (socket != nullptr) {
// We use qintptr as PyLong, but we check for int
// since it is currently an alias to be Python2 compatible.
// Internally, ints are qlonglongs.
@@ -1340,18 +1340,17 @@ if (!PyTuple_SetItem(empty, 0, PyList_New(0))) {
// @snippet qcoreapplication-2
// @snippet qcoreapplication-instance
-QCoreApplication *app = QCoreApplication::instance();
PyObject *pyApp = Py_None;
-if (app) {
+if (qApp) {
pyApp = reinterpret_cast<PyObject*>(
- Shiboken::BindingManager::instance().retrieveWrapper(app));
+ Shiboken::BindingManager::instance().retrieveWrapper(qApp));
if (!pyApp)
- pyApp = %CONVERTTOPYTHON[QCoreApplication*](app);
+ pyApp = %CONVERTTOPYTHON[QCoreApplication*](qApp);
// this will keep app live after python exit (extra ref)
}
// PYSIDE-571: make sure that we return the singleton "None"
if (pyApp == Py_None)
- Py_DECREF(MakeSingletonQAppWrapper(0)); // here qApp and instance() diverge
+ Py_DECREF(MakeSingletonQAppWrapper(nullptr)); // here qApp and instance() diverge
%PYARG_0 = pyApp;
Py_XINCREF(%PYARG_0);
// @snippet qcoreapplication-instance
diff --git a/sources/pyside2/doc/_themes/pysidedocs/static/pyside.css b/sources/pyside2/doc/_themes/pysidedocs/static/pyside.css
new file mode 100644
index 000000000..956e3113b
--- /dev/null
+++ b/sources/pyside2/doc/_themes/pysidedocs/static/pyside.css
@@ -0,0 +1,1892 @@
+@import url('cookie-confirm.css') screen;
+
+/* -- admonitions -- */
+
+div.admonition {
+ margin: 1em 0 1em;
+ padding: 7px;
+}
+
+div.admonition dt {
+ font-weight: bold;
+}
+
+div.admonition dl {
+ margin-bottom: 0;
+}
+
+p.admonition-title {
+ margin: 0px 10px 5px 0px;
+ font-weight: bold;
+}
+.body {
+ width: 100%
+}
+.bodywrapper .admonition p.admonition-title {
+ margin-bottom:5px
+}
+
+.bodywrapper .admonition p {
+ margin:0
+}
+
+div.body p.centered {
+ text-align: center;
+ margin-top: 25px;
+}
+
+div.warning {
+ background-color: #ffe4e4;
+ border: 1px solid #f66;
+}
+
+div.seealso {
+ background-color: #ffffcc;
+ border: 1px solid #ffff66;
+}
+
+div.note {
+ border: 1px solid #e3e3e3;
+}
+
+table.docutils {
+ margin-right: auto;
+ margin-bottom: 10px;
+ border: none;
+ width: initial;
+}
+
+table.docutils.colwidths-given td {
+ float: none;
+}
+
+table.docutils th,
+table.docutils td {
+ padding-left:0;
+ border: none;
+}
+
+table.docutils td ul {
+ margin:0
+}
+
+table.docutils td ul > li {
+ margin: 0 0 0.5em;
+}
+h2 em {
+ float: right;
+ font-size: 10px;
+ position: relative;
+ top: -20px;
+}
+
+.document {
+ padding-bottom: 20px;
+}
+
+.documentwrapper {
+ margin-left: 255px;
+}
+
+.body blockquote {
+ border: none;
+ padding-left: 0;
+ margin-bottom: 2em;
+}
+
+.sphinxsidebar {
+ float: left;
+ width: 186px;
+ padding: 25px;
+ text-align: left;
+ background-color: #fff;
+}
+
+.sphinxsidebar ul {
+ padding: 0px;
+ margin: 0px;
+ list-style-position: inside;
+}
+
+.sphinxsidebar > ul {
+ padding: 0px;
+ margin: 0px;
+}
+
+.sphinxsidebar ul li li {
+ margin-left: 10px;
+ padding: 0px;
+ font-size: 0.95em;
+}
+
+.sphinxsidebar ul a,
+.sphinxsidebar p.topless a {
+ word-break: break-word;
+}
+
+.sphinxsidebar h3, .sphinxsidebar h3 a {
+ color: #333;
+}
+
+.sphinxsidebar p.topless {
+ margin: 1em 0 1em;
+}
+
+.pysidetoc ul {
+ list-style: none;
+ padding: 0px;
+ margin: 0px;
+}
+
+.pysidetoc em {
+ font-style: normal;
+}
+
+.pysidetoc strong {
+ display: block;
+ padding: 5px;
+ margin: 0 10px 10px 0;
+ border: 1px solid #ddd;
+ background-color: #f4f4f4;
+ -moz-border-radius:6px;
+ -webkit-border-radius:6px;
+ -khtml-border-radius:6px;
+}
+
+.section .docutils.container td {
+ float:left;
+}
+
+.hide {
+ display: none;
+}
+
+/* copy-notice */
+.document + p {
+ margin-left: 255px;
+ width: 70%;
+ font-size: 0.75em;
+ margin: 0 35px 15px 280px;
+}
+
+#searchbox {
+ border-top: 1px solid #989898;
+ padding-top: 10px;
+ margin-left: -10px;
+ margin-right: -10px;
+ padding-left: 10px;
+ padding-right: 10px;
+}
+
+#search_button {
+ border: 1px solid #3A393A;
+ background-color: #3A393A;
+ color: white;
+ cursor: pointer;
+ -moz-border-radius: 5px;
+ -webkit-border-radius: 5px;
+ -khtml-border-radius: 5px;
+
+}
+
+form {
+ margin: 0px;
+ padding: 0px;
+}
+
+#searchbox h3 {
+ padding: 10px 0 0 0;
+ margin-bottom: 5px;
+}
+
+/* search field */
+form #q {
+ width: 136px;
+ /* height: 22px; */
+ /* border: none; */
+ margin: 0px;
+ -moz-border-radius: 5px;
+ -webkit-border-radius: 5px;
+ -khtml-border-radius: 5px;
+ margin-top: 2px;
+ padding: 4px;
+ line-height: 22px;
+}
+
+#search-results h2 {
+ display: none;
+}
+
+#search-results h2 {
+ display: none;
+}
+
+#search-results ul.search {
+ margin: 0px;
+ padding: 0px;
+}
+
+ul.search div.context {
+ padding-left: 40px;
+}
+
+#installation td {
+ text-align: center;
+ font-weight: bold;
+}
+
+em {
+ color: inherit;
+ font-style:italic;
+}
+
+/******** REL bar *********/
+
+.related {
+ display: inline;
+}
+
+.related h3 {
+ display: none;
+}
+
+.align-center {
+ text-align: center;
+}
+
+.contentstable {
+ width: 100%;
+}
+
+.contentstable td {
+ padding-left: 30px;
+ vertical-align: top;
+}
+
+p.biglink a {
+ font-size: 20px;
+}
+
+dt:target, .highlight {
+ background-color: #fbe54e;
+}
+
+p.highlight-link {
+ margin-top: 10px;
+ font-size: 0.8em;
+}
+
+#synopsis table, table.field-list {
+ margin: 1em 0 1em 0;
+}
+
+table.field-list tr {
+ text-align: left;
+}
+
+tt.descname {
+ font-size: 120%;
+ font-weight: bold;
+}
+
+#functions ul, #virtual-functions ul, #slots ul, #signals ul, #static-functions ul {
+ list-style: none;
+ margin: 0px;
+ padding: 10px;
+ border: 1px solid #ddd;
+ background-color: #f4f4f4;
+ -moz-border-radius:10px;
+ -webkit-border-radius:10px;
+ -khtml-border-radius:10px;
+}
+
+#synopsis span.pre {
+ color: #009491;
+ font-weight: bolder;
+}
+
+#detailed-description .class dt,
+#detailed-description .method dt,
+#detailed-description .staticmethod dt,
+#detailed-description .attribute dt {
+ margin: 0px;
+ margin-bottom: 10px;
+ padding: 10px;
+ border: 1px solid #ddd;
+ background-color: #f4f4f4;
+ -moz-border-radius:10px;
+ -webkit-border-radius:10px;
+ -khtml-border-radius:10px;
+}
+
+.document dl.attribute,
+.document dl.class,
+.document dl.method,
+.document dl.staticmethod {
+ margin-top: 2em;
+}
+
+.document dl.attribute dd,
+.document dl.class dd,
+.document dl.method dd,
+.document dl.staticmethod dd {
+ padding-left: 1em;
+}
+
+/* Qt theme */
+#navbar {
+ position:fixed;
+ top:0;
+ left:0;
+ z-index:100;
+ background:#fff;
+ width:100%
+}
+#navbar .container, .fixed .container {
+ max-width:1280px;
+ margin:0 auto;
+ padding:0 3.9%; /* 0? */
+ position:relative;
+ overflow:visible
+}
+#navbar .navbar-header {
+ position:relative
+}
+#menuextras li a:hover span {
+ color: #41cd52;
+}
+/* new header */
+#mm-wrap, #mm-wrap #mm-helper,
+#mm-wrap #mm-helper li.mm-item,
+#mm-wrap #mm-helper a.mm-link {
+ -moz-transition: none;
+ -o-transition: none;
+ -webkit-transition: none;
+ transition: none;
+ -webkit-border-radius: 0 0 0 0;
+ -moz-border-radius: 0 0 0 0;
+ -ms-border-radius: 0 0 0 0;
+ -o-border-radius: 0 0 0 0;
+ border-radius: 0 0 0 0;
+ -webkit-box-shadow: none;
+ -moz-box-shadow: none;
+ -ms-box-shadow: none;
+ -o-box-shadow: none;
+ box-shadow: none;
+ background: none;
+ border: 0;
+ bottom: auto;
+ box-sizing: border-box;
+ clip: auto;
+ color: #090e21;
+ display: block;
+ float: none;
+ font-family: inherit;
+ font-size: 14px;
+ height: auto;
+ left: auto;
+ line-height: 1.7;
+ list-style-type: none;
+ margin: 0;
+ min-height: 0;
+ opacity: 1;
+ outline: none;
+ overflow: visible;
+ padding: 0;
+ position: relative;
+ right: auto;
+ text-align: left;
+ text-decoration: none;
+ text-transform: none;
+ top: auto;
+ vertical-align: baseline;
+ visibility: inherit;
+ width: auto;
+}
+#mm-wrap #mm-helper {
+ visibility:visible;
+ text-align:right;
+ padding:0 0px 0 0px
+}
+#navbar #mm-wrap #mm-helper li.mm-item {
+ border-right:solid #f3f3f4 1px;
+ padding-right:30px;
+ padding-left:30px
+}
+#navbar #mm-wrap #mm-helper li.mm-item > a:hover {
+ opacity: .5
+}
+#mm-wrap #mm-helper > li.mm-item {
+ margin:0 0 0 0;
+ display:inline-block;
+ height:auto;
+ vertical-align:middle
+}
+#navbar #mm-wrap #mm-helper li.mm-item:nth-child(3) {
+ border-right:0
+}
+#mm-wrap #mm-helper a.mm-link {
+ cursor: pointer
+}
+@media (max-width: 1279px) {
+ #navbar {
+ padding:0;
+ position:relative;
+ }
+ #navbar .container {
+ max-width:100%
+ }
+ .container {
+ padding:0 2%
+ }
+}
+#navbar .navbar-oneQt {
+ display:inline;
+ float:left;
+ width:31px;
+ color:#41cd52
+}
+#navbar .navbar-oneQt:before {
+ content:attr(data-icon);
+ position:absolute;
+ top:14px;
+ left:0;
+ color:#41cd52;
+ font-family:'Qt Icons';
+ line-height:1;
+ font-size:40px;
+ transition:all 0.3s ease-in-out;
+}
+#mm-wrap {
+ clear:both;
+ background:rgba(255, 255, 255, 0.1);
+ -webkit-border-radius:0px 0px 0px 0px;
+ -moz-border-radius:0px 0px 0px 0px;
+ -ms-border-radius:0px 0px 0px 0px;
+ -o-border-radius:0px 0px 0px 0px;
+ border-radius:0px 0px 0px 0px
+}
+#mm-wrap #mm-helper li.mm-item:last-child a {
+ background:transparent url("icon_avatar.png") 50% 50% no-repeat !important;
+ background-size:24px !important;
+ width:24px !important;
+ height:24px !important;
+}
+#navbar #mm-wrap #mm-helper li.mm-item > a {
+ opacity:1;
+ -webkit-transition:all 0.3s ease-in-out;
+ -moz-transition:all 0.3s ease-in-out;
+ -ms-transition:all 0.3s ease-in-out;
+ -o-transition:all 0.3s ease-in-out;
+ transition:all 0.3s ease-in-out;
+}
+#mm-wrap #mm-helper > li.mm-item > a.mm-link {
+ border-top:0px solid #fff;
+ border-left:0px solid #fff;
+ border-right:0px solid #fff;
+ border-bottom:0px solid #fff;
+ outline:none;
+ text-decoration:none;
+ padding:0 0 0 0;
+ line-height:70px;
+ font-weight:normal;
+ height:70px;
+ vertical-align:baseline;
+ text-align:left;
+ width:auto;
+ display:block;
+ color:#090e21;
+ text-transform:none;
+ text-decoration:none;
+ background:rgba(0, 0, 0, 0);
+ -webkit-border-radius:0px 0px 0px 0px;
+ -moz-border-radius:0px 0px 0px 0px;
+ -ms-border-radius:0px 0px 0px 0px;
+ -o-border-radius:0px 0px 0px 0px;
+ border-radius:0px 0px 0px 0px;
+ font-family:inherit;
+ font-size:14px;
+}
+/* end new header */
+@media (min-width: 1320px) {
+ .body .flowListDiv dl.flowList {
+ -webkit-column-count:3;
+ -moz-column-count:3;
+ column-count:3
+ }
+}
+@media (min-width: 1120px) {
+ #navbar.fixed {
+ -moz-box-shadow:0px 0px 8px rgba(0,0,0,0.23);
+ -webkit-box-shadow:0px 0px 8px rgba(0,0,0,0.23);
+ box-shadow:0px 0px 8px rgba(0,0,0,0.23)
+ }
+ #navbar.fixed #mm-wrap #mm-helper > li.mm-item > a.mm-link {
+ height:50px;
+ line-height:50px
+ }
+ #navbar.fixed .navbar-oneQt:before {
+ font-size:35px;
+ top:7px
+ }
+
+ .flowListDiv dl.flowList {
+ -webkit-column-count:2;
+ -moz-column-count:2;
+ column-count:2
+ }
+}
+@media (max-width: 1120px) {
+ #navbar {
+ padding:0;
+ position:relative
+ }
+ #navbar .navbar-oneQt:before {
+ left:10px
+ }
+ #navbar .container {
+ max-width:100%;
+ padding:0
+ }
+ #footerbar .container {
+ padding:0
+ }
+ body .main {
+ margin-top:0px
+ }
+ #footerbar .footer-main .footer-nav {
+ padding:3.9% 0 3.9% 3%;
+ border-bottom:1px solid #413d3b;
+ float:none;
+ display:block;
+ width:auto
+ }
+ #footerbar .footer-main .theqtcompany {
+ clear:both;
+ float:left;
+ margin:30px 0 8px 3%
+ }
+ #footerbar .footer-main .footer-social {
+ float:left;
+ padding:50px 0px 0px 3%
+ }
+ #footerbar #menu-footer-submenu {
+ clear:both;
+ float:none;
+ display:block;
+ padding:0px 0px 3.9% 3%
+ }
+ ul#menu-footer-submenu {
+ margin-left: 0
+ }
+}
+.cookies_yum {
+ background-color:#cecfd5;
+ display:none;
+ width:100%
+}
+.cookies_yum img {
+ width:25px;
+ top:6px;
+ display:inline-block;
+ position:absolute;
+ left:13px
+}
+.cookies_yum div {
+ margin:0 auto;
+ max-width:1280px;
+ min-height:30px;
+ padding:6px 0px 6px 0px;
+ position:relative
+}
+.cookies_yum p {
+ color:#09102b;
+ margin:0px;
+ font-size:0.79em;
+ display:inline-block;
+ line-height:1.2;
+ padding:0 30px 0 50px
+}
+.cookies_yum p a {
+ white-space:nowrap
+}
+.cookies_yum a:hover {
+ color:#46a2da
+}
+.cookies_yum .close {
+ width:15px;
+ height:15px;
+ background-image:url("cookiebar-x.png");
+ background-size:15px 30px;
+ background-position:top left;
+ cursor:pointer;
+ top:13px;
+ right:13px;
+ position:absolute;
+ transition:none
+}
+.cookies_yum .close:hover {
+ background-position:bottom left
+}
+#sidebar-toggle,#toc-toggle {
+ width:24px;
+ height:14px;
+ background-size:24px 28px;
+ cursor:pointer;
+ background-image:url("list_expand.png");
+ float:right
+}
+#sidebar-toggle.collapsed,
+#toc-toggle.collapsed {
+ background-position:bottom left
+}
+#sidebar-content > h2 {
+ display:none
+}
+#footerbar {
+ background:#222840;
+ color:#fff;
+ font-size: 0.9em;
+}
+#footerbar.fixed {
+ bottom:0;
+ left:0;
+ width:100%
+}
+#footerbar .footer-nav {
+ display:inline;
+ float:left
+}
+#footerbar .footer-main .footer-nav li {
+ float:left;
+ margin-right:1em
+}
+#footerbar .footer-main .footer-nav li a {
+ display:block;
+ padding:30px 0 10px 0;
+ line-height:20px;
+ height:20px;
+ color:#fff;
+ font-weight: 600;
+}
+#footerbar .footer-main .footer-nav li a:hover,#footerbar .footer-main .footer-nav li.current-menu-item a {
+ color:#eee
+}
+#footerbar .footer-main .footer-nav .sub-menu {
+ margin-left:0;
+ margin-bottom:0
+}
+#footerbar .footer-main .footer-nav .sub-menu li {
+ float:none;
+ width: 100%;
+}
+#footerbar .footer-main .footer-nav .sub-menu ul {
+ padding:1px 1em;
+ font-size:0.786em;
+ line-height:8px;
+ float:none;
+ color:#5d5b59;
+ margin-bottom:0
+}
+#footerbar .footer-main .footer-nav .sub-menu li a {
+ padding:2px 0;
+ font-size:1em;
+ float:none;
+ color:#cecfd5;
+ font-weight: 400;
+}
+#footerbar .footer-main .footer-nav .sub-menu li a:hover,#footerbar .footer-main .footer-nav .sub-menu li.current-menu-item a {
+ color:#eee
+}
+#footerbar .theqtcompany {
+ background:url("theqtcompany.png") no-repeat;
+ background-size:100%;
+ width:215px;
+ height:68px;
+ display:inline;
+ float:right;
+ margin:29px 0 28px 30px
+}
+#footerbar .footer-social {
+ display:inline;
+ float:right;
+ width:164px
+}
+#footerbar .footer-main .footer-social>div {
+ margin-left:0.1em;
+ margin-bottom:10px
+}
+#footerbar .disclaimer {
+ font-size:0.786em;
+ line-height:2.73;
+ color:#868584;
+ padding-top:20px;
+ padding-bottom:0.5%
+}
+#footerbar .disclaimer a {
+ color:#bdbebf
+}
+#footerbar .disclaimer a:hover {
+ color:#d6d6d6
+}
+#footerbar .disclaimer ul li {
+ float:left;
+ vertical-align:middle;
+ margin-left:1.18em
+}
+#footerbar .disclaimer ul li:first-child {
+ margin-left:0
+}
+#footerbar .disclaimer ul.lang-selector a {
+ color:#506a34;
+ color:rgba(128,195,66,0.3)
+}
+#footerbar .disclaimer ul.lang-selector a:hover {
+ color:#80c342;
+ color:rgba(128,195,66,0.7)
+}
+#menu-footer-menu, #menu-footer-menu ul {
+ margin-left:0;
+ margin-bottom:0
+}
+@font-face {
+ font-family: 'Titillium Web';
+ font-style: normal;
+ font-weight: 400;
+ src: url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-regular.eot");
+ /* IE9 Compat Modes */
+ src: local("Titillium Web"), local("TitilliumWeb-Regular"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-regular.eot?#iefix") format("embedded-opentype"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-regular.woff2") format("woff2"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-regular.woff") format("woff"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-regular.ttf") format("truetype"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-regular.svg#TitilliumWeb") format("svg");
+ /* Legacy iOS */
+}
+/* titillium-web-italic - latin_latin-ext */
+@font-face {
+ font-family: 'Titillium Web';
+ font-style: italic;
+ font-weight: 400;
+ src: url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-italic.eot");
+ /* IE9 Compat Modes */
+ src: local("Titillium WebItalic"), local("TitilliumWeb-Italic"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-italic.eot?#iefix") format("embedded-opentype"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-italic.woff2") format("woff2"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-italic.woff") format("woff"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-italic.ttf") format("truetype"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-italic.svg#TitilliumWeb") format("svg");
+ /* Legacy iOS */
+}
+/* titillium-web-600 - latin_latin-ext */
+@font-face {
+ font-family: 'Titillium Web';
+ font-style: normal;
+ font-weight: 600;
+ src: url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-600.eot");
+ /* IE9 Compat Modes */
+ src: local("Titillium WebSemiBold"), local("TitilliumWeb-SemiBold"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-600.eot?#iefix") format("embedded-opentype"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-600.woff2") format("woff2"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-600.woff") format("woff"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-600.ttf") format("truetype"), url("//d33sqmjvzgs8hq.cloudfront.net/wp-content/themes/oneqt/assets/fonts/titillium-web-v4-latin_latin-ext-600.svg#TitilliumWeb") format("svg");
+ /* Legacy iOS */
+}
+@font-face {
+ font-family:'Droid Sans Mono';
+ font-style:normal;
+ font-weight:400;
+ src:local("Droid Sans Mono"),local("DroidSansMono"),url(//fonts.gstatic.com/s/droidsansmono/v7/ns-m2xQYezAtqh7ai59hJUYuTAAIFFn5GTWtryCmBQ4.woff) format("woff")
+}
+@font-face {
+ font-family:'Qt Icons';
+ src:url("../style/icomoon.eot?-tgjuoj");
+ src:url("../style/icomoon.eot?#iefix-tgjuoj") format("embedded-opentype"),url("../style/icomoon.woff?-tgjuoj") format("woff"),url("../style/icomoon.ttf?-tgjuoj") format("truetype"),url("../style/icomoon.svg?-tgjuoj#icomoon") format("svg");
+ font-weight:normal;
+ font-style:normal
+}
+@font-face {
+ font-family:'social-icons';
+ src:url("../style/social-icons.eot?54625607");
+ src:url("../style/social-icons.eot?54625607#iefix") format("embedded-opentype"),
+ url("../style/social-icons.woff?54625607") format("woff");
+ font-weight:normal;
+ font-style:normal
+}
+.clearfix:before,.clearfix:after {
+ content:" ";
+ display:table
+}
+.clearfix:after {
+ clear:both
+}
+.clearfix {
+ *zoom:1
+}
+.clearfix .right {
+ float:right
+}
+html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video {
+ margin:0;
+ padding:0;
+ border:0;
+ font-size:100%
+}
+html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,caption,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video {
+ vertical-align:baseline
+}
+h1,h2,h3,h4,h5,h6 {
+ font-weight:300
+}
+.body h2,.body h3,.body h4,.body h5,.body h6 {
+ margin:1.5em 0 0.75em
+}
+.body h1 {
+ margin-bottom:0.75em;
+ font-size:2.25em;
+}
+.body h3.fn,.body h3.flags {
+ color:#26282a;
+ font-size:1.46em;
+ padding:15px 0 15px 0;
+ border-bottom:2px #eee solid;
+ word-wrap:break-word
+}
+.body .fngroup {
+ border-bottom:2px #eee solid;
+ padding-bottom:15px;
+ margin-bottom:1.5em
+}
+.body .fngroup h3.fngroupitem {
+ margin:0;
+ padding-bottom:0;
+ border:none
+}
+.body h3.fn .name,
+.body h3 span.type,
+.qmlname span.name {
+ font-weight: 400
+}
+.qmlname {
+ font-size:1.46em
+}
+.qmlproto table {
+ border:none;
+ border-bottom:2px #eee solid
+}
+.qmlproto table p {
+ max-width:100%
+}
+.qmlproto table tr {
+ background-color:#fff
+}
+.qmlname td, .qmlname th {
+ border:none;
+ text-align:left;
+ padding:5px 0 0 0
+}
+.qmlreadonly,.qmldefault {
+ padding:0 5px 0 5px;
+ font-size:0.75em;
+ background-color:#eee;
+ float:right
+}
+.qmlreadonly {
+ color:#414141
+}
+.qmldefault {
+ color:#D14141
+}
+.rightAlign {
+ padding:3px 5px 3px 10px;
+ text-align:right
+}
+.centerAlign.functionIndex {
+ text-align:center;
+ font-size:150%;
+ margin-bottom: 1em
+}
+article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section {
+ display:block
+}
+body {
+ line-height:1;
+ font-family:'Titillium Web', Arial, Helvetica, sans-serif;
+ font-weight:400;
+ transition-duration:1s;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+ font-size: 16px;
+ background-color:#f3f3f4;
+ color:#404244;
+}
+ol,ul {
+ list-style:none
+}
+.body ol,.body ul {
+ margin-top:0.75em;
+ margin-left:20px
+}
+.bodywrapper ol>li {
+ list-style-type:decimal;
+ margin-left:15px
+}
+.bodywrapper ol.a >li {
+ list-style-type:lower-alpha;
+}
+.bodywrapper ol.A >li {
+ list-style-type:upper-alpha;
+}
+.bodywrapper ol.i >li {
+ list-style-type:lower-roman;
+}
+.bodywrapper ol.I >li {
+ list-style-type:upper-roman;
+}
+.body li p {
+ margin-top:1em
+}
+blockquote,q {
+ quotes:none;
+ border-left:10px solid #ddd;
+ padding-left:10px
+}
+blockquote:before,blockquote:after,q:before,q:after {
+ content:'';
+ content:none;
+ width:100%
+}
+table {
+ border-collapse:collapse;
+ border-spacing:0;
+ margin-bottom:5px;
+ width:100%
+}
+a {
+ color:#17a81a;
+ text-decoration:none;
+ transition-duration:0.3s
+}
+a:hover {
+ color:#17a81a
+}
+.main,#footerbar>div {
+ max-width:1280px;
+ width:95%;
+ margin:0 auto
+}
+.main {
+ margin-top:80px
+}
+@media (max-width: 1120px) {
+ .main,.navbar-header,#footerbar>div {
+ width: 100%;
+ margin: 0;
+ }
+ .main .main-rounded {
+ padding: 0 15px;
+ }
+}
+.main_index {
+ background-color:#fff
+}
+.sectionlist {
+ margin-bottom:2em
+}
+[class*="col-"] {
+ letter-spacing:normal
+}
+.landing,.main_index .row {
+ letter-spacing:-0.31em
+}
+.main_index .row>div {
+ letter-spacing:normal
+}
+.col-1,.body {
+ display:inline-block;
+ background-color:#fff;
+ padding: 25px 35px 20px 30px;
+ -webkit-box-sizing:border-box;
+ -moz-box-sizing:border-box;
+ -ms-box-sizing:border-box;
+ box-sizing:border-box;
+}
+.col-1 h2 {
+ font-size:1.8em;
+ font-weight:300;
+ line-height:1.1;
+ margin-bottom:0.83em;
+ margin-top:1em
+}
+.icons1of3 img {
+ display:inline-block;
+ float:left;
+ margin-right:0.75em;
+ margin-top:-5px;
+ width:2.75em
+}
+div.multi-column {
+ position:relative
+}
+div.multi-column div {
+ display:-moz-inline-box;
+ display:inline-block;
+ vertical-align:top;
+ margin-top:1em;
+ margin-right:2em;
+ width:16em
+}
+.sidebar {
+ display:block;
+ position:relative;
+ position:sticky;
+ float:left;
+ -webkit-box-sizing:border-box;
+ -moz-box-sizing:border-box;
+ -ms-box-sizing:border-box;
+ box-sizing:border-box;
+ width:20%;
+ padding-right:20px
+}
+.sidebar li {
+ text-overflow:ellipsis;
+ overflow:hidden
+}
+.toc,.sectionlist {
+ padding:25px;
+ background-color:#fff;
+ margin-bottom:1.25em
+}
+.sidebar .sectionlist p {
+ margin-bottom:0
+}
+.sectionlist.promo {
+ padding:0;
+ background-color:#f3f3f4
+}
+.sidebar-content:empty {
+ display:none;
+ visibility:hidden
+}
+.col-2 h2,.toc h3,.sidebar-content h2,
+.sidebar-content h3,.sectionlist h2,
+.sphinxsidebar h3 {
+ font-weight:400;
+ margin-bottom:1em
+}
+.toc h3 a {
+ color:#404244
+}
+.title {
+ font-size:2.25em;
+ font-weight:300;
+ letter-spacing:-1px;
+ line-height:1.15em;
+ margin-bottom:0.5em;
+ word-wrap:break-word
+}
+.navigationbar,col-1 h2 {
+ font-size:0.85em
+}
+.navigationbar h1 {
+ font-size:2.5em;
+ margin-bottom:0.85em;
+ margin-top:0.85em
+}
+.navigationbar li {
+ display:inline-block;
+ margin-right:5px;
+ position:relative;
+ padding-right:10px;
+ color:#585a5c
+}
+.navigationbar ul:last-of-type li a {
+ color:#404244
+}
+.sectionlist li, .sphinxsidebar li {
+ padding-bottom: 10px;
+ line-height: 1.75em;
+}
+.col-1 ul {
+ margin-bottom:1.56em
+}
+.bodywrapper li {
+ margin-top:0.5em;
+ line-height:1.25em
+}
+.bodywrapper li.level2 {
+ margin-left:10px;
+ margin-top:0.4em;
+ font-size:0.9375em;
+}
+.bodywrapper p,
+.bodywrapper dd {
+ line-height:1.25em;
+ margin:1em 0 1em;
+ color:#404244
+}
+.bodywrapper b {
+ font-weight:600
+}
+.body ul,.body ol {
+ /* margin-bottom:1.5em */
+}
+.bodywrapper ul ul {
+ margin-top:0.5em
+}
+.bodywrapper .naviNextPrevious {
+ margin-top:25px;
+ max-width:100%
+}
+.naviNextPrevious.headerNavi,
+p.naviNextPrevious + p {
+ display:none
+}
+.nextPage {
+ float:right
+}
+.prevPage:before {
+ content:"< "
+}
+.nextPage:after {
+ content:" >"
+}
+.navigationbar li a {
+ color:#404244
+}
+.navigationbar li:after {
+ color:#404244;
+ content:"›";
+ display:inline-block;
+ font-size:1.5em;
+ line-height:1;
+ position:absolute;
+ right:-2px;
+ top:-4px
+}
+.sub-navigation {
+ margin-top:10px
+}
+.navigationbar li:last-child:after,.sub-navigation li:after {
+ content:none
+}
+.navigationbar {
+ margin-bottom:10px;
+ line-height:1em
+}
+#buildversion {
+ margin-bottom:10px;
+ font-style:italic;
+ font-size:small;
+ float:right
+}
+.copy-notice {
+ width:75%;
+ font-size:0.75em;
+ margin:20px 35px 0 10px;
+ line-height:1.75em;
+ float:right;
+ color:#585a5c
+}
+.copy-notice.index {
+ margin-top:10px;
+ float:none
+}
+li a.active {
+ color:#585a5c
+}
+.flowList {
+ padding:25px
+}
+.flowListDiv dl {
+ -webkit-column-count:1;
+ -moz-column-count:1;
+ column-count:1
+}
+.flowList dd {
+ display:inline-block;
+ margin-left:10px;
+ width:90%;
+ line-height:1.15em;
+ overflow-x:hidden;
+ text-overflow:ellipsis
+}
+.alphaChar {
+ font-size:2em;
+ position:absolute
+}
+.flowList.odd {
+ background-color:#f9f9f9
+}
+.body ul>li,.doc-column ul>li {
+ list-style-image:url("list_arrow.png");
+ margin-left:15px;
+ color:#404244;
+ margin-top:0.65em;
+ line-height:1em
+}
+.bodywrapper table p {
+ margin:0px;
+ padding:0px
+}
+.bodywrapper table p {
+ margin:0px;
+ padding:0px;
+ min-height:1.25em
+}
+.bodywrapper .qmldoc {
+ margin-top:0.75em
+}
+.body h2 {
+ margin-top: 1.5em;
+ font-size:1.75em
+}
+.body h3 {
+ font-size:1.35em
+}
+.body h4 {
+ font-size:1.15em
+}
+.body p img {
+ margin-top:0.75em;
+ max-width:100%
+}
+.body .border img {
+ box-shadow:3px 3px 8px 3px rgba(200,200,200,0.5)
+}
+.body .border .player {
+ box-shadow:3px 3px 8px 3px rgba(200,200,200,0.5)
+}
+.body p.figCaption {
+ transform:translateY(-30px);
+ color:#606366;
+ font-size:95%;
+ margin-left:3px;
+ font-style:italic
+}
+.body table {
+ width:initial;
+ vertical-align:initial
+}
+table .odd {
+ background-color:#f9f9f9
+}
+table thead {
+ text-align:left;
+ padding-left:20px
+}
+table,table td,table th {
+ border:1px solid #eee
+}
+table td,table th {
+ padding:5px 20px;
+ line-height:1.3
+}
+.body .fixed table td {
+ min-width:50%;
+ width:50%
+}
+table.alignedsummary,table.propsummary {
+ width:initial
+}
+table.valuelist td.tblval {
+ font-size:0.75em
+}
+div.main_index .row {
+ border-bottom:10px solid #f3f3f4
+}
+div.main_index .row {
+ position:relative
+}
+div.main_index .row>div {
+ display:inline-block;
+ width:50%;
+ vertical-align:top;
+ padding:2em 3em;
+ -webkit-box-sizing:border-box;
+ -moz-box-sizing:border-box;
+ -ms-box-sizing:border-box;
+ box-sizing:border-box
+}
+div.main_index h2 {
+ font-size:2.1875em;
+ margin-bottom:1em
+}
+#search_bar {
+ width:40%;
+ float:right
+}
+div.main_index .row:after {
+ content:"";
+ position:absolute;
+ top:0;
+ right:50%;
+ height:100%;
+ width:10px;
+ background-color:#f3f3f4
+}
+div.table {
+ overflow-x:auto
+}
+.body tr > td > pre {
+ font-size:0.75em
+}
+p.qt_commercial {
+ border:3px solid #5caa15;
+ margin:0 auto;
+ padding:15px;
+ width:28%;
+ text-align:center;
+ clear:both
+}
+h1.qt_commercial {
+ padding:20px;
+ background-color:#5caa15;
+ display:inline;
+ float:right;
+ font-size:1.25em;
+ line-height:1.25em;
+ height:1.25em;
+ color:#fff
+}
+div.qt_commercial {
+ border-top:5px solid #5caa15;
+ margin-bottom:50px
+}
+div.pre {
+ position:relative;
+ height:auto
+}
+pre, .LegaleseLeft {
+ background-color:#3a4055;
+ color:#fff;
+ display:block;
+ font-family:"Droid Sans Mono";
+ line-height:1.5;
+ overflow-x:auto;
+ margin-bottom:25px;
+ padding:25px;
+ margin-top:0.75em;
+ font-size: .8em;
+}
+.bodywrapper .LegaleseLeft p {
+ color:#fff;
+ white-space: pre-wrap
+}
+pre .str,code .str {
+ color:#aaaaaa
+}
+pre .kwd,code .kwd {
+ color:#ffff55
+}
+pre .com,code .com {
+ color:#55ffff
+}
+pre .typ,code .typ {
+ color:#4f9d08
+}
+pre a .typ,code a .typ {
+ color:#21be2b
+}
+pre .lit,code .lit {
+ color:#ff55ff
+}
+pre .pun,code .pun {
+ color:#fff
+}
+pre .pln,code .pln {
+ color:#fff
+}
+@media print {
+ pre {
+ background-color:#eee !important
+ }
+ pre .str,code .str {
+ color:#060
+ }
+ pre .kwd,code .kwd{
+ color:#006;
+ font-weight:bold
+ }
+ pre .com,code .com {
+ color:#600
+ }
+ pre .typ,code .typ {
+ color:#404;
+ font-weight:bold
+ }
+ pre .lit,code .lit {
+ color:#044
+ }
+ pre .pun,code .pun {
+ color:#440
+ }
+ pre .pln,code .pln {
+ color:#000
+ }
+}
+pre.wrap {
+ white-space:pre-wrap
+}
+pre span.wrap {
+ display:none;
+ background:url("wrap.png") no-repeat;
+ right:0;
+ top:2px;
+ position:absolute;
+ width:20px;
+ height:14px;
+ margin:4px;
+ opacity:0.65
+}
+span.wrap:hover {
+ opacity:1
+}
+span.wrap:active {
+ opacity:0.75
+}
+.copy_text {
+ background-color:#46a2da;
+ color:#fff;
+ border:2px solid #46a2da;
+ padding:10px 16px;
+ margin-left:-10px;
+ margin-top:-50px;
+ position:absolute;
+ opacity:0;
+ cursor:pointer;
+ float:right
+}
+.copy_text:hover {
+ background-color:#fff;
+ color:#46a2da
+}
+code,.codelike {
+ font-family:"Droid Sans Mono"
+}
+h3.fn code {
+ font-size:0.75em;
+ float:right;
+ background-color:#eee;
+ padding:3px;
+ margin: 3px 0 0 20px
+}
+pre:hover>.copy_text {
+ display:inline-block;
+ opacity:1;
+ transition:0.5s ease
+}
+#main_title_bar {
+ background:url("pyside-logo.png") no-repeat;
+ background-size:100%;
+ width:366px;
+ height:86px;
+ margin:15px 0 15px 0
+}
+#main_title_bar h1 {
+ visibility:hidden
+}
+#main_title_bar .search_bar {
+ letter-spacing:normal;
+ width:50%;
+ display:inline-block;
+ -webkit-box-sizing:border-box;
+ -moz-box-sizing:border-box;
+ -ms-box-sizing:border-box;
+ box-sizing:border-box;
+ vertical-align:middle
+}
+#main_title_bar h1 {
+ letter-spacing:normal;
+ display:inline-block;
+ -webkit-box-sizing:border-box;
+ -moz-box-sizing:border-box;
+ -ms-box-sizing:border-box;
+ box-sizing:border-box;
+ vertical-align:middle
+}
+#main_title_bar .search_bar * {
+ letter-spacing:normal;
+ padding:0;
+ margin:0;
+ border:none
+}
+#sidebar-toggle,#toc-toggle {
+ display:none
+}
+@media (max-width: 980px) {
+ body {
+ font-size:calc-em(14px)
+ }
+ #main_title_bar>h1,#main_title_bar .search_bar {
+ width:100%
+ }
+ #main_title_bar .search_bar {
+ margin-bottom:15px
+ }
+ .main {
+ margin-top:0px
+ }
+ .main_index .row {
+ border:none !important
+ }
+ .title {
+ font-size:1.5em;
+ font-weight:400;
+ word-wrap:break-word
+ }
+ .col-1,.body,.naviNextPrevious,.sidebar {
+ padding:10px
+ }
+ .sidebar {
+ position:relative;
+ padding-top:0
+ }
+ .search .sidebar {
+ display:none;
+ visibility:hidden
+ }
+ .col-2 h2,.toc h3,.sidebar-content h2,.sidebar-content h3,.sectionlist h2 {
+ text-align:center;
+ margin-bottom:5px
+ }
+ div.main_index .row:after {
+ content:none
+ }
+ div.main_index .row>div {
+ display:block !important;
+ width:100%;
+ padding:15px;
+ margin:0
+ }
+ .body,.sidebar,.col-1 {
+ width:100%
+ }
+ .sidebar-content,.col-2,.toc {
+ background-color:#fff;
+ margin-bottom:1em;
+ padding:20px
+ }
+ #sidebar-toggle,#toc-toggle {
+ display:block
+ }
+ #sidebar-toggle.collapsed + h2 {
+ display:block
+ }
+ .bodywrapper p {
+ margin-bottom:1em;
+ max-width:100%
+ }
+ table td,table th {
+ padding:5px 5px
+ }
+ .sectionlist {
+ padding:0
+ }
+ .sidebar > .sectionlist {
+ padding:20px
+ }
+ .sectionlist.promo {
+ max-width:46%;
+ margin:0 auto 1em auto;
+ float:left;
+ padding:0 2%
+ }
+ .sidebar .sidebar-content {
+ clear:both
+ }
+ .copy-notice {
+ float:none;
+ width:initial
+ }
+}
+[id]:target > *:first-child,
+dt[id]:target {
+ -webkit-animation:highlighter 3s;
+ animation:highlighter 3s
+}
+@-webkit-keyframes highlighter {
+ 25% {
+ background-color:#d1e8f6;
+ color:#444
+ }
+ 75% {
+ background-color:#d1e8f6;
+ color:#444
+ }
+}
+@keyframes highlighter {
+ 25% {
+ background-color:#d1e8f6;
+ color:#444
+ }
+ 75% {
+ background-color:#d1e8f6;
+ color:#444
+ }
+}
+@-webkit-keyframes copypaste {
+ 25% {
+ opacity:1
+ }
+ 100% {
+ border-radius:10px;
+ margin-top:-50px;
+ opacity:1
+ }
+}
+@keyframes copypaste {
+ 25% {
+ opacity:1
+ }
+ 100% {
+ border-radius:10px;
+ margin-top:-50px;
+ opacity:1
+ }
+}
+#footer {
+ clear:both
+}
+.footer-social i {
+ font-family: "social-icons";
+ font-style: normal;
+ font-size:150%;
+ margin: .55em;
+ color: #cecfd5
+}
+.footer-social i:hover {
+ color: #eee
+}
+.footer-social .icon-twitter:before {
+ content: '\f099'
+}
+.footer-social .icon-facebook:before {
+ content: '\f09a'
+}
+.footer-social .icon-youtube:before {
+ content: '\f16a'
+}
+.menuextraslanguages {
+ display:none;
+ visibility:hidden
+}
+form.gsc-search-box {
+ font-size: 25px !important;
+ margin-top: 0 !important;
+ margin-right: 0 !important;
+ margin-bottom: 4px !important;
+ margin-left: 0 !important;
+ width: 102.5% !important;
+}
+table.gsc-search-box {
+ border-style: none !important;
+ border-width: 0 !important;
+ border-spacing: 0 0 !important;
+ width: 100% !important;
+ margin-bottom: 2px !important;
+}
+
+table.gsc-search-box td {
+ vertical-align: middle !important;
+}
+
+table.gsc-search-box td.gsc-input {
+ padding-right: 0px !important;
+}
+table.gsc-search-box td.gsc-input input {
+ background-position: 10px center !important;
+}
+
+td.gsc-search-button {
+ width: 1% !important;
+}
+
+td.gsc-clear-button {
+ width: 14px !important;
+ visibility:hidden !important;
+ display:none !important;
+}
+table.gsc-branding td,
+table.gsc-branding {
+ margin: 0 0 0 0 !important;
+ padding: 0 0 0 0 !important;
+ border: none !important;
+}
+
+table.gsc-branding {
+ border-style: none !important;
+ border-width: 0 !important;
+ border-spacing: 0 0 !important;
+ width: 100% !important;
+}
+
+.gsc-branding-text {
+ color: #676767 !important;
+}
+
+td.gsc-branding-text {
+ vertical-align: top !important;
+}
+td.gsc-branding-text div.gsc-branding-text {
+ padding-bottom: 2px !important;
+ text-align: right !important;
+ font-size: 11px !important;
+ margin-right: 2px !important;
+}
+
+td.gsc-branding-img {
+ width: 65px !important;
+ vertical-align: bottom !important;
+}
+
+img.gsc-branding-img {
+ padding-top: 1px !important;
+ margin: 0 0 0 0 !important;
+ padding-right: 0 !important;
+ padding-left: 0 !important;
+ padding-bottom: 0 !important;
+ border: none !important;
+ display: inline !important;
+}
+
+input.gsc-search-button {
+ background-color: white !important;
+ height: 35px !important;
+ width: 25px !important;
+ color: transparent !important;
+ background-image: url("doc_search.png") !important;
+ background-size: 25px auto;
+ background-position: 0px 5px;
+ background-repeat: no-repeat;
+ margin-left: -43px !important;
+ overflow: hidden;
+ min-width: 20px !important;
+}
+
+input.gsc-search-button:hover {
+ cursor: pointer;
+}
+
+input.gsc-search-button:focus {
+ outline: none;
+ box-shadow: none;
+}
+
+.gsc-search-box-tools .gsc-clear-button {
+ display: none !important;
+ visibility: none !important;
+}
+
+.gsc-overflow-hidden {
+ overflow: hidden !important;
+}
+
+input.gsc-input {
+ background-color: #fff !important;
+ border: 1px solid #d6d6d6 !important;
+ box-sizing: border-box !important;
+ -moz-box-sizing: border-box !important;
+ color: #868482 !important;
+ outline: 0 none !important;
+ padding: 9px 10px 10px !important;
+ transition: color 0.5s ease 0s, box-shadow 0.5s ease 0s, background-color 0.5s ease 0s !important;
+}
+
+input {
+ font-family: 'Titillium Web', Arial, Helvetica, sans-serif !important;
+ line-height: 1.5 !important;
+ font-weight: 300 !important;
+ vertical-align:middle
+}
+
+input:focus {
+ border-color: #46a2da;
+ box-shadow: 0 0 5px #46a2da;
+ color: #000;
+}
+
+.animation {
+ width: 100%;
+ border-style: none;
+ border-width: 0
+}
+
+.player {
+ width: auto;
+ position: relative;
+ display: table;
+ margin-bottom:1.5em;
+}
+
+.playcontrol {
+ display: none;
+ background: url("play_icon.svg") no-repeat center,
+ linear-gradient(
+ rgba(0,0,0,0.15), rgba(0,0,0,0.15)
+ );
+ background-size: 25%;
+ width: 100%;
+ height: 100%;
+ position: absolute;
+ left: 0%;
+ right: 0%;
+ top: 0%;
+ bottom: 0%;
+ margin: auto
+}
+
+/* expand/collapse code sections */
+pre input {
+ display:none;
+ visibility:hidden
+}
+pre label {
+ display:block;
+ margin:-3px 3px 0 -16px;
+ text-align:center;
+ color:#21be2b;
+ float:left;
+}
+pre label:hover {
+ color:#fff
+}
+pre label::before {
+ font-weight:600;
+ font-size:16px;
+ content:"+";
+ display:inline-block;
+ width:16px;
+ height:16px
+}
+#ec_expand {
+ height:16px;
+ overflow:hidden;
+ transition:height 0.35s;
+}
+#ec_expand::before {
+ content:"...*/";
+ color:#aaa;
+ background-color:#3a4055;
+ z-index:99 !important;
+ right:25px;
+ position:absolute
+}
+#ec_toggle:checked ~ #ec_expand {
+ height:initial
+}
+#ec_toggle:checked ~ #ec_expand::before {
+ content:""
+}
+#ec_toggle:checked ~ label::before {
+ content:"-"
+}
+
+/* permalinks */
+h1:hover > .headerlink,
+h2:hover > .plink,
+h2:hover > .headerlink,
+h3:hover > .plink,
+h3:hover > .headerlink,
+h4:hover > .plink,
+h4:hover > .headerlink,
+h5:hover > .plink,
+h5:hover > .headerlink {
+ opacity:1
+}
+a.plink, a.headerlink {
+ opacity: 0;
+ padding-left: 8px;
+ font-size: 0.8em;
+ font-weight: 600;
+ transition: opacity 180ms ease-in-out
+}
+a.plink::before {
+ content:'\00B6'
+}
diff --git a/sources/pyside2/doc/_themes/pysidedocs/static/pysidedocs.css b/sources/pyside2/doc/_themes/pysidedocs/static/pysidedocs.css
deleted file mode 100644
index 6b1c4274e..000000000
--- a/sources/pyside2/doc/_themes/pysidedocs/static/pysidedocs.css
+++ /dev/null
@@ -1,477 +0,0 @@
-* {
- font: 100% Verdana, Arial, Helvetica, sans-serif;
- font-size:12px;
-}
-
-html {
- height: 100%;
-}
-
-body {
- margin: 0;
- padding: 0;
- background-color: #EBEBEB;
- height: 100%;
- color: #333;
-}
-
-strong {
- font-weight:bold;
-}
-
-.document {
- padding-bottom: 90px;
-}
-
-#container {
- position: relative;
- min-height: 100%;
- background-image: url(fakebar.png);
- background-repeat: repeat-y;
- background-color: white;
-}
-
-.footer {
- position: absolute;
- bottom: 0px;
- margin-top: 50px;
- text-align:center;
- background-color: white;
- border-top: 2px solid #e0e0e0;
- white-space: normal;
- height: 90px;
- width: 100%;
-}
-
-.footer img {
- margin-left: 8px;
- margin-right: 8px;
-}
-
-.sphinxsidebar {
- float: left;
- width: 250px;
- padding: 0px 10px 0px 10px;
- text-align: left;
-}
-
-.sphinxsidebar ul {
- padding: 0px;
- margin: 0px;
- list-style-position: inside;
-}
-
-.sphinxsidebar > ul {
- padding: 0px;
- margin: 0px;
-}
-
-.sphinxsidebar ul li {
- margin-left: 10px;
- padding: 0px;
-}
-
-.sphinxsidebar h3, .sphinxsidebar h3 a {
- font-weight: bold;
- color: #333;
-}
-
-.documentwrapper {
- margin-left: 270px;
- text-align: left;
- background-color: #ffffff;
- border-left: 1px solid #989898;
- font-size:18px;
- padding: 10px 50px 15px 50px;
- height: 100%;
-}
-
-h1 {
- font-size:18px;
- padding-left: 50px;
- padding-bottom: 15px;
- padding-top: 15px;
- border-bottom: 1px solid #c2c2c2;
-/* text-transform:uppercase; */
- margin-right: -100px;
- position: relative;
- left: -50px;
- top: -10px;
-}
-
-h2 {
- font-size:12px;
- font-weight:bold;
- border-left-width: 1px;
- border-right-width: 1px;
- border-top-width: 1px;
- border-bottom-width: 2px;
- border-style: solid;
- border-left-color: #b1b1b1;
- border-right-color: #b1b1b1;
- border-top-color: #b1b1b1;
- border-bottom-color: #009491;
- background-color: #e0e0e0;
- padding:5px;
- margin-top: 20px;
- -moz-border-radius:5px;
- -webkit-border-radius:5px;
- -khtml-border-radius:5px;
-}
-
-h3, h4 {
- font-weight: bolder;
-}
-
-pre {
- border-top: 1px solid #e0e0e0;
- border-bottom: 1px solid #e0e0e0;
- background-color: #fafafa;
- padding: 5px;
- font: 100% monospace;
- overflow: auto;
-}
-
-pre * {
- font: 100% monospace;
-}
-
-.pre {
- font: 100% monospace;
-}
-
-.headerlink {
- font-size: 100%;
- color: inherit;
- float: right;
- visibility: Hidden
-}
-
-h1 .headerlink {
- padding-right: 50px;
-}
-
-h1:hover .headerlink, h2:hover .headerlink, h3:hover .headerlink {
- visibility: Visible;
-}
-
-a, a:visited {
- color: #009491;
- text-decoration: none;
-}
-
-a:hover {
- text-decoration: underline;
-}
-
-/* -- admonitions ----------------------------------------------------------- */
-
-div.admonition {
- margin-top: 10px;
- margin-bottom: 10px;
- padding: 7px;
-}
-
-div.admonition dt {
- font-weight: bold;
-}
-
-div.admonition dl {
- margin-bottom: 0;
-}
-
-p.admonition-title {
- margin: 0px 10px 5px 0px;
- font-weight: bold;
-}
-
-div.body p.centered {
- text-align: center;
- margin-top: 25px;
-}
-
-div.warning {
- background-color: #ffe4e4;
- border: 1px solid #f66;
-}
-
-div.seealso {
- background-color: #ffffcc;
- border: 1px solid #ffff66;
-}
-
-div.note {
- border: 1px solid #e3e3e3;
-}
-
-table.docutils {
- margin-left: auto;
- margin-right: auto;
- margin-bottom: 10px;
- border: none;
-}
-
-table.docutils td {
- border: none;
-}
-
-table.docutils th {
- border: none;
- font-weight: bold;
- vertical-align: top;
-}
-
-h2 em {
- float: right;
- font-size: 10px;
- position: relative;
- top: -20px;
-}
-
-/* Table of pymaemo components */
-
-#development table.docutils td {
- border-bottom: 1px solid #EBEBEB;
-}
-
-#development th {
- background-color: #EBEBEB;
- color: #FC7E00;
- padding: 5px;
-}
-
-#development th:first-child {
- -moz-border-radius: 20px 0px 0px 0px;
- -webkit-border-radius: 20px 0px 0px 0px;
- -khtml-border-radius: 20px 0px 0px 0px;
- padding-left: 10px;
-}
-#development th:last-child {
- -moz-border-radius: 0px 20px 0px 0px;
- -webkit-border-radius: 0px 20px 0px 0px;
- -khtml-border-radius: 0px 20px 0px 0px;
- padding-right: 10px;
- width: 100px;
-}
-
-hr {
- border: none;
- border-bottom: 1px dashed #EBEBEB;
- width: 70%
-}
-
-.oldnews {
- text-align: right;
-}
-
-/******************* TOPO *****************************/
-.header {
- background-image: url(bg_topo.jpg);
- background-repeat: repeat-x;
- height: 147px;
-}
-
-.header_container {
- background-image: url(bg_header.png);
- background-repeat: no-repeat;
- background-position: 100px 0px;
-}
-
-.logo {
- text-align: left;
- margin-bottom: 10px;
-}
-
-#searchbox {
- border-top: 1px solid #989898;
- padding-top: 10px;
- margin-left: -10px;
- margin-right: -10px;
- padding-left: 10px;
- padding-right: 10px;
-}
-
-#search_button {
- border: 1px solid #3A393A;
- background-color: #3A393A;
- color: white;
- cursor: pointer;
- -moz-border-radius: 5px;
- -webkit-border-radius: 5px;
- -khtml-border-radius: 5px;
-
-}
-
-form {
- margin: 0px;
- padding: 0px;
-}
-
-/* search field */
-form #q {
- width: 136px;
-/* height: 22px; */
- border: none;
- margin: 0px;
- -moz-border-radius: 5px;
- -webkit-border-radius: 5px;
- -khtml-border-radius: 5px;
- margin-top: 2px;
- padding: 4px;
- line-height: 22px
-}
-
-#search-results h2 {
- display: none;
-}
-
-#search-results h2 {
- display: none;
-}
-
-#search-results ul.search {
- margin: 0px;
- padding: 0px;
-}
-
-ul.search div.context {
- padding-left: 40px;
-}
-
-#installation td {
- text-align: center;
- font-weight: bold;
-}
-
-em {
- color: inherit;
- font-style:italic;
-}
-
-/******** REL bar *********/
-
-.related {
- display: inline;
-}
-
-.related ul {
- padding: 0px 0px 0px 10px;
- margin: 0px;
- text-align: left;
- background-image: url(relbar_bg.png);
-}
-
-.related li {
- display: inline;
- color: white;
- font-weight: bold;
-}
-
-.related li a {
- color: inherit;
- line-height: 35px;
- font-weight: bold;
- vertical-align: middle;
-}
-
-.related li.right {
- float: right;
- margin-right: 5px;
-}
-
-.related h3 {
- display: none;
-}
-
-.align-center {
- text-align: center;
-}
-
-.contentstable {
- width: 100%;
-}
-
-.contentstable td {
- padding-left: 30px;
- vertical-align: top;
-}
-
-p.biglink a {
- font-size: 20px;
-}
-
-dt:target, .highlight {
- background-color: #fbe54e;
-}
-
-img {
- border: 0px;
-}
-
-.figure .caption {
- font-style:italic;
-}
-
-table.footnote {
- margin: 0px;
-}
-
-#synopsis table, table.field-list {
- margin: 0px;
-}
-
-tt.descname {
- font-size: 120%;
- font-weight: bold;
-}
-
-#functions ul, #virtual-functions ul, #slots ul, #signals ul, #static-functions ul {
- list-style: none;
- margin: 0px;
- padding: 10px;
- border: 1px solid #ddd;
- background-color: #f4f4f4;
- -moz-border-radius:10px;
- -webkit-border-radius:10px;
- -khtml-border-radius:10px;
-}
-
-#synopsis span.pre {
- color: #009491;
- font-weight: bolder;
-}
-
-#detailed-description .class dt, #detailed-description .method dt, #detailed-description .attribute dt {
- margin: 0px;
- padding: 10px;
- border: 1px solid #ddd;
- background-color: #f4f4f4;
- -moz-border-radius:10px;
- -webkit-border-radius:10px;
- -khtml-border-radius:10px;
-}
-
-.pysidetoc ul {
- list-style: none;
- padding: 0px;
- margin: 0px;
-}
-
-.pysidetoc em {
- font-style: normal;
-}
-
-.pysidetoc strong {
- display: block;
- padding: 5px;
- border: 1px solid #ddd;
- background-color: #f4f4f4;
- -moz-border-radius:6px;
- -webkit-border-radius:6px;
- -khtml-border-radius:6px;
-}
-
-.hide {
- display: none;
-}
-
diff --git a/sources/pyside2/doc/_themes/pysidedocs/theme.conf b/sources/pyside2/doc/_themes/pysidedocs/theme.conf
index e0a652a5d..01a4dd4a1 100644
--- a/sources/pyside2/doc/_themes/pysidedocs/theme.conf
+++ b/sources/pyside2/doc/_themes/pysidedocs/theme.conf
@@ -1,6 +1,6 @@
[theme]
inherit = default
-stylesheet = pysidedocs.css
+stylesheet = pyside.css
pygments_style = none
[options]
diff --git a/sources/pyside2/doc/deployment-cxfreeze.rst b/sources/pyside2/doc/deployment-cxfreeze.rst
index 40b65621b..f0a71ca80 100644
--- a/sources/pyside2/doc/deployment-cxfreeze.rst
+++ b/sources/pyside2/doc/deployment-cxfreeze.rst
@@ -2,10 +2,9 @@
|project| & cx_Freeze
=====================
-`cx_Freeze <https://anthony-tuininga.github.io/cx_Freeze/>`_ allows you to freeze your Python
-application into executables.
-The supported platforms are Linux, macOS, Windows, FreeBSD, among others.
-
+`cx_Freeze <https://anthony-tuininga.github.io/cx_Freeze/>`_ lets you
+freeze your Python application into executables. The supported
+platforms are Linux, macOS, Windows, FreeBSD, among others.
You can read the `official documentation <https://cx-freeze.readthedocs.io/en/latest/index.html>`_
to clarify any further question, and remember to contribute to
@@ -15,7 +14,7 @@ if you find any, or contributing to `their development <https://bitbucket.org/an
Preparation
===========
-Installing `cx_Freeze` can be done via **pip**::
+Installing `cx_Freeze` can be done using **pip**::
pip install cx_freeze
@@ -34,7 +33,7 @@ There are three options to work with `cx_Freeze`:
2. Creating `setup.py` script to build the project.
3. Using the module classes directly (for advanced purposes).
-We will cover the first two uses cases.
+The following sections cover the first two use cases.
Creating an example
-------------------
@@ -83,15 +82,16 @@ Now, consider the following simple script, named `hello.py`::
Using `cxfreeze` executable
---------------------------
-The command line to proceed will look like this::
+Now that we have an application, try freezing it with the following
+command::
cxfreeze hello.py
-This command will create a `dist/` directory that will contain the
-executable and a `lib/` directory including all the shared libraries.
+This command creates a `dist/` directory containing the executable.
+and a `lib/` directory containing all the shared libraries.
-To launch the application, you need to just go to the `dist/` directory
-and execute the file::
+To launch the application, go to the `dist/` directory and execute
+the file::
cd dist/
./main
@@ -100,7 +100,7 @@ and execute the file::
Using a setuptools script
-------------------------
-For this process, you will need an additional script called `setup.py`::
+For this process, you need an additional script called `setup.py`::
import sys
from cx_Freeze import setup, Executable
@@ -110,18 +110,18 @@ For this process, you will need an additional script called `setup.py`::
description = "My GUI App",
executables = [Executable("hello.py")])
-After that, you need to build the project using it::
+Now, build the project using it::
python setup.py build
-This step will create a `build/` directory with the following structure::
+This step creates a `build/` directory with the following structure::
build
└── exe.linux-x86_64-3.7
└── lib
└── main
-The first directory inside `build/` will depend on the platform
+The first directory inside `build/` depends on the platform
you are using, in this case a `x86_64` Linux using Python 3.7.
The structure is the same as previously described, and you can simply
enter the directory and execute the file::
diff --git a/sources/pyside2/doc/deployment-fbs.rst b/sources/pyside2/doc/deployment-fbs.rst
index ff489f745..6375da61e 100644
--- a/sources/pyside2/doc/deployment-fbs.rst
+++ b/sources/pyside2/doc/deployment-fbs.rst
@@ -3,8 +3,8 @@
===============
`fbs <https://build-system.fman.io>`_ provides a powerful environment for packaging,
-creating installers, and signing your application, but also for managing the application's updates.
-Since it is based on PyInstaller, it currently supports Linux, macOS, and Windows.
+creating installers, and signing your application. It also lets you manage updates to
+your application. As it is based on PyInstaller, it supports Linux, macOS, and Windows.
You can read the `official tutorial <https://github.com/mherrmann/fbs-tutorial>`_ for more
details on how to use `fbs`, or check the
@@ -26,12 +26,12 @@ After the installation, you will be able to use the `fbs` executable.
Starting a new project
======================
-`fbs` provides nice features that allow you to create a base
+`fbs` provides nice features that lets you create a base
project structure by executing the following command::
fbs startproject
-This process will prompt you to answer many questions to configure the details
+This command prompts you to answer a few questions to configure the details
of your project, like:
* Application name
@@ -39,8 +39,8 @@ of your project, like:
* Qt bindings (PySide2 or PyQt5)
* Bundle indentified (for macOS)
-After the process finishes, you will have a `src/` directory that
-will contain the following structure::
+After it finishes, you will have a `src/` directory that
+contains the following structure::
└── src
├── build
@@ -52,10 +52,11 @@ will contain the following structure::
│ └── mac
└── python
-Inside the `settings` directory you can find a couple of `json` files
-that you can edit to include more information about your project.
+Inside the `settings` directory, you will find a couple of `json` files
+that can be edited to include more information about your project.
-The main file will be under the `python` directory, and its content by default is::
+The `main` file will be under the `python` directory, and its content
+by default is::
from fbs_runtime.application_context import ApplicationContext
from PySide2.QtWidgets import QMainWindow
@@ -70,7 +71,8 @@ The main file will be under the `python` directory, and its content by default i
exit_code = appctxt.app.exec_() # 2. Invoke appctxt.app.exec_()
sys.exit(exit_code)
-The example will show an empty `QMainWindow`, and you can execute it by running::
+This example shows an empty `QMainWindow`. You can run it using the
+following command::
fbs run
@@ -78,23 +80,24 @@ Freezing the application
========================
Once you verify that the application is properly working,
-you can continue with the freezing process::
+you can continue with the freezing process using the following
+command::
fbs freeze
After the process finishes, you will get a message stating the location
-of your executable, e.g.::
+of your executable. For example::
Done. You can now run `target/MyApp/MyApp`. If that doesn't work, see
https://build-system.fman.io/troubleshooting.
-Then executing the application will result in the same window
-you saw with the `fbs run` command::
+You can now try running the application, which will result in the same
+window that you saw with the `fbs run` command::
cd target/MyApp/
./MyApp
-.. note:: This is the case for Linux. For other platforms like macOS, you will need to
- enter the directory: `target/MyApp.app/Contents/MacOS`, and for
- Windows you will find a `MyApp.exe` executable.
+.. note:: This is the case for Linux. For other platforms like macOS,
+ you need to enter the directory: `target/MyApp.app/Contents/macOS`,
+ and for Windows find the `MyApp.exe` executable.
diff --git a/sources/pyside2/doc/deployment-pyinstaller.rst b/sources/pyside2/doc/deployment-pyinstaller.rst
index f361daf4a..7a720f558 100644
--- a/sources/pyside2/doc/deployment-pyinstaller.rst
+++ b/sources/pyside2/doc/deployment-pyinstaller.rst
@@ -2,12 +2,12 @@
|project| & PyInstaller
=======================
-`PyInstaller <https://www.pyinstaller.org/>`_ allows you to freeze your python
+`PyInstaller <https://www.pyinstaller.org/>`_ lets you freeze your python
application into a stand-alone executable.
The supported platforms are Linux, macOS, Windows, FreeBSD, and others.
One of the main goals of `PyInstaller` is to be compatible with 3rd-party
-Python modules, e.g.: |pymodname|.
+Python modules, for example: |pymodname|.
You can read the `official documentation <https://www.pyinstaller.org/documentation.html>`_
to clarify any further question, and remember to contribute to
@@ -17,7 +17,7 @@ by filing issues if you find any, or contributing to their development.
Preparation
===========
-Installing `PyInstaller` can be done via **pip**::
+Installing `PyInstaller` can be done using **pip**::
pip install pyinstaller
@@ -26,12 +26,11 @@ installing `PyInstaller` into it.
After the installation, the `pyinstaller` binary will be located in the `bin/`
directory of your virtual environment, or where your Python executable is located.
+If that directory is not in your `PATH`, include the whole path when executing `pyinstaller`.
-If that directory is not in your `PATH`, you need to include the whole path
-when executing `pyinstaller`.
-
-.. warning:: If you already have PySide2 or Shiboken2 installed in your system, PyInstaller will pick them
- instead of your virtual environment ones.
+.. warning:: If you already have a PySide2 or Shiboken2 version installed in your
+ system path, PyInstaller will pick them instead of your virtual environment
+ version.
Freezing an application
=======================
@@ -41,13 +40,12 @@ To learn more about them you can just run `pyinstaller -h`.
Two main features are the option to package the whole project
(including the shared libraries) into one executable file (`--onefile`),
-and to prepare a directory that will contain
-an executable next to all the used libraries.
+and to place it in a directory containing the libraries.
Additionally, for Windows you can enable opening a console during the
-execution with the option `-c` (or equivalent `--console` or `--nowindowed`).
+execution with the option, `-c` (or equivalent `--console` or `--nowindowed`).
Further, you can specify to not open such console window
-on macOS and Windows with the option `-w` (or equivalent `--windowed` or `--noconsole`).
+on macOS and Windows with the option, `-w` (or equivalent `--windowed` or `--noconsole`).
Creating an example
-------------------
@@ -93,32 +91,33 @@ Now, consider the following simple script, named `hello.py`::
sys.exit(app.exec_())
-Since it has a UI, we will use the `--windowed` option.
+As it has a UI, you will use the `--windowed` option.
-The command line to proceed will look like this::
+The command line to proceed looks like this::
pyinstaller --name="MyApplication" --windowed hello.py
-This process will create a `dist/` and `build/` directory.
-The executable and all the shared libraries required by your application
-will be placed inside `dist/MyApplication`.
+This process creates a `dist/` and `build/` directory.
+The application executable and the required shared libraries are
+placed in `dist/MyApplication`.
-To execute the frozen application you can go inside `dist/MyApplication` and
+To run the application you can go to `dist/MyApplication` and
execute the program::
cd dist/MyApplication/
./MyApplication
-.. note:: The directory inside `dist/` and the executable will have the same name.
+.. note:: The directory inside `dist/` and the executable will have
+the same name.
-If you prefer to have everything bundled into one executable, i.e.:
-no shared libraries next to the executable, you can use the option
+If you prefer to have everything bundled into one executable,
+without the shared libraries next to it, you can use the option
`--onefile`::
pyinstaller --name="MyApplication" --windowed --onefile hello.py
-This process will take a bit longer, but in the end you will discover
-an executable inside the `dist/` directory that you can execute::
+This process takes a bit longer, but in the end you will have one
+executable in the `dist/` directory::
cd dist/
./MyApplication
@@ -131,26 +130,29 @@ Current Caveats To Be Aware Of
PyInstaller Problem
-------------------
-As already mentioned, `PyInstaller` will pick a system installation of PySide2 or
-Shiboken2 instead of your virtualenv version without notice, if it exists.
-This may be no problem if those PySide2 or shiboken2 versions are the same.
-
-If you are working with different versions, this can result in frustrating sessions,
-when you think you are testing a new version, but `PyInstaller`
-is silently working with a different, older version.
+As already mentioned, `PyInstaller` will pick a system installation
+of PySide2 or Shiboken2 instead of your virtualenv version without
+notice, if it exists. This may not be a problem if those two
+versions are the same.
+If you are working with different versions, this can result in
+frustrating debugging sessions. You could think you are testing the
+latest version, but `PyInstaller` could be working with an older
+version.
Problem with numpy in Python 2.7.16
-----------------------------------
-A recent problem of PyInstaller is the appearance of Python 2.7.16 .
-This Python version creates a problem that is known from Python 3 as a `Tcl/Tk` problem.
-This does rarely show up in Python 3 because `Tcl/Tk` is seldom used with `PyInstaller.
+A recent problem of PyInstaller is the appearance of Python 2.7.16.
+This Python version creates a problem that is known from Python 3
+as a `Tcl/Tk` problem. This does rarely show up in Python 3 because
+`Tcl/Tk` is seldom used with `PyInstaller.
-On Python 2.7.16, this problem is very much visible, since many people are using numpy.
-For some reason, installing `numpy` creates a dependency of `Tcl/Tk`, which can
-be circumvented only by explicitly excluding `Tcl/Tk` related things by adding
-this line to the analysis section of the spec-file::
+On Python 2.7.16, this problem is very much visible, as many are
+using numpy. For some reason, installing `numpy` creates a
+dependency to `Tcl/Tk`, which can be circumvented only by explicitly
+excluding `Tcl/Tk` related things by adding this line to the analysis
+section of the spec-file::
excludes=['FixTk', 'tcl', 'tk', '_tkinter', 'tkinter', 'Tkinter'],
@@ -162,12 +164,12 @@ o When using `PyInstaller` with `virtualenv`, make sure that there is no system
installation of PySide2 or shiboken2.
o Before compiling, use `pip -uninstall pyside2 shiboken2 -y` multiple times, until
- none of the programs is found anymore.
+ none of the programs are found anymore.
o Pip is usually a good tool. But to be 100 % sure, you should directly remove
the PySide2 and shiboken2 folders from site-packages.
o Be sure to use the right version of pip. The safest way to really run the right
- pip, use the Python that you mean: Instead of the pip command, better use::
+ pip, is to use the Python that you mean: Instead of the pip command, better use::
<path/to/your/>python -m pip
diff --git a/sources/pyside2/libpyside/pyside.cpp b/sources/pyside2/libpyside/pyside.cpp
index 6e4a3efd4..fff28a9e7 100644
--- a/sources/pyside2/libpyside/pyside.cpp
+++ b/sources/pyside2/libpyside/pyside.cpp
@@ -94,6 +94,31 @@ void init(PyObject *module)
SignalManager::instance();
}
+static bool _setProperty(PyObject* qObj, PyObject *name, PyObject *value, bool *accept)
+{
+ QByteArray propName(Shiboken::String::toCString(name));
+ propName[0] = std::toupper(propName[0]);
+ propName.prepend("set");
+
+ Shiboken::AutoDecRef propSetter(PyObject_GetAttrString(qObj, propName.constData()));
+ if (!propSetter.isNull()) {
+ *accept = true;
+ Shiboken::AutoDecRef args(PyTuple_Pack(1, value));
+ Shiboken::AutoDecRef retval(PyObject_CallObject(propSetter, args));
+ if (retval.isNull())
+ return false;
+ } else {
+ PyErr_Clear();
+ Shiboken::AutoDecRef attr(PyObject_GenericGetAttr(qObj, name));
+ if (PySide::Property::checkType(attr)) {
+ *accept = true;
+ if (PySide::Property::setValue(reinterpret_cast<PySideProperty*>(attr.object()), qObj, value) < 0)
+ return false;
+ }
+ }
+ return true;
+}
+
bool fillQtProperties(PyObject* qObj, const QMetaObject* metaObj, PyObject* kwds, const char** blackList, unsigned int blackListSize)
{
@@ -103,28 +128,27 @@ bool fillQtProperties(PyObject* qObj, const QMetaObject* metaObj, PyObject* kwds
while (PyDict_Next(kwds, &pos, &key, &value)) {
if (!blackListSize || !std::binary_search(blackList, blackList + blackListSize, std::string(Shiboken::String::toCString(key)))) {
QByteArray propName(Shiboken::String::toCString(key));
+ bool accept = false;
if (metaObj->indexOfProperty(propName) != -1) {
- propName[0] = std::toupper(propName[0]);
- propName.prepend("set");
-
- Shiboken::AutoDecRef propSetter(PyObject_GetAttrString(qObj, propName.constData()));
- if (!propSetter.isNull()) {
- Shiboken::AutoDecRef args(PyTuple_Pack(1, value));
- Shiboken::AutoDecRef retval(PyObject_CallObject(propSetter, args));
- } else {
- PyObject* attr = PyObject_GenericGetAttr(qObj, key);
- if (PySide::Property::checkType(attr))
- PySide::Property::setValue(reinterpret_cast<PySideProperty*>(attr), qObj, value);
- }
+ if (!_setProperty(qObj, key, value, &accept))
+ return false;
} else {
propName.append("()");
if (metaObj->indexOfSignal(propName) != -1) {
+ accept = true;
propName.prepend('2');
- PySide::Signal::connect(qObj, propName, value);
- } else {
- PyErr_Format(PyExc_AttributeError, "'%s' is not a Qt property or a signal", propName.constData());
+ if (!PySide::Signal::connect(qObj, propName, value))
+ return false;
+ }
+ }
+ if (!accept) {
+ // PYSIDE-1019: Allow any existing attribute in the constructor.
+ if (!_setProperty(qObj, key, value, &accept))
return false;
- };
+ }
+ if (!accept) {
+ PyErr_Format(PyExc_AttributeError, "'%S' is not a Qt property or a signal", key);
+ return false;
}
}
}
diff --git a/sources/pyside2/tests/QtWidgets/application_test.py b/sources/pyside2/tests/QtWidgets/application_test.py
index bd0f94125..0b8f73cd6 100644
--- a/sources/pyside2/tests/QtWidgets/application_test.py
+++ b/sources/pyside2/tests/QtWidgets/application_test.py
@@ -31,19 +31,25 @@
import unittest
from testbinding import TestObject
from PySide2.QtWidgets import QApplication
+from PySide2 import __all__ as all
class QApplicationInstance(unittest.TestCase):
def appDestroyed(self):
- sefl.assertTrue(False)
+ self.assertTrue(False)
def testInstanceObject(self):
+ self.assertEqual(type(qApp), type(None))
TestObject.createApp()
app1 = QApplication.instance()
app2 = QApplication.instance()
app1.setObjectName("MyApp")
self.assertEqual(app1, app2)
self.assertEqual(app2.objectName(), app1.objectName())
+ if len(all) > 3:
+ # an import triggers qApp initialization
+ __import__("PySide2." + all[-1])
+ self.assertEqual(app1, qApp)
app1.destroyed.connect(self.appDestroyed)
if __name__ == '__main__':
diff --git a/sources/pyside2/tests/pysidetest/CMakeLists.txt b/sources/pyside2/tests/pysidetest/CMakeLists.txt
index cb8ba04cf..3c993cf4e 100644
--- a/sources/pyside2/tests/pysidetest/CMakeLists.txt
+++ b/sources/pyside2/tests/pysidetest/CMakeLists.txt
@@ -118,6 +118,7 @@ target_link_libraries(testbinding
add_dependencies(testbinding pyside2 QtCore QtGui QtWidgets pysidetest)
create_generator_target(testbinding)
+PYSIDE_TEST(constructor_properties_test.py)
PYSIDE_TEST(decoratedslot_test.py)
# Will always crash when built against Qt 5.6, no point in running it.
if (Qt5Core_VERSION VERSION_GREATER 5.7.0)
diff --git a/sources/pyside2/tests/pysidetest/constructor_properties_test.py b/sources/pyside2/tests/pysidetest/constructor_properties_test.py
new file mode 100644
index 000000000..48e2a7aae
--- /dev/null
+++ b/sources/pyside2/tests/pysidetest/constructor_properties_test.py
@@ -0,0 +1,64 @@
+#############################################################################
+##
+## Copyright (C) 2019 The Qt Company Ltd.
+## Contact: https://www.qt.io/licensing/
+##
+## This file is part of Qt for Python.
+##
+## $QT_BEGIN_LICENSE:LGPL$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and The Qt Company. For licensing terms
+## and conditions see https://www.qt.io/terms-conditions. For further
+## information use the contact form at https://www.qt.io/contact-us.
+##
+## GNU Lesser General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU Lesser
+## General Public License version 3 as published by the Free Software
+## Foundation and appearing in the file LICENSE.LGPL3 included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU Lesser General Public License version 3 requirements
+## will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 2.0 or (at your option) the GNU General
+## Public license version 3 or any later version approved by the KDE Free
+## Qt Foundation. The licenses are as published by the Free Software
+## Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
+## included in the packaging of this file. Please review the following
+## information to ensure the GNU General Public License requirements will
+## be met: https://www.gnu.org/licenses/gpl-2.0.html and
+## https://www.gnu.org/licenses/gpl-3.0.html.
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+import unittest
+
+from helper import UsesQApplication
+from PySide2.QtCore import Qt
+from PySide2.QtWidgets import QApplication, QLabel, QFrame
+
+
+class ConstructorPropertiesTest(UsesQApplication):
+
+ def testCallConstructor(self):
+ label = QLabel(
+ frameStyle=QFrame.Panel | QFrame.Sunken,
+ text="first line\nsecond line",
+ alignment=Qt.AlignBottom | Qt.AlignRight
+ )
+ self.assertRaises(AttributeError, lambda: QLabel(
+ somethingelse=42,
+ text="first line\nsecond line",
+ alignment=Qt.AlignBottom | Qt.AlignRight
+ ))
+
+
+if __name__ == '__main__':
+ unittest.main()
+