X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/842d6c94bd9fedff4799fd8e54cdb48de2fa7aa3..42d14d4e8fbcc49af37381f7b6730d70da84f2ac:/docs/latex/wx/file.tex

diff --git a/docs/latex/wx/file.tex b/docs/latex/wx/file.tex
index 655f48fcd4..8d799e648c 100644
--- a/docs/latex/wx/file.tex
+++ b/docs/latex/wx/file.tex
@@ -3,7 +3,8 @@
 A wxFile performs raw file I/O. This is a very small class designed to
 minimize the overhead of using it - in fact, there is hardly any overhead at
 all, but using it brings you automatic error checking and hides differences
-between platforms and compilers.
+between platforms and compilers. wxFile also automatically closes the file in
+its destructor making it unnecessary to worry about forgetting to do it.
 
 \wxheading{Derived from}
 
@@ -82,7 +83,7 @@ fail.
 
 \func{}{wxFile}{\param{int}{ fd}}
 
-Opens a file with the given file descriptor, which has already been opened.
+Associates the file with the given file descriptor, which has already been opened.
 
 \wxheading{Parameters}
 
@@ -98,7 +99,7 @@ Opens a file with the given file descriptor, which has already been opened.
 
 Destructor will close the file.
 
-NB: it is not virtual so you should {\it not} derive from wxFile!
+NB: it is not virtual so you should use wxFile polymorphically.
 
 \membersection{wxFile::Access}\label{wxfileaccess}
 
@@ -113,7 +114,7 @@ values of wxFile::read or wxFile::write really make sense here.
 
 Attaches an existing file descriptor to the wxFile object. Example of predefined
 file descriptors are 0, 1 and 2 which correspond to stdin, stdout and stderr (and
-have symbolic names of wxFile::fd\_stdin, wxFile::fd\_stdout and wxFile::fd\_stderr).
+have symbolic names of {\bf wxFile::fd\_stdin}, {\bf wxFile::fd\_stdout} and {\bf wxFile::fd\_stderr}).
 
 The descriptor should be already opened and it will be closed by wxFile
 object.
@@ -148,18 +149,25 @@ Returns the file descriptor associated with the file.
 
 \constfunc{bool}{Eof}{\void}
 
-Returns TRUE if the end of the file has been reached (the last byte has been read).
+Returns TRUE if the end of the file has been reached.
+
+Note that the behaviour of the file pointer based class 
+\helpref{wxFFile}{wxffile} is different as \helpref{wxFFile::Eof}{wxffileeof} 
+will return TRUE here only if an attempt has been made to read 
+{\it past} the last byte of the file, while wxFile::Eof() will return TRUE
+even before such attempt is made if the file pointer is at the last position
+in the file.
 
-Note that the behaviour of the file pointer based class
-\helpref{wxFFile}{wxffile} is different as \helpref{wxFFile::Eof}{wxffileeof}
-will return TRUE here only if an attempt has been made to read
-{\it past} the last byte of the file.
+Note also that this function doesn't work on unseekable file descriptors
+(examples include pipes, terminals and sockets under Unix) and an attempt to
+use it will result in an error message in such case.
 
 \membersection{wxFile::Exists}\label{wxfileexists}
 
 \func{static bool}{Exists}{\param{const char*}{ filename}}
 
-Returns TRUE if the given name specifies an existing regular file.
+Returns TRUE if the given name specifies an existing regular file (not a
+directory or a link)
 
 \membersection{wxFile::Flush}\label{wxfileflush}
 
@@ -444,7 +452,7 @@ Returns the current position.
 
 \membersection{wxFFile::Write}\label{wxffilewrite}
 
-\func{size_t}{Write}{\param{const void*}{ buffer}, \param{size\_t}{ count}}
+\func{size\_t}{Write}{\param{const void*}{ buffer}, \param{size\_t}{ count}}
 
 Writes the specified number of bytes from a buffer.
 
