Python
Kate on 5: The Future of KTextEditor and Kate Part
Kate in 4.11
A rich python console and more in Kate editor
I have done some improvements in the plugins: python_console_ipython, python_autocomplete, python_utils, js_utils, xml_pretty and django_utils. These plugins I added a month and a half ago (except python_console_ipython) to the kate repository. I have done two improvements and a new feature:
- Now they work with Python2 and Python3 (except python_autocomplete, this only works with Python2, due pysmell dependence)
- Now they have a configuration page (except python_autocomplete, this should not have configuration parameters)
New plugins to the Kate, utils to: Python, JavaScript, Django and XML
Python plugin gets support for Python3
Being vaguely aware that Python3 had some “interesting” differences compared to Python2, I had decided to not think about Python3 for now, but then one of our dear users piped up to say that even building it was broken! That seemed weird, so I started poking around only to find myself falling Alice-like into a Wonderland where strings were not always strings…
Well, I’ve long been interested in i18n and l10n in all their forms, especially as they apply to Indic languages, so I was somewhat aware of the sorts of issues that Unicode can throw up. Luckily, as a KDE developer I’m used to depending on QString handle all the routine grunt work so it was a bit of a rude awakening to discover that, the C API for Python strings takes many forms:
Read MoreID + etags > ID || etags
Python plugin developer guide, part 1
I’m a Python newbie, so if you are at least that good :-D, you should be able to dive in and write useful Python plugins for your favourite editor too! This is the first in what I hope will be a series of notes and tutorials to help you along the way.
Where can I find examples to steal from inspire me?
Any good developer knows that a good way to launch into a new area is to look at examples, so here is a list of places I’ve encountered.
Read MorePython plugin user guide
KDE 4.9 has branched, and so the Pâté plugin “host” for Python plugins has moved from Kate’s playground to be a mainstream plugin. Since a plugin-for-plugins might be a bit confusing, here is a quick tour of how it is managed and works, and especially a few rough edges it still has.
NOTE If you’ve installed this from a package, hopefully your distro will have added kate.so under PyKDE4 as needed, but if you are building from source, see the notes at the end of this post.
Read More