failed attempts to intercept copy command when the cursor is in the empty text field...
[LeanCalc.git] / help / ftell
1 NAME
2     ftell - return a file position
3
4 SYNOPSIS
5     ftell(fd)
6
7 TYPES
8     fd          open file stream
9
10     return      non-negative integer or error value
11
12 DESCRIPTION
13     This function attempts to return the current value of the file position
14     indicator for the stream.  This is the number of characters (bytes)
15     between the beginning of the file and the position of the
16     next character for output in "w" or "w+" mode or for input.
17
18      On failure, this returns an error value.
19
20 EXAMPLE
21     > fd = fopen("/tmp/curds", "w")
22     > fputs(fd, "0123456789")
23     > ftell(fd)
24         10
25     > fputs(fd, "abcdef")
26     > ftell(fd)
27         16
28     > fseek(fd, 20, 0)
29     > ftell(fd)
30         20
31     > fputs(fd, "01234")
32     > ftell(fd)
33         25
34     > freopen(fd, "r")
35     > fscanf(fd, "%*5c")
36         0
37     > ftell(fd)
38         5
39
40 LIMITS
41     none
42
43 LINK LIBRARY
44     none
45
46 SEE ALSO
47     fseek, fgetpos, fsetpos, rewind, strerror
48