Topic : TOS - das Betriebssystem
Author :
Version : tos.hyp (5. März 2013)
Subject : Programmieren/Atari
Nodes : 3001
Index Size : 93602
HCP-Version : 5
Compiled on : Atari
@charset : atarist
@lang :
@default : Titel
@help :
@options : +g -i -s +x +zz -t4
@width : 70
View Ref-File7.5.24 Bindings für v_etext TOS
C: void v_etext( int16_t handle, int16_t x, int16_t y,
int16_t *string, int16_t *offsets);
Umsetzung:
void v_etext( int16_t handle, int16_t x, int16_t y,
int16_t *string, int16_t *offsets)
{
ptsin[0] = x;
ptsin[1] = y;
ptsin[2] = offsets[0];
ptsin[3] = offsets[2];
.
.
ptsin[2n+1] = offsets[2n-1];
i = 0;
while (intin[i++] = *string++)
;
contrl[0] = 11;
contrl[1] = length og string + 1 ;
contrl[3] = lenght of string;
contrl[4] = 11;
contrl[6] = handle;
vdi ();
}
GEM-Arrays:
Adresse Feldelement Belegung
contrl contrl[0] 11 # Opcode der Funktion
contrl+2 contrl[1] n + 1 # Einträge in ptsin
contrl+4 contrl[2] 0 # Einträge in ptsout
contrl+6 contrl[3] n # Einträge in intin
contrl+8 contrl[4] 0 # Einträge in intout
contrl+10 contrl[5] 11
contrl+12 contrl[6] handle
intin intin[0..n-1] string[0..n-1]
ptsin ptsin[0] x
ptsin+2 ptsin[1] y
ptsin+4 ptsin[2..2n+1] offsets[0..2n-1]