filestruct *top_save;
bool edittop_inside;
#ifndef NANO_TINY
- bool right_side_up = FALSE;
+ bool do_mark_shift = FALSE;
#endif
assert(file_top != NULL && file_bot != NULL);
#ifndef NANO_TINY
- if (openfile->mark_set) {
- filestruct *top, *bot;
- size_t top_x, bot_x;
-
- mark_order((const filestruct **)&top, &top_x,
- (const filestruct **)&bot, &bot_x, &right_side_up);
- }
+ if (openfile->mark_set)
+ do_mark_shift = (openfile->current_x <= openfile->mark_begin_x);
#endif
/* Partition the filestruct so that it contains no text, and keep
#ifndef NANO_TINY
if (openfile->mark_set) {
openfile->mark_begin = openfile->current;
- if (!right_side_up)
+ if (do_mark_shift)
openfile->mark_begin_x += openfile->current_x;
}
#endif