home *** CD-ROM | disk | FTP | other *** search
- #include <graphics.h>
-
- main()
- {
- int c, i, mx, my;
- char buf[100];
- GrSetMode(GR_default_graphics);
- c = GrAllocColor(255, 255, 0);
- mx = GrSizeX()/2;
- my = GrSizeY()/2;
- GrLine(0, 0, mx, my, c);
- sprintf(buf, "(%d,%d)", mx, my);
- GrTextXY(mx, my, buf, GrWhite(), GrBlack());
- getkey();
- GrSetMode(GR_default_text);
- }
-