Changeset View
Changeset View
Standalone View
Standalone View
src/plugins/barcode/3of9.cpp
Show First 20 Lines • Show All 171 Lines • ▼ Show 20 Line(s) | 161 | for (int i = 0; i < str.length(); i++) { | |||
---|---|---|---|---|---|
172 | for (int b = 0; b < 9; b++, space = !space) { | 172 | for (int b = 0; b < 9; b++, space = !space) { | ||
173 | qreal w = (_3of9codes[idx].values[b] == 1 ? narrow_bar * bar_width_mult : narrow_bar); | 173 | qreal w = (_3of9codes[idx].values[b] == 1 ? narrow_bar * bar_width_mult : narrow_bar); | ||
174 | //kreportpluginDebug() << w << space; | 174 | //kreportpluginDebug() << w << space; | ||
175 | if (!space) { | 175 | if (!space) { | ||
176 | ORORect * rect = new ORORect(); | 176 | ORORect * rect = new ORORect(); | ||
177 | rect->setPen(pen); | 177 | rect->setPen(pen); | ||
178 | rect->setBrush(brush); | 178 | rect->setBrush(brush); | ||
179 | rect->setRect(QRectF(pos, top, w, draw_height)); | 179 | rect->setRect(QRectF(pos, top, w, draw_height)); | ||
180 | page->addPrimitive(rect); | 180 | page->insertPrimitive(rect); | ||
181 | } | 181 | } | ||
182 | pos += w; | 182 | pos += w; | ||
183 | } | 183 | } | ||
184 | pos += interchange_gap; | 184 | pos += interchange_gap; | ||
185 | } | 185 | } | ||
186 | } | 186 | } |