home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
QBasic & Borland Pascal & C
/
Delphi5.iso
/
C
/
Samples
/
CSAPE32.ARJ
/
SOURCE
/
CSSRC
/
TEDGSTR.C
< prev
next >
Wrap
C/C++ Source or Header
|
1990-03-28
|
604b
|
36 lines
/*
tedgstr.c
% ted_GetString
C-scape 3.2
Copyright (c) 1988, by Oakland Group, Inc.
ALL RIGHTS RESERVED.
Revision History:
-----------------
3/24/89 jmd added sed_ macros
3/28/90 jmd ansi-fied
*/
#include "ted.h"
unsigned int ted_GetString(sed_type sed, char *buf, unsigned int len)
{
unsigned int glen = 0;
tb_type tb;
tb = sed_GetTextbuf(sed);
if (tb_FindPosition(tb, sed_GetTrow(sed), sed_GetTcol(sed))) {
glen = (unsigned int)bbc_Get(tb->bbc, tb->cursor - tb->offset,
buf, (long)len);
}
buf[glen] = '\0';
return(glen);
}