Changeset View
Changeset View
Standalone View
Standalone View
src/items/label/KReportItemLabel.cpp
Show First 20 Lines • Show All 184 Lines • ▼ Show 20 Line(s) | 179 | { | |||
---|---|---|---|---|---|
185 | tb->setSize(sceneSize(size())); | 185 | tb->setSize(sceneSize(size())); | ||
186 | tb->setFont(font()); | 186 | tb->setFont(font()); | ||
187 | tb->setText(text()); | 187 | tb->setText(text()); | ||
188 | tb->setFlags(textFlags()); | 188 | tb->setFlags(textFlags()); | ||
189 | tb->setTextStyle(textStyle()); | 189 | tb->setTextStyle(textStyle()); | ||
190 | tb->setLineStyle(lineStyle()); | 190 | tb->setLineStyle(lineStyle()); | ||
191 | 191 | | |||
192 | if (page) { | 192 | if (page) { | ||
193 | page->addPrimitive(tb); | 193 | page->insertPrimitive(tb); | ||
194 | } | 194 | } | ||
195 | 195 | | |||
196 | if (section) { | 196 | if (section) { | ||
197 | OROPrimitive *clone = tb->clone(); | 197 | OROPrimitive *clone = tb->clone(); | ||
198 | clone->setPosition(scenePosition(position())); | 198 | clone->setPosition(scenePosition(position())); | ||
199 | section->addPrimitive(clone); | 199 | section->addPrimitive(clone); | ||
200 | } | 200 | } | ||
201 | 201 | | |||
202 | if (!page) { | 202 | if (!page) { | ||
203 | delete tb; | 203 | delete tb; | ||
204 | } | 204 | } | ||
205 | 205 | | |||
206 | return 0; //Item doesn't stretch the section height | 206 | return 0; //Item doesn't stretch the section height | ||
207 | } | 207 | } | ||
208 | 208 | |