+ if(edit_pos>0)
+ set_edit_position(edit_pos-1);
+ }
+ else if(nav==NAV_RIGHT)
+ {
+ if(edit_pos<text.size())
+ set_edit_position(edit_pos+1);
+ }
+ else if(nav==NAV_DOWN && multiline)
+ {
+ unsigned row, col;
+ text.offset_to_coords(edit_pos, row, col);
+ set_edit_position(text.coords_to_offset(row+1, col));
+ }
+ else if(nav==NAV_UP && multiline)
+ {
+ unsigned row, col;
+ text.offset_to_coords(edit_pos, row, col);
+ set_edit_position(row>0 ? text.coords_to_offset(row-1, col) : 0);
+ }
+ else if(nav==NAV_ACCEPT && !signal_enter.empty())
+ signal_enter.emit();
+ else
+ return false;
+
+ return true;
+}
+
+void Entry::animate(const Time::TimeDelta &)
+{
+ cursor_blink = !cursor_blink;
+ rebuild();
+}
+
+void Entry::on_geometry_change()
+{
+ if(multiline)
+ check_view_range();
+}
+
+void Entry::on_style_change()
+{
+ text.set_style(style);
+
+ if(!style)
+ {
+ text_part = 0;
+ return;
+ }
+
+ text_part = style->get_part("text");