[Qgis-developer] QGIS GRASS plugin - modules upgrade

Radim Blazek radim.blazek at gmail.com
Wed Aug 19 01:57:57 PDT 2015


On Tue, Aug 18, 2015 at 9:39 PM, Vaclav Petras <wenzeslaus at gmail.com> wrote:
>> > I wonder why UI is not generated on the fly or during compilation? To
>> > maintain manually UI in QGIS is complicated and the result will be
>> > always out-of-date. Just 2 my cents, Martin
>>
>> UI is generated on the fly when a module UI is opened. It is using
>> options description printed by GRASS module (--interface-description)
>> combined with options definition for the module in QGIS (.qgm file).
>> The additional options definition in QGIS is mainly for two purposes:
>>
>> 1) limit number of options not to frighten users, some GRASS modules
>> are also represented as multiple items with predefined options
>
> Hi Radim and Martin,
>
> I guess that one of the reasons for QGIS interface for GRASS. Anyway, is
> there a option of not using .qgm file and using --interface-description
> only? This would not only enable some of the hidden features but more
> importantly, it would enable to use of modules from GRASS GIS Addons
> repository.

I know, it was discussed. Generic UI is not currently supported, I am
considering that.

>> 2) define relations between options (e.g. type or column option
>> relation with input vector) or special options which has dedicated
>> widget in UI (e.g. GDAL/OGR input).
>
> This should be defined in GRASS GIS. If it is missing in GRASS or in the
> --interface-description then it is a bug which should be solved.
>
> Here are examples of guidependency "option attribute":
>
> https://trac.osgeo.org/grass/browser/grass/trunk/vector/v.distance/main.c#L222
> https://trac.osgeo.org/grass/browser/grass/trunk/scripts/v.what.vect/v.what.vect.py#L15

The guidependency is very welcome, but it is not available in GRASS 6.
However, qgm requires explicitly defined vector map <-> field, type
relation, I'll try to implement defaults if single vector is used.

Radim

>> It was surely difficult to keep options in sync with GRASS modules,
>> but with the new debugging tool (in master), it is possible to check
>> all options/modules with just one click.
>
> This sounds really good.
>
> Best,
> Vaclav
>
>


More information about the Qgis-developer mailing list