void Entry::set_text(const string &t)
{
- text=t;
- edit_pos=text.size();
+ text = t;
+ edit_pos = text.size();
}
void Entry::set_multiline(bool m)
{
unsigned row, col;
text.offset_to_coords(edit_pos, row, col);
- edit_pos=text.coords_to_offset(row+1, col);
+ edit_pos = text.coords_to_offset(row+1, col);
}
else if(key==Input::KEY_UP && multiline)
{
unsigned row, col;
text.offset_to_coords(edit_pos, row, col);
if(row>0)
- edit_pos=text.coords_to_offset(row-1, col);
+ edit_pos = text.coords_to_offset(row-1, col);
else
- edit_pos=0;
+ edit_pos = 0;
}
else if(key==Input::KEY_BACKSPACE)
{
unsigned row, col;
text.offset_to_coords(edit_pos, row, col);
- Geometry rgeom=text.coords_to_geometry(row, col);
+ Geometry rgeom = text.coords_to_geometry(row, col);
part.get_alignment().apply(rgeom, geom, part.get_margin());
GL::push_matrix();