Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-634

No (obvious) way of emitting a signal with a named parameter to QML

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • P2: Important
    • Resolution: Done
    • 5.6, 5.9, 5.11.2
    • 5.12.5, 5.13.1
    • Documentation, PySide
    • 1b77fc5931bf14b2a9e936a8d08334d9e00ffe7e (pyside/pyside-setup/5.12)

    Description

      In PyQt5 you would do:

      from PyQt5.QtCore import pyqtSignal
      
      sumResult = pyqtSignal(int, arguments=['sum'])
      sumResult.emit(42)
      

      And then in QML:

      onSumResult: console.log(sum)
      

      Attachments

        1. main.qml
          0.5 kB
        2. pyside-634.py
          0.6 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            crmaurei Cristian Maureira-Fredes
            cbenhagen Ben Hagen
            Votes:
            3 Vote for this issue
            Watchers:
            11 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes