QGsComposerLabel set text

المشرف العام

Administrator
طاقم الإدارة
I am building a composition with map, legend... I want to add a paragraph (text) to the composition but the text only recognize one word. What I am doing wrong?

Code:

text = QgsComposerLabel(myComposition)text.setText("Prognostico" + "\n" + "Coordinate System: ETRS89 PTTM06" + '\n' + str(self.pr))text.setFont(QFont("Cambria",15, QFont.Bold))text.setItemPosition(328.2, 72.3, 87.7,102.3)text.adjustSizeToText()#title.setFrameEnabled(True)myComposition.addItem(text) In this example only Prognostico word is showed in the layout. Why the rest doesn't appears?

Thanks



أكثر...
 
أعلى