Hi,
(some unneccessary stuff cut out to improve readability)

-------8<-------------



But AFAIK you can not load a template into it with 1.8


I think this is possible. QgsComposition has readXML and
addItemsFromXML


-------8<-------------



I did not fiddle with those 1.8 methods, but thinking about it
it should even be possible to do substitution using PyQt
methods, i.e.
1) read file
2) do substitutions
3) create the XMLDoc
4) load into composer

I will check and report back


I get an error in 1.8:
newComposition.addItemsFromXML(rootEle,  doc)
AttributeError: 'QgsComposition' object has no attribute 'addItemsFromXML'

so it seems not possible to load a template in a Python plugin in 1.8.
No problem I will wait until 2.0.

Bernhard




__________ Information from ESET Mail Security, version of virus signature 
database 8064 (20130301) __________

The message was checked by ESET Mail Security.
http://www.eset.com


_______________________________________________
Qgis-developer mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/qgis-developer

Reply via email to