The text will be in the encoding set with
The string will be null-terminated, but note that it may contain 0x00
bytes (depending on the current text encoding). See
The caller is responsible for calling
pdfFreeMemory on the
Returns an empty string if there is no selection (or if there is no text in the selected region).