[f40a309] | 1 | /*
|
---|
| 2 | =============================================================================
|
---|
| 3 | vmput.c -- video menu put functions
|
---|
| 4 | Version 3 -- 1987-03-30 -- D.N. Lynx Crowe
|
---|
| 5 | (c) Copyright 1987 -- D.N. Lynx Crowe
|
---|
| 6 |
|
---|
| 7 | vmput(sbase, row, col, ms, ma)
|
---|
| 8 | uint *sbase, rwo, col, ma;
|
---|
| 9 | char *ms[];
|
---|
| 10 |
|
---|
| 11 | Copies lines from ms, with attribute ma, to sbase at (row,col).
|
---|
| 12 |
|
---|
| 13 | vmputa(sbase, row, col, ms, ma)
|
---|
| 14 | uint *sbase, row, col, *ma;
|
---|
| 15 | char *ms[];
|
---|
| 16 |
|
---|
| 17 | Copies lines from ms, with attributes from ma, to sbase at (row,col).
|
---|
| 18 | =============================================================================
|
---|
| 19 | */
|
---|
| 20 |
|
---|
[b28a12e] | 21 | #include "ram.h"
|
---|
[f40a309] | 22 |
|
---|
| 23 | /*
|
---|
| 24 | =============================================================================
|
---|
| 25 | vmput(sbase, row, col, ms, ma) -- put a menu item in a screen image.
|
---|
| 26 | Copies lines from ms, with attribute ma, to sbase at (row,col).
|
---|
| 27 | =============================================================================
|
---|
| 28 | */
|
---|
| 29 |
|
---|
[7258c6a] | 30 | void vmput(uint16_t *sbase, uint16_t row, uint16_t col, uint16_t ma, int8_t *ms[])
|
---|
[f40a309] | 31 | {
|
---|
[7258c6a] | 32 | register uint16_t c, tc, tr;
|
---|
| 33 | int8_t *cp;
|
---|
[f40a309] | 34 |
|
---|
| 35 | tr = row;
|
---|
| 36 |
|
---|
| 37 | while (cp = *ms++) {
|
---|
| 38 |
|
---|
| 39 | tc = col;
|
---|
| 40 |
|
---|
| 41 | while (c = *cp++)
|
---|
| 42 | vputc(sbase, tr, tc++, c, ma);
|
---|
| 43 |
|
---|
| 44 | tr++;
|
---|
| 45 | }
|
---|
| 46 | }
|
---|
| 47 |
|
---|
| 48 | /* |
---|
| 49 | */
|
---|
| 50 |
|
---|
| 51 | /*
|
---|
| 52 | =============================================================================
|
---|
| 53 | vmputa(sbase, row, col, ms, ma) -- put a menu item in a screen image.
|
---|
| 54 | Copies lines from ms, with attributes from ma, to sbase at (row,col).
|
---|
| 55 | =============================================================================
|
---|
| 56 | */
|
---|
[7258c6a] | 57 |
|
---|
[f40a309] | 58 | void vmputa(uint16_t *sbase, uint16_t row, uint16_t col, uint16_t *ma[], int8_t *ms[])
|
---|
[7258c6a] | 59 | {
|
---|
| 60 | register uint16_t c, tc, tr;
|
---|
| 61 | uint16_t *tm;
|
---|
[f40a309] | 62 | int8_t *cp;
|
---|
| 63 |
|
---|
| 64 | tr = row;
|
---|
| 65 |
|
---|
| 66 | while (cp = *ms++) {
|
---|
| 67 |
|
---|
| 68 | tc = col;
|
---|
| 69 | tm = *ma++;
|
---|
| 70 |
|
---|
| 71 | while (c = *cp++)
|
---|
| 72 | vputc(sbase, tr, tc++, c, *tm++);
|
---|
| 73 |
|
---|
| 74 | tr++;
|
---|
| 75 | }
|
---|
| 76 | }
|
---|