| 1234567891011121314151617181920212223242526 |
- /* hello3.c
- * purpose using refresh and sleep for animated effects
- * outline initialize, draw stuff, wrap up
- */
- #include <stdio.h>
- #include <curses.h>
- main()
- {
- int i;
- initscr();
- clear();
- for(i=0; i<LINES; i++ ){
- clear();
- move( i, i+i );
- if ( i%2 == 1 )
- standout();
- addstr("Hello, world");
- if ( i%2 == 1 )
- standend();
- sleep(1);
- refresh();
- }
- endwin();
- }
|