[PyQt] call method doesn't work if it has QScintilla instance
Detlev Offenbach
detlev at die-offenbachs.de
Sun Oct 14 14:50:45 BST 2012
Still cannot run it because sciPythonEditor.py includes this import statement
from qgis.utils import iface
Further more, the code you sent doesn have a prefChanged() method anywhere.
On Sunday 14 October 2012, 15:14:19 Salvatore Larosa wrote:
Hi,
very odd, you should be able to run it also without qgis package!
I attached a new package, Could you give a try at it ? (run
sciPythonEditor.py)
Thank you very much!
Regards,
-SL
PS: can I clone the repository to install trunk version of eric like to github
repository ? Where/How do it ?
2012/10/14 Detlev Offenbach <detlev at die-offenbachs.de>
Hello,
I don't know why it doesn't work. The code looks right (although a bit
strange). Unfortunately I am not able to debug it because it imports QGis
stuff, which I don't have, and missing files in the archive.
Regards,
Detlev
Am 14.10.2012 um 13:03 schrieb Salvatore Larosa <lrssvtml at gmail.com>:
Hi Detlev,
At the moment I'm using Aptana as IDE, but I will pass to Eric ;-)
If you are so kind to check out the attached code, you will notice the
problem. The interpreter is console.py!
the method is prefChanged() in console_sci.py which is called in
console_settings.py (accept event)
I do not understand why does not work, I make a simple call!
Thanks a lot!
-SL
2012/10/14 Detlev Offenbach <detlev at die-offenbachs.de>
Is the second method called at all? Maybe it would be a good idea to do your
coding with eric and use the eric debugger to check what's going on ;-)
Detlev
Am 14.10.2012 um 11:33 schrieb Salvatore Larosa <lrssvtml at gmail.com>:
I have a small problem in defining/calling an external method in my
application.
I have 3 files, mainapp.py, qscintilla.py and settings.py
in mainapp.py:
from qscintilla import sciEditor
from settings import dialog
in setting.py (settings dialog):
from qscintilla import sciEditor
in qscintilla.py:
scintilla instances stuff
the strange thing is that I can not call a method of sciEditor from setting
dialog which has Qscintilla instance!!
I try to be clearer:
For example, in my sciEditor class I have these methods:
def method1 (self):
print "Hello"
def method2 (self):
self.SendScintilla (QsciScintilla.SCI_CLEARALL)
self.setText ("Hello")
calling the first method from settings dialog works, the latter not!
maybe I'm missing something!!!
Any suggest is appreciate !
All the best!
-SL
--
Salvatore Larosa
linkedIn: http://linkedin.com/in/larosasalvatore
twitter: @lrssvt
skype: s.larosa
IRC: lrssvt on freenode
_______________________________________________
PyQt mailing list PyQt at riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt
Detlev Offenbach
detlev at die-offenbachs.de
--
Salvatore Larosa
linkedIn: http://linkedin.com/in/larosasalvatore
twitter: @lrssvt
skype: s.larosa
IRC: lrssvt on freenode
<consolePython.zip>
Detlev Offenbach
detlev at die-offenbachs.de
--
Salvatore Larosa
linkedIn: http://linkedin.com/in/larosasalvatore
twitter: @lrssvt
skype: s.larosa
IRC: lrssvt on freenode
--
Detlev Offenbach
detlev at die-offenbachs.de
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20121014/0d309f06/attachment.html>
More information about the PyQt
mailing list