bool menu_window_mark(struct Menu *m) { int pos = m->line_count - m->window_begin; if (pos < m->window_pos) { m->line_count++; return false; } if (pos >= m->window_pos + m->window_size) { m->line_count++; return false; } menu_mark(m); return true; }
static VALUE rbncurs_c_menu_mark(VALUE rb_menu) { MENU *menu = get_menu(rb_menu); return rb_str_new2(menu_mark(menu)); }