Skip to content

Qt for Python

For discussion and questions about Qt for Python (PySide & Shiboken)

3.4k Topics 14.8k Posts
  • Pre-allocating a space to insert my specialized widget

    Unsolved
    2
    0 Votes
    2 Posts
    255 Views
    JonBJ
    @BegBlev So that I understand --- and I am more C++ than Python --- are you using Designer's Promote to ... from the widget's context menu, e.g. as per https://www.pythonguis.com/tutorials/embed-pyqtgraph-custom-widgets-qt-app/ ?
  • Resources text file unable to be opened in Windows, but works fine in Linux

    Solved
    15
    1 Votes
    15 Posts
    2k Views
    T
    For anyone else who is having issues similar to mine: I have confirmed that by running pyside6-rcc with --compress-algo zlib allows for the creation of a resources file that works cross-platform, at the cost of a larger resources file size. So, if you need cross-platform compatibility for your resources files that are generated on Linux but pulled on other platforms, be sure to use zlib as the compression algorithm, rather than the default of zstd (which isn't even available on Windows). I'm going to mark this as solved, but will be going through the bug report I mentioned above to hopefully get some documentation written about this inconsistency.
  • 0 Votes
    3 Posts
    469 Views
    R
    Thank you very much for your reply. I have used 3.10. It works when I upgrade to 3.12.
  • PySide6.QtGraphs.QSurfaceDataProxy.resetArrayNp called with wrong argument types:

    Solved
    7
    0 Votes
    7 Posts
    476 Views
    SGaistS
    @G4IXT Hi, As an alternative you can very well install PySide6 in your conda environment using pip. That way you can use conda to manage your environments.
  • macOS Trackpad Gestures - Simultaneous Pinch & Pan?

    Unsolved
    2
    0 Votes
    2 Posts
    506 Views
    jsulmJ
    @mjiggidyj said in macOS Trackpad Gestures - Simulatneous Pinch & Pan?: any positional info I get from the QNativeGestureEvent during pinch (from pos(), etc) is not updated What about https://doc.qt.io/qt-6/qnativegestureevent.html#delta ?
  • [PySide6] Unable to listen to DBUS ScreenSaver ActiveChanged Signal

    Unsolved pyside
    1
    0 Votes
    1 Posts
    249 Views
    No one has replied
  • Did pyside6 ever support macOS 10.13?

    Unsolved
    2
    0 Votes
    2 Posts
    407 Views
    I
    It doesn't appear so, no. The minimal version ever supported by Qt 6 (as seen in the 6.0 documentation archives) is 10.14 - https://doc.qt.io/archives/qt-6.0/supported-platforms.html.
  • Qt Designer - unable to replicate qtdesigner-manual form

    Unsolved
    12
    0 Votes
    12 Posts
    2k Views
    JonBJ
    @ReyCBXZRX I don't always follow the logic or English of what you write, but never mind :) A QSpinBox has a pair of "scroll arrows" at the right but it is not a "scrollbar". These are for inc/decrementing the number value and have nothing to do with scrolling or sizing. A QLineEdit is for entering text (rather than number), is single line and has no scrollbars. A QTextEdit or QPlainTextEdit is for multiline text, can be resized vertically and can have scrollbars. There are two ways of adding a layout to a widget in Designer. Each widget can have a layout set by right-clicking on it and selecting Layout > menu item. However for unknown/inexplicable reason this is only enabled when the parent widget has had at least one child widget placed on it, you cannot do it before you add any child widget, which is rather odd. Alternatively there are explicit layout items available at the top of the all the items you can drag from the left-hand side toolbar, these can be dragged and placed anytime. I have never understood/investigated whether there is any difference in result between these two methods. With layouts there should be no "overlapping", it is their job to prevent this. One tip: If you look at the Object Explorer --- the pane at the right which shows all your placed widgets in their hierarchy --- you will see a "red no entry" symbol on any widgets you have created which do not have a layout but should have. If you see that you know you should be adding a layout there.
  • How can I call the const method variant on a Qt object from Python?

    Unsolved qt for python pyside
    3
    0 Votes
    3 Posts
    431 Views
    K
    Thanks for clarifying. I suspected this would be the case but I thought it was worth asking the question.
  • Python 3.14 timeline

    Unsolved
    4
    0 Votes
    4 Posts
    460 Views
    F
    Qt for Python 6.10.1 /6.11 will support Python 3.14
  • QGraphicsAnchorLayout quirks and UI bugs.

    Unsolved pyside2 qt for python
    1
    0 Votes
    1 Posts
    181 Views
    No one has replied
  • QtQuick.VectorImage in PySide6

    Unsolved
    8
    0 Votes
    8 Posts
    1k Views
    SGaistS
    @usymbiote you can check the bug report system. If there's nothing related yet, please open a new ticket.
  • looking for a code editor widget for Qt for Python

    Unsolved
    9
    1 Votes
    9 Posts
    3k Views
    RokeJulianLockhartR
    @nutrx, work is being made toward this at invent.kde.org/frameworks/ktexteditor/-/issues/24 and its superordinate issue.
  • No suitable kits found

    Unsolved
    2
    0 Votes
    2 Posts
    333 Views
    jsulmJ
    @Milosz said in No suitable kits found: How to fix the problem? By manually adding your Python installation in Python/Interpreter in QtCreator settings.
  • PySide vs PyQt ui file load.

    Unsolved pyside
    8
    0 Votes
    8 Posts
    2k Views
    JonBJ
    @swoiwode Yes, you have made the right changes! Note how you changed from PyQt6.uic.loadUi(ui_file, self), which loaded into self and gave you self.label etc. over to self.ui = PySide6.QtUiTools.QUiLoader().load(ui_file), which returned into a newly created self.ui (or whatever you choose to call it) and hence gave you self.ui.label etc. It's just a different way of doing things, and PySide just does not offer that parameter or loading into self. Looking around at what examples there are on the web I found that actually even in PyQt more people had worked from self.ui = PyQt6.uic.loadUi(ui_file) which is also available and similar to the PySide way than that "non-standard" PyQt6.uic.loadUi(ui_file, self) which the code you inherited had chosen to use. Honestly you came across one of the few difference between PyQt and PySide right from the outset in the small script you were working on. 99% of the time you should find that same code simply works from PyQt to PySide.
  • Pyside on Boot2Qt in RaspberryPi5

    Unsolved
    2
    0 Votes
    2 Posts
    277 Views
    jsulmJ
    @Pritha-Suresh Since you're accessing the device via ssh you need to forward X11 if you want to run a GUI application this way, see -X ssh parameter, Also the error you get hints that you did not install X11 on the device.
  • Font clipping of custom Italic fonts

    Unsolved
    3
    0 Votes
    3 Posts
    425 Views
    M
    This was with PySide6 6.9.2, I also tried with 6.10.0 The OS is Windows 10 22H2
  • PySide on Phytec i.MX Pollux Board — Licensing and Platform Support

    Unsolved
    3
    0 Votes
    3 Posts
    466 Views
    P
    Hi! Thank you for the quick response. We are not going for deployments as of now. We will be showcasing the PySide capabalities as a product demo on Phytec Board. So two points from your response, Do we need commercial license for Pyside demo on Phytec board? Can I get more info on LGPLv3 and GPLv3? Thanks in advance!
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    1 Views
    No one has replied
  • PyQt6: QSvgWidget does not render when loading a QByteArray instead of a file

    Unsolved
    14
    0 Votes
    14 Posts
    2k Views
    JonBJ
    @ErwanM Yes, the ones there using the R"(-type construct are shown having leading & trailing newlines which will be in the resulting string. One guy does even say All the spaces and indentation and the newlines in the string are preserved. That's up to them for their examples where it doesn't matter. In your case of <?xml we simply cannot afford that. The one which starts std::string index_html=R"html( <!DOCTYPE html> would have a newline before the <!DOCTYPE html>, but maybe that is allowed, unlike for <?xml. Or maybe it isn't allowed either and they didn't check! Anyway, there we are, that's just how it is.