Skip to content

Language Bindings

You're using Qt with other languages than C++, eh? Post here!
853 Topics 3.3k Posts
  • 0 Votes
    4 Posts
    2k Views
    B

    I concur with you that the errors are harmless to the install. Its an open source project: it is low priority for them to port the examples to Python 3. I don't know how to read the install scripts to know whether the success of the installation is conditional on successful interpretation by Python 3 of the examples. Probably not, since you will find whether the install was successful soon enough as you try PySide with your real code. Your post is good to know (for others who will be trying Python3 soon) but I wouldn't file a bug report, the PySide project probably knows already.

  • 0 Votes
    1 Posts
    980 Views
    No one has replied
  • 0 Votes
    2 Posts
    1k Views
    B

    I can confirm that the QPrintDialog used as above does work (whereas modally it did not) on Qt 4.8.2(?). So my question is now academic, about how Qt signals in PySide would bind the string parameter to QPrintDialog.open() to a method.

    Also, in OSX, the dialog appears hung down off the mainwindow title bar, and IS non-modal in the sense that the app still gets events in the main window that is not obscured by the print dialog. So now I need to read up on whether the fact that the dialog will not go behind the main window, or say off to the side, is a feature of OSX in general for all non-modal dialogs, or just a feature of their native print dialog. If I open a second non-modal dialog (but not a native OSX dialog), where will it appear?

    Can you say that as far as Qt is concerned, the dialog is non-modal, but as a native OSX dialog, it has a restricted sense of non-modal? Is there another word for such behaviour, such as pull-down dialog, or tear-off (I'm not sure it will tear off?)

    My original attempt to make the dialog modal is laziness? Now I must test that anything the user does while the print dialog is open has no harmful effect. Including testing that if the user asks to print again, another print dialog should not open.

  • 'Large' program structure - basic concepts

    2
    0 Votes
    2 Posts
    2k Views
    B

    First, are you talking about instances or classes?

    If instances: Although the general rule is: don't use global variables... sometime you do. (After all, if instances 'know' about other instances, they do, you can't pretend they don't, but you could pass them around in parameters.) Commonly, in a config.py module at the top. For example, mainWindow=None in that module. The module creating the main window would:

    @import config
    ...
    config.mainWindow = QMainWindow()@

    If classes, search for 'circular import problem.' Best to avoid, generally by rearranging your classes, but sometimes you solve by doing imports at the bottom of a module.

  • 0 Votes
    1 Posts
    2k Views
    No one has replied
  • Corelation with Hardware

    13
    0 Votes
    13 Posts
    3k Views
    SGaistS

    Please open a new thread when you have new questions

    Look at QFile and the xml module

  • PySide Menu not working

    3
    0 Votes
    3 Posts
    4k Views
    SGaistS

    Hi,

    IIRC from my pythonic days, you were replacing the function centralWidget with you widget object.

    As a side note, QMainWindow has a default menu bar that you can use so you don't need to create you own.

  • How to make a modal dialog?

    3
    0 Votes
    3 Posts
    2k Views
    R

    Thankfully, I found the answer "somewhere else":http://stackoverflow.com/questions/5874025/pyqt4-how-to-show-a-modeless-dialog...

    @ ldlg = LegendDialog(self)
    ldlg.show()@

  • Using QT Designer with PyQT

    4
    0 Votes
    4 Posts
    7k Views
    T

    Working further with it and adding pushbuttons, the two boxes ignoring their geometry means the pushbuttons get added ON TOP OF the boxes instead of beside them.

    http://i.imgur.com/19ZMm7y.png

  • Newbie help - display album art with PyQT

    14
    0 Votes
    14 Posts
    9k Views
    T

    will make a new topic.

    Thanks for everyone's help in this instance. It was solved.

  • Java with qt

    1
    0 Votes
    1 Posts
    798 Views
    No one has replied
  • Sublime Text 2/3 PySide plugin

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • 0 Votes
    6 Posts
    8k Views
    N

    I was looking for a solution without having to involve images.

    But I'll use this for my last resort. Thanks so much!!

  • Detect all the network erroneous cases with Qt

    2
    0 Votes
    2 Posts
    1k Views
    B

    Enough to do what? You will get every error because you check on !NoError. What else can happen then?

    Please be a bit more specific in your questions. It is hard to help when information is missing!

  • 0 Votes
    3 Posts
    4k Views
    R

    thanks , jazzycamel,you're a very kind-hearted person .
    you said
    [quote author="jazzycamel" date="1374860919"] What you see as making the app more 'user friendly' actually breaks with the key concepts of user expectation and OS native behaviours that Qt promotes.
    [/quote]

    I am curious how you learned of this ?

    for this question ,I found another solution ,code here
    @
    def changeEvent(self, event):
    if event.type()==QEvent.ActivationChange:
    self.textEdit.setFocus()
    @

    as for you solution , I also thought of that, but there is some problem with it when you type words into the textEdit using a input software ,for example ,I use "Sogou Pinyin":http://en.wikipedia.org/wiki/Sogou_Pinyin
    ,I don’t know why the problem occurred …
    Thanks anyway.

  • 0 Votes
    8 Posts
    12k Views
    E

    At least thousands times better then what I did up to now.
    It's took me several month to decide which framework to use for the change but I think I took the right one. Not sorry up to now.

    Sorry for off-topic. I'm just astonished how easy live can be.

    Greetings from Germany!
    Stefanie

  • PySide: QxtGlobalShortcut for HotKeys?

    1
    0 Votes
    1 Posts
    914 Views
    No one has replied
  • 0 Votes
    5 Posts
    5k Views
    R

    [quote author="jazzycamel" date="1374250349"]Increasing dy will have the desired effect, try replacing line 24 with:

    @
    dy=((-event.delta()/8)/15)*vsb.singleStep()*3
    @

    You may just have to tweak this a little until you get the desired result.[/quote]

    thanks , jazzycamel ! your suggestion is always constructive !

    this question has also stuck me for a few days ,can youhave a look ?thanks a lot !!!
    http://qt-project.org/forums/viewthread/30256/

  • 0 Votes
    1 Posts
    5k Views
    No one has replied
  • Pyside problem

    1
    0 Votes
    1 Posts
    926 Views
    No one has replied