Logo Search packages:      
Sourcecode: djvulibre version File versions

bool DjVuFile::contains_text ( void   ) 

Returns TRUE# if the file contains hiddentext chunks. Known hiddentext chunks at the time of writing this help are: { TXTa}, and { TXTz}.

Definition at line 2167 of file DjVuFile.cpp.

References IFFByteStream::close_chunk(), ByteStream::create(), ByteStream::EndOfFile, and IFFByteStream::get_chunk().

Referenced by change_text().

  const GP<ByteStream> str(data_pool->get_stream());
  GUTF8String chkid;
  const GP<IFFByteStream> giff(IFFByteStream::create(str));
  IFFByteStream &iff=*giff;
  if (!iff.get_chunk(chkid))
    G_THROW( ByteStream::EndOfFile );
    if (is_text(chkid))
      return true;
  return false;

Generated by  Doxygen 1.6.0   Back to index