[Qgis-developer] Re: PyQGIS Auto-completion and Call Tips in Eric Python Editor

Tim Sutton lists at linfiniti.com
Mon Apr 9 17:39:13 EDT 2012


Hi

On Mon, Apr 9, 2012 at 10:06 PM, G. Allegri <giohappy at gmail.com> wrote:
> I would seriously consider upgrading the Python console, first of all to
> support autocompletion. I suggested the incorporation of QScintilla a couple
> of years ago, but it didn't raise much interest.

Sometimes these things take time to gather interest....we have a much
larger python userbase and probably these ideas are more likely to
gain critical mass...


>A few weeks ago I gave a
> look to iPython, and it's Qt console [1].

Larry has a very nice simple integrated IDE plugin in the works that
also uses scintilla, which I would like to see become part of QGIS
core, so scintilla is probably a good fit (though I don't know if it
is mutually exclusive of iPython Qt).

Regards

Tim

>
> giovanni
>
> [1]  http://ipython.org/ipython-doc/dev/interactive/qtconsole.html
>
>
>
> 2012/4/9 Tim Sutton <lists at linfiniti.com>
>>
>> Hi Larry
>>
>> On Mon, Apr 9, 2012 at 5:20 AM, Larry Shaffer <larrys at dakotacarto.com>
>> wrote:
>> > On Sun, Apr 8, 2012 at 7:48 PM, Larry Shaffer <larrys at dakotacarto.com>
>> > wrote:
>> >>
>> >> Hi,
>> >>
>> >> I've successfully generated QScintilla2 API files for the QGIS Python
>> >> bindings and utility modules [0]. If you use the Eric4/5 Python editor
>> >> (or
>> >> another based on QScintilla2), you may be interested in installing and
>> >> compiling these APIs.
>> >
>> >
>> > Seems a better approach, instead of changing SIPMacros.cmake, would be
>> > in
>> > python/CMakeLists.txt [0]:
>> >
>> > --- python/CMakeLists_orig.txt    2012-02-19 13:41:41.000000000 -0700
>> > +++ python/CMakeLists.txt    2012-04-08 21:00:16.000000000 -0600
>> > @@ -54,0 +55 @@
>> > +set(SIP_EXTRA_OPTIONS ${PYQT4_SIP_FLAGS} -o -a
>> > ${CMAKE_BINARY_DIR}/python/qgis.core.api)
>> > @@ -68,0 +70 @@
>> > +set(SIP_EXTRA_OPTIONS ${PYQT4_SIP_FLAGS} -o -a
>> > ${CMAKE_BINARY_DIR}/python/qgis.gui.api)
>> > @@ -79,0 +82 @@
>> > +set(SIP_EXTRA_OPTIONS ${PYQT4_SIP_FLAGS} -o -a
>> > ${CMAKE_BINARY_DIR}/python/qgis.analysis.api)
>> >
>> > This worked fine on compile, creating the same output as the
>> > SIPMacros.cmake
>> > edit. Each SIP_EXTRA_OPTIONS could be wrapped with a conditional based
>> > on a
>> > compile option for generating the APIs.
>> >
>>
>> Two quick comments:
>>
>> 1) Could you submit your patch via github? If it is a cmake
>> conditional compilation I see no reason to exclude it from master -
>> others may have a different opinion.
>> 2) What I would really *love* is to have QGIS api completion (and
>> other standard python modules if it is easy to achieve) in the built
>> in python console that is activeated from the QGIS plugins menu. I
>> often like to demo stuff to people using the python console and always
>> flap around trying to remember syntax. Obviously this would add a
>> qsctintilla dependency to QGIS core - how do others feel about this?
>> Given the other work you are busy with that dependency is probably
>> coming anyway....
>>
>>
>> Regards
>>
>> Tim
>>
>> >
>> > Regards,
>> >
>> > Larry Shaffer
>> > Dakota Cartography
>> > Black Hills, South Dakota
>> >
>> > [0] http://dl.dropbox.com/u/4058089/qgis/CMakeLists.txt
>> >
>> > _______________________________________________
>> > Qgis-developer mailing list
>> > Qgis-developer at lists.osgeo.org
>> > http://lists.osgeo.org/mailman/listinfo/qgis-developer
>> >
>>
>>
>>
>> --
>> Tim Sutton - QGIS Project Steering Committee Member (Release  Manager)
>> ==============================================
>> Please do not email me off-list with technical
>> support questions. Using the lists will gain
>> more exposure for your issues and the knowledge
>> surrounding your issue will be shared with all.
>>
>> Visit http://linfiniti.com to find out about:
>>  * QGIS programming and support services
>>  * Mapserver and PostGIS based hosting plans
>>  * FOSS Consulting Services
>> Skype: timlinux
>> Irc: timlinux on #qgis at freenode.net
>> ==============================================
>> _______________________________________________
>> Qgis-developer mailing list
>> Qgis-developer at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/qgis-developer
>
>



-- 
Tim Sutton - QGIS Project Steering Committee Member (Release  Manager)
==============================================
Please do not email me off-list with technical
support questions. Using the lists will gain
more exposure for your issues and the knowledge
surrounding your issue will be shared with all.

Visit http://linfiniti.com to find out about:
 * QGIS programming and support services
 * Mapserver and PostGIS based hosting plans
 * FOSS Consulting Services
Skype: timlinux
Irc: timlinux on #qgis at freenode.net
==============================================


More information about the Qgis-developer mailing list