Skip to content

Language Bindings

You're using Qt with other languages than C++, eh? Post here!
850 Topics 3.3k Posts
  • 0 Votes
    1 Posts
    3k Views
    No one has replied
  • Using vendor-supplied JAR file with Necessitas

    1
    0 Votes
    1 Posts
    870 Views
    No one has replied
  • 0 Votes
    2 Posts
    2k Views
    O

    I have found the cause. The highlighter instance is destroyed when initUI() terminates. This line fixes the problem on line 52:

    @ self.myHighlighter = highlighter.Highlighter(codeTextEdit.document())@

  • 0 Votes
    7 Posts
    3k Views
    R

    thanks for your tips !!!
    [quote author="bootchk" date="1365163715"]Expounding on SGaist's reply.... Usually a project such as PySide has an IRC channel. Some of the key developers usually hang out on (monitor) that channel. (Although it can get clogged with hanger's on, who don't contribute much.) Usually the channel is for people who are willing to attempt to fix a bug, or otherwise contribute documentation or source code. You shouldn't report bugs on the IRC channel. You must be polite. Don't ask trivial questions that you could answer yourself by browsing the source code (although you can ask where to begin looking.) If you do ask a question, just come right out and ask it as simply and briefly as you can. No need to explain why you want to know, or to introduce yourself. In this case, it MIGHT be fair to ask "Where should I report a bug in the PySide documentation." At this point I think it is already clear that it is a bug (and since it is in the documentation, relatively low priority for most developers, except for the one developer who might be in charge of the documentation.) If you ask, "Isn't this a bug?", it might be received as a complaint. It might be better if you are willing to attempt to fix the bug and ask "Where is the code that generates PySide documentation." I could be wrong, I am speaking from my limited experience with the Gimp project. I have no experience with the PySide project or channel. "But isn't this where you should report the bug?":https://bugreports.qt-project.org/browse/PYSIDE[/quote]

  • 0 Votes
    10 Posts
    7k Views
    R

    [quote author="jazzycamel" date="1364483680"]When you say "other process" do you mean an application other than your own? For example, a web browser window has been opened on top of your application? If this is the case, the simple answer to your question is that AFAIK you can't and if even if you could, you shouldn't as this would be incredibly annoying from a user perspective. What will happen is that the task bar will signal to the user via the task bar (usually by changing the colour of or flashing you apps entry) that something requires attention (your message box in this case).[/quote]
    yes,that's what I mean.thanks 4 your tips

  • Qt 5 & Python integration

    8
    0 Votes
    8 Posts
    21k Views
    M

    Maybe "this":http://stackoverflow.com/questions/261638/how-do-i-protect-python-code will help you

  • Read a qt dll from a c# gui

    5
    0 Votes
    5 Posts
    2k Views
    R

    I installed in VS2010 the "VS Add-in with Qt5". In my vs2010 solution i have the project of the qt dll ("Qt Library" created inside VS2010), correctly compiled and linked.

    so i have done right.

    I post i piece of the interface:

    #ifdef COMMQT_LIB

    define EXAMPLEUNMANAGEDDLL_API Q_DECL_EXPORT

    #else

    define COMMQT_EXPORT Q_DECL_IMPORT

    #endif

    #ifdef __cplusplus

    extern "C" {
    #endif

    extern EXAMPLEUNMANAGEDDLL_API Comm* CreateCommClass();
    extern EXAMPLEUNMANAGEDDLL_API void DisposeCommClass(Comm * pObject);
    extern EXAMPLEUNMANAGEDDLL_API int CommGetNumEvents(Comm * pObject);

    #ifdef __cplusplus
    }
    #endif

    Thankyou for your reply

  • Compiling pyside for python3.3 (linux)

    2
    0 Votes
    2 Posts
    2k Views
    B

    What step is "-- Found...." an output of? It seems to me that it is just a comment of a "configure" step, where it searches for presence of dependencies. It may be that the other changes you made are accomplishing what you want, to build with libpython3.3, and that you can ignore the comment.

    (I have no experience in building PySide, I could be wrong.)

  • Missing Pyside Documentation page

    3
    0 Votes
    3 Posts
    1k Views
    R

    Note:All the lines that start with line numbers in Qt documentation for C++ are missing in The PySide class reference documentation.

    here is an example :
    https://deptinfo-ensip.univ-poitiers.fr/ENS/pyside-docs/PySide/QtGui/QMessageBox.html?highlight=qmessagebox.about#PySide.QtGui.PySide.QtGui.QMessageBox.about

    where is the four locations ???

  • PySide Python3 Properties problem

    6
    0 Votes
    6 Posts
    3k Views
    L

    You can also call the parent QObject with the super() method.

    @
    from PySide.QtCore import QObject, Property

    class MyObject(QObject):
    def init(self,startval=42):
    super().init()
    self.ppval = startval

    def readPP(self): return self.ppval def setPP(self,val): self.ppval = val pp = Property(int, readPP, setPP)

    obj = MyObject()
    obj.pp = 47
    print (obj.pp)
    @

  • Visual Development of GUI possible with pyside

    5
    0 Votes
    5 Posts
    20k Views
    L

    @ericparent, your post seems to be unrelated to the OP's discussion, but have you tried to install the windows binaries?

    Go here and click on "Get PySide": http://qt-project.org/wiki/PySide

  • 0 Votes
    2 Posts
    20k Views
    L

    I found tutorials that show you 2 different ways to do this:

    Using Python, Import PySide
    You can create the GUIs directly from a python script, just import PySide and follow the tutorials on this page: http://qt-project.org/wiki/PySideDocumentation

    Using QtCreator, PySide and PySide Tools
    You can also create the GUI in QtCreator and convert it to a python script. Follow this tutorial:
    http://qt-project.org/wiki/QtCreator_and_PySide

  • The Extension Example With PyQt4

    2
    0 Votes
    2 Posts
    2k Views
    jazzycamelJ

    In this case it does very little because the of the size of the widgets, the use of a QGridLayout() as the main layout and the fact that the dialog cannot be resized (on Mac anyway). addStretch() puts a QSpacerItem() in the layout with initial size 0 which will then expand to fill any excess space in the layout not required by the widgets (depending on QSizePolicy()'s).

    Consider (and run ;o) the following example:

    @
    from PyQt4.QtCore import *
    from PyQt4.QtGui import *

    class Widget(QWidget):
    def init(self, parent=None, **kwargs):
    QWidget.init(self, parent, **kwargs)

    l=QVBoxLayout(self) hl1=QHBoxLayout() hl1.addWidget(QPushButton("Button 1", self)) hl1.addWidget(QPushButton("Button 2", self)) hl1.addStretch() hl2=QHBoxLayout() hl2.addWidget(QPushButton("Button 1", self)) hl2.addWidget(QPushButton("Button 2", self)) l.addLayout(hl1) l.addLayout(hl2)

    if name=="main":
    from sys import argv, exit
    a=QApplication(argv)
    w=Widget()
    w.show()
    w.raise_()
    exit(a.exec_())
    @

    When the window is resized (by the user) the buttons in the first layout retain there original size position, whereas the buttons in the second layout expand to fill extra space.

    Hope this answers your question ;o)

  • Link C# DLL to Qt Project

    2
    0 Votes
    2 Posts
    2k Views
    ?

    Hi,

    Check Gerolf's post here, http://qt-project.org/forums/viewthread/6154

    Regards

  • QTJambi

    2
    0 Votes
    2 Posts
    1k Views
    T

    You seem to have a problem... what exactly is it? Why don't you contact the people listed on sourceforge as project admins directly?

  • 0 Votes
    1 Posts
    790 Views
    No one has replied
  • PySide pickle support

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • 0 Votes
    1 Posts
    820 Views
    No one has replied
  • Preparing query for QSqlQUeryModel

    10
    0 Votes
    10 Posts
    6k Views
    S

    yes!!

  • 0 Votes
    6 Posts
    4k Views
    N

    Well that is why its not clear to me.
    One thing that the user can do to avoid the problem is to click on a node but not move the mouse.
    So no dragging (mouseMoveEvent) messages get sent - this seems to clear up the cache and subsequent mouse dragging does not incorrectly reposition the element at 0,0. So it seems mouse tracking is key to the fault. I agree it looks like bug in QT but it seems to me this bug must have been found by now if it really was a bug in QT. I think QtGui.QGraphicsItem is extensively used in QT apps. So I am reluctant to raise a bug report when it is more likely that my understanding of how QT works is flawed and incomplete.

    I have tried overriding the mouse drag event and stuffing a good position in there manually - but I have not succeeded at such a draconian method as keeping my own position and trying to determine when the new pos suddenly moves close to 0 (not exactly 0 mind - which would be easy - but 0 + the mouse delta).
    @
    def mouseMoveEvent(self,event):
    print event.pos(), event.scenePos(), event.screenPos()
    QtGui.QGraphicsItem.mouseMoveEvent(self, event)@

    The other area - but I can't see how it should affect it - would be to remove all weakrefs and see if there is some collision here with the mouse dragging behaviour. But I have not done this.
    Thanks for looking.