예제 #1
0
파일: view.c 프로젝트: Aracturat/Tetris
void view_border_area(int x0,int y0,int x,int y)
{
	view_line_right(y0,x0,x);
	view_line_right(y,x0,x);
	view_line_down(x0,y0,y);
	view_line_down(x,y0,y);
}
예제 #2
0
파일: main.c 프로젝트: SUMPaul/vis
static const char *cursors_new(Vis *vis, const char *keys, const Arg *arg) {
	View *view = vis_view(vis);
	size_t pos = view_cursor_get(view);
	Cursor *cursor = view_cursors_new(view);
	if (cursor) {
		view_cursors_to(cursor, pos);
		if (arg->i > 0)
			view_line_down(cursor);
		else if (arg->i < 0)
			view_line_up(cursor);
	}
	return keys;
}