Category : C Source Code
Archive   : WRAP.ZIP
Filename : READ.ME

Output of file : READ.ME contained in archive : WRAP.ZIP
This file includes five routines that may come in handy when working with
text-mode screens. They are all written in assembly language.

The following is included in the file wrap.h

/* directions for rollwrap */
#define LEFT_UP 2
#define LEFT_DOWN 3
#define RIGHT_UP 0
#define RIGHT_DOWN 1

typedef struct {
int x1, y1, x2, y2;
char attr;
} shiftwin;

void shift (shiftwin *win, int num); /* horizontal shift */
void scroll (shiftwin *win, int num); /* vertical scroll */
void roll (shiftwin *win, int num); /* vertical wrap */
void wrap (shiftwin *win, int num); /* horizontal wrap */
void rollwrap (shiftwin *win, int num, int dir); /* diagonal wrap */
/* end of wrap.h */

shift, scroll, roll, and wrap treat the parameter num as a signed integer.
rollwrap treates the parameter as unsigned. The parameter dir tells rollwrap
which directions to wrap the window.

I didn't include a shiftscroll() routine because this can easily be
accomplished by a shift followed immediately by a scroll (or vice-versa).

getscr contains internal routines called by shift, roll, wrap, and rollwrap.
These routines shouldn't be called by the application program.

The coordinates x1, y1, x2, and y2 are 1-relative, like the BGI text mode

These routines have been tested with Turbo C versions 1.0 and 1.5, but should
work equally well with Microsoft C.

Questions, comments, suggestions should be addressed to:
Jim Mischel
20 Stewart St.
Durango, CO 81301
CIS: 73717,1355

  3 Responses to “Category : C Source Code
Archive   : WRAP.ZIP
Filename : READ.ME

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: