[Qgis-developer] Embedding of layers and legend groups from other projects

Marco Hugentobler marco.hugentobler at sourcepole.ch
Wed Jun 8 03:11:09 EDT 2011


Hi Barry

Interesting, I didn't know about that plugin.

It seems the functionality is a bit different. The one in core embeds a 
reference into the project file (and QgsProject as well as QGIS server need to 
know how to handle referenced groups and layers). On every project load, you 
get updates if the original project has changed.

Whereas it sounds the plugin loads the layers from other projects (therefore 
copying those layer settings to the current project). Advantage here is that 
it is independant (no dependencies on external projects that could be removed 
or changed).

Depends on the use case which one to prefer.

Regards,
Marco

Am Dienstag, 7. Juni 2011, 19.58:50 schrieb Barry Rowlingson:
> On Tue, Jun 7, 2011 at 6:40 PM, Duarte Carreira <DCarreira at edia.pt> wrote:
> > Is this a coincidence?? Just last week we discussed this in #qgis and
> > spacedman started a python plugin for this same functionality... it's
> > great it's done already! I offer myself to test if you'd like... if I
> > can get my hands on a compiled version that is.
> 
>  Yeah, I just finished a pretty simple python plugin that basically
> reads <maplayer> entries from a .qgs project file XML, then puts them
> in a Qt table with the basic info (type, geometry, datasource) and a
> check box. Check the layers you want, and they get loaded into Qgis.
> 
>  Doesn't handle groups (havent tried it with project files with
> groups...) or anything else really... But it does load the layers in
> with the styling.
> 
>  A simple extension would be to load all layers from a plugin in a
> kind of 'include project' option.
> 
> Barry


-- 
Dr. Marco Hugentobler
Sourcepole -  Linux & Open Source Solutions
Churerstrasse 22, CH-8808 Pfäffikon SZ, Switzerland
marco.hugentobler at sourcepole.ch http://www.sourcepole.ch
Technical Advisor QGIS Project Steering Committee


More information about the Qgis-developer mailing list