[Qgis-user] Updating composer label text

James Stott James.Stott at npaconsult.co.uk
Thu Jun 21 06:28:47 PDT 2012


I am writing a plugin that replaces the text of a composer label based
on its itemID. 

When I try to change the text of the label using:

item.setText("Hello World")

The label changes on the composer but the text in the Item Properties
panel for the label doesn't, it stays as what it was originally.

If I call item.displayText() before and after I change the label text
this returns the correct information.

How do I get the text to change in the Item Properties panel? Using qgis
1.8.

James Stott BSc (Hons) MSc | Senior Professional
Nicholas Pearson Associates | 30 Brock Street | Bath | BA1 2LN
T: 01225 445548 | M: -
http://www.npaconsult.co.uk/ 

http://www.npaconsult.co.uk/http://www.npaconsult.co.uk/about-news.asp

http://www.npaconsult.co.uk/terms.asp
This Electronic Transmission is intended only for the attention of the addressee. It may contain privileged and confidential information. If you are not the person for whom it is intended, you must not copy, distribute or take any action in reliance on it. If you have received this electronic transmission in error please notify us immediately by telephone, delete the transmission and destroy any hard copies.
Nicholas Pearson Associates has used all reasonable efforts to ensure that this message and any attachments are free from viruses.
Nicholas Pearson Associates, 30 Brock Street, Bath, BA1 2LN , Tel: +44 (0) 01225 445548, Fax: +44 (0) 01225 312387, Website: http://www.npaconsult.co.uk/



More information about the Qgis-user mailing list