2003-11-05 12:06:20 +00:00
|
|
|
|
// -*- C++ -*-
|
|
|
|
|
/**
|
|
|
|
|
* \file output_latex.h
|
|
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
|
*
|
|
|
|
|
* \author Lars Gullik Bj<EFBFBD>nnes
|
|
|
|
|
*
|
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#ifndef OUTPUT_LATEX_H
|
|
|
|
|
#define OUTPUT_LATEX_H
|
|
|
|
|
|
2007-07-05 19:19:41 +00:00
|
|
|
|
#include <utility>
|
|
|
|
|
|
2006-10-19 16:51:30 +00:00
|
|
|
|
#include "support/docstream.h"
|
2003-11-05 12:06:20 +00:00
|
|
|
|
|
2006-10-21 00:16:43 +00:00
|
|
|
|
|
|
|
|
|
namespace lyx {
|
|
|
|
|
|
2003-11-05 12:06:20 +00:00
|
|
|
|
class Buffer;
|
2007-01-09 19:25:40 +00:00
|
|
|
|
class BufferParams;
|
|
|
|
|
class Encoding;
|
2007-04-26 08:30:11 +00:00
|
|
|
|
class Paragraph;
|
2003-11-05 12:06:20 +00:00
|
|
|
|
class OutputParams;
|
|
|
|
|
class TexRow;
|
2008-01-25 13:27:08 +00:00
|
|
|
|
class Text;
|
2003-11-05 12:06:20 +00:00
|
|
|
|
|
2007-01-30 13:23:21 +00:00
|
|
|
|
/// Export up to \p number optarg insets
|
2008-02-27 20:43:16 +00:00
|
|
|
|
int latexOptArgInsets(Paragraph const & par,
|
2007-05-28 22:27:45 +00:00
|
|
|
|
odocstream & os, OutputParams const & runparams,
|
|
|
|
|
int number);
|
2007-01-30 13:23:21 +00:00
|
|
|
|
|
2007-01-09 19:25:40 +00:00
|
|
|
|
/** Export \p paragraphs of buffer \p buf to LaTeX.
|
|
|
|
|
Don't use a temporary stringstream for \p os if the final output is
|
|
|
|
|
supposed to go to a file.
|
|
|
|
|
\sa Buffer::writeLaTeXSource for the reason.
|
|
|
|
|
*/
|
2003-11-05 12:06:20 +00:00
|
|
|
|
void latexParagraphs(Buffer const & buf,
|
2008-01-25 13:27:08 +00:00
|
|
|
|
Text const & text,
|
2006-10-21 00:16:43 +00:00
|
|
|
|
odocstream & ofs,
|
2003-11-05 12:06:20 +00:00
|
|
|
|
TexRow & texrow,
|
|
|
|
|
OutputParams const &,
|
|
|
|
|
std::string const & everypar = std::string());
|
|
|
|
|
|
2007-12-17 10:53:38 +00:00
|
|
|
|
/// Switch the encoding of \p os from runparams.encoding to \p newEnc if needed.
|
2007-07-05 19:19:41 +00:00
|
|
|
|
/// \return (did the encoding change?, number of characters written to \p os)
|
2007-12-17 10:53:38 +00:00
|
|
|
|
std::pair<bool, int> switchEncoding(odocstream & os,
|
2007-07-05 19:19:41 +00:00
|
|
|
|
BufferParams const & bparams,
|
2007-12-17 10:53:38 +00:00
|
|
|
|
OutputParams const &, Encoding const & newEnc);
|
2006-10-21 00:16:43 +00:00
|
|
|
|
|
|
|
|
|
} // namespace lyx
|
|
|
|
|
|
2003-11-05 12:06:20 +00:00
|
|
|
|
#endif
|