- Geometry rgeom;
- rgeom.w = static_cast<unsigned>(font.get_string_width(items[first+i])*font_size);
- rgeom.h = row_height;
- rgeom.x = margin.left;
- rgeom.y = geom.h-margin.top-(i+1)*row_height-static_cast<int>(font.get_descent()*font_size);
- part.get_alignment().apply(rgeom, pgeom);
-
- GL::push_matrix();
- GL::translate(rgeom.x, rgeom.y, 0);
- GL::scale_uniform(font_size);
- GL::Immediate imm((GL::COLOR4_UBYTE, GL::TEXCOORD2, GL::VERTEX2));
- imm.color(color.r, color.g, color.b);
- font.draw_string(items[first+i], imm);
- GL::pop_matrix();
+ if(i!=0)
+ GL::translate(0, -static_cast<int>(row_height), 0);
+ Text(*style, items[first+i]).render(part, pgeom);