Blog

Here I post my thoughts, QGIS tips and tricks, updates on my QGIS-related work, etc.

New QGIS plugins respository

05.03.2011 18:04 ·  GIS  ·  qgis, plugins

The new QGIS plugin repository, which was discussed at the latest developer meeting in Wrocław, is now available for testing at https://plugins.qgis.org. Everyone is welcome to try it out, login with your OSGeo ID. Any problems should be reported to https://github.com/qgis/QGIS-Django.

There is also a separate bug tracker for plugins, which can also be accessed using the OSGeo ID.

More information about the new plugin repository can be found on the QGIS Wiki.

Contributing to QGIS using git-svn

03.03.2011 20:23 ·  GIS  ·  qgis, git

At the last QGIS developer meeting in Wrocław we discussed the migration from SVN to Git. There was even a small workshop on using Git at the hackfest. The final decision on this topic has not yet been made, but it will be discussed again at the next meeting in Lisbon.

For those who want to try Git in action, there are several QGIS mirrors on GitHub (one, two) that can be used for development. Gary Sherman has written a good post on how to do this.

Another option is to use git-svn. This eliminates the need to create an account on GitHub and is a good option if you just want to try Git but still want to use your SVN working copy for a while. This is the option I chose.

First, we need to obtain sources, starting with some revision

git svn clone --revision 15000:HEAD https://svn.osgeo.org/qgis/trunk/qgis qgis

If necessary, revision 15000 can be replaced with another revision. Now you can cd into the qgis directory and use all the features of git: create local branches, make and commit changes, etc. When everything is ready to be committed back to trunk, use the following command

git svn dcommit

To synchronise with the repository, use

git svn rebase

I’ve already made my first commit this way.

Automatic stretching of the raster histogram in QGIS

01.03.2011 15:01 ·  GIS  ·  qgis, tips

QGIS allows you to save a default raster band combination, standard deviation and contrast enhancement algorithm for rasters.

But it seems that not many people use this feature. At least no one noticed that although the band combination and standard deviation can be saved, they are of no use because the saved values are not applied when the raster is loaded. There were also other problems (for example, the default band combination is 5-4-3, but the raster properties show 1-2-3) that no one reported.

All this has been around for a long time, somewhere since r13582 or even earlier. And only in r15256 were all these problems finally solved.

I’ll try to explain why you might need it and how to use it.

Read more ››

Custom plugin directories in QGIS

24.02.2011 09:04 ·  GIS  ·  qgis, plugins

A great new feature has been added in revision r15250: Tim Sutton implemented support for custom directories for C++ plugins. The directories are added one at a time, and the next time QGIS is started, it will load both the default plugins and the plugins from the specified directories. The plugins can then be activated as usual from the plugin manager.

This is useful for both users, who will find it easier to add third-party plugins, and developers. Another benefit is that there is no need to worry about copying plugins to the correct location after updates.

How the patch was applied

22.02.2011 08:06 ·  GIS  ·  qgis

The epic with the patch adding support for import and export of symbols in QGIS is finished.

The path from idea to commit was not an easy one: after creation and some testing, the patch sat on my laptop for a few days; then, after minor cosmetic improvements, it was uploaded to the QGIS trac and sat there for 5 weeks. Due to a small misunderstanding, the interested parties never got to test it and give their opinion. Finally, last Sunday I contacted Martin (the “new symbology” is his brainchild). After his reply, I had to improve the code a bit. The result can be seen in r15236.

While uploading the updated patch, I remembered another improvement. Minor, but also related to the “new symbology”, namely control over overwriting symbols with the same name. And I decided that since I started pestering Martin, I should make the most of it. The second patch was applied in r15237.

Looking forward for more such patches 😉

I hope Martin’s optimism is not in vain.

"Tip of the day" in QGIS

19.02.2011 18:35 ·  GIS  ·  qgis

In the commit 15199 Tim Sutton added tips shown on QGIS startup. Those tips can be enabled/disabled the QGIS settings.

So far, the number of tips is very small - about a dozen. Anyone who wants to can submit their tips for inclusion. The requirements are simple:

A bit earlier, in commit 15195, a separate window was added with a list of organisations that supported (and support) the project financially, i.e. sponsors.

RasterCalc 0.2

15.02.2011 18:00 ·  GIS  ·  qgis, plugins, rastercalc

I have just released RasterCalc 0.2 with conditional operators support.

Beer feedback and bug reports can be sent to the author.

P.S.: GIT is extremely powerful and easy to use.

Adding a layer list widget to a PyQGIS application

14.02.2011 09:31 ·  GIS  ·  qgis, python, howto

QGIS is not only a ready-to-use desktop GIS, but also a set of libraries that can be used to create custom GIS applications. Unfortunately, when creating such applications, developers have to implement some GUI elements from scratch. An example of such a widget is the list of loaded layers (sometimes incorrectly called a legend).

In this post I will show the process of embedding a layer list widget into a PyQGIS application. The widget was developed by Germán Carrillo and you can get the code and read how to use it in German’s post “Layer list widget for PyQGIS applications” on the GeoTux blog.

Read more ››

About QGIS again

11.02.2011 17:07 ·  GIS  ·  qgis

A guy called Alsi Yilmaz has analysed the usability of QGIS. I read it diagonally, there are some remarks that make sense, but the rest… is nonsense.

On the other hand, Marco Hugentobler made a lot of people happy: the experimental support for joined tables (I wrote about this earlier) was moved to trunk by commit 15155.

I also can’t get around to finishing a little “secret project” and publish the results.

In bad weather

08.02.2011 11:54 ·  Notes  ·  qgis

The weather is not good today. It’s thawing. Everything is melting, it’s damp and foggy. Normally, you would not want to do anything in weather like this, except maybe lie around with a book or watch a film. But no…

Since I did not get any feedback on the new tool in GdalTools for several days, I did some tests myself. After finally making sure that it works, I submitted the patch and wrote to Giuseppe. Since r15135 there is another tool available in GdalTools — gdaltindex.

I’ve slightly improved the symbology import/export patch (I wrote about it a few days ago) and submitted it too. Waiting for feedback now.

Then I started to improve the usability of the import/export dialogue of PostGIS and WMS connections. I decided not to bother with a patch (the changes are not that big) and cheekily committed everything directly to trunk.

I finally went into a frenzy and fixed a long-standing and nasty bug in RasterCalc, extended the set of available comparison operators and started updating the documentation.

P.S.: and I’m still in no mood anyway.