#include "LayoutFile.h"
#include "BranchList.h"
#include "Buffer.h"
-#include "buffer_funcs.h"
#include "Bullet.h"
#include "CiteEnginesList.h"
#include "Color.h"
#include "ColorSet.h"
#include "Converter.h"
#include "Encoding.h"
+#include "Format.h"
#include "IndicesList.h"
#include "Language.h"
#include "LaTeXFeatures.h"
#include "LaTeXFonts.h"
-#include "Length.h"
-#include "ModuleList.h"
#include "Font.h"
#include "Lexer.h"
#include "LyXRC.h"
#include "support/convert.h"
#include "support/debug.h"
-#include "support/docstream.h"
#include "support/FileName.h"
#include "support/filetools.h"
#include "support/gettext.h"
+#include "support/Length.h"
#include "support/Messages.h"
#include "support/mutex.h"
#include "support/Package.h"
listings_params = string();
pagestyle = "default";
tablestyle = "default";
+ float_alignment = "class";
+ float_placement = "class";
suppress_date = false;
justification = true;
// no color is the default (white)
html_math_output = MathML;
html_math_img_scale = 1.0;
html_css_as_file = false;
+ docbook_table_output = HTMLTable;
display_pixel_ratio = 1.0;
shell_escape = false;
}
-void BufferParams::addAuthor(Author a)
+void BufferParams::addAuthor(Author const & a)
{
author_map_[a.bufferId()] = pimpl_->authorlist.record(a);
}
branch_ptr->setColor(color);
// Update also the Color table:
if (color == "none")
- color = lcolor.getX11Name(Color_background);
+ color = lcolor.getX11HexName(Color_background);
// FIXME UNICODE
lcolor.setColor(to_utf8(branch), color);
}
index_ptr->setColor(color);
// Update also the Color table:
if (color == "none")
- color = lcolor.getX11Name(Color_background);
+ color = lcolor.getX11HexName(Color_background);
// FIXME UNICODE
if (!shortcut.empty())
lcolor.setColor(to_utf8(shortcut), color);
} else if (token == "\\html_latex_end") {
lex.eatLine();
html_latex_end = lex.getString();
+ } else if (token == "\\docbook_table_output") {
+ int temp;
+ lex >> temp;
+ docbook_table_output = static_cast<TableOutput>(temp);
} else if (token == "\\output_sync") {
lex >> output_sync;
} else if (token == "\\output_sync_macro") {
if (!lineno_opts.empty())
os << "\\lineno_options " << lineno_opts << '\n';
- if (isbackgroundcolor == true)
+ if (isbackgroundcolor)
os << "\\backgroundcolor " << lyx::X11hexname(backgroundcolor) << '\n';
- if (isfontcolor == true)
+ if (isfontcolor)
os << "\\fontcolor " << lyx::X11hexname(fontcolor) << '\n';
if (notefontcolor != lyx::rgbFromHexName("#cccccc"))
os << "\\notefontcolor " << lyx::X11hexname(notefontcolor) << '\n';
<< "\\html_css_as_file " << html_css_as_file << '\n'
<< "\\html_be_strict " << convert<string>(html_be_strict) << '\n';
+ os << "\\docbook_table_output " << docbook_table_output << '\n';
+
if (html_math_img_scale != 1.0)
os << "\\html_math_img_scale " << convert<string>(html_math_img_scale) << '\n';
if (!html_latex_start.empty())
docstring options_encodable;
Encoding const * const enc = features.runparams().encoding;
if (enc) {
- for (size_t n = 0; n < strOptions.size(); ++n) {
- char_type c = strOptions[n];
+ for (char_type c : strOptions) {
if (!enc->encodable(c)) {
docstring const glyph(1, c);
LYXERR0("Uncodable character '"
}
// only output when the background color is not default
- if (isbackgroundcolor == true) {
+ if (isbackgroundcolor) {
// only require color here, the background color will be defined
// in LaTeXFeatures.cpp to avoid interferences with the LaTeX
// package pdfpages
}
// only output when the font color is not default
- if (isfontcolor == true) {
+ if (isfontcolor) {
// only require color here, the font color will be defined
// in LaTeXFeatures.cpp to avoid interferences with the LaTeX
// package pdfpages
docstring uncodable_glyphs;
Encoding const * const enc = features.runparams().encoding;
if (enc) {
- for (size_t n = 0; n < preamble.size(); ++n) {
- char_type c = preamble[n];
+ for (char_type c : preamble) {
if (!enc->encodable(c)) {
docstring const glyph(1, c);
LYXERR0("Uncodable character '"
excludes.insert("xetex");
}
- FormatList result;
- for (auto const & b : backs) {
- FormatList r =
- theConverters().getReachable(b, only_viewable, false, excludes);
+ FormatList result =
+ theConverters().getReachable(backs[0], only_viewable, true, excludes);
+ vector<string>::const_iterator it = backs.begin() + 1;
+ for (; it != backs.end(); ++it) {
+ FormatList r = theConverters().getReachable(*it, only_viewable,
+ false, excludes);
result.insert(result.end(), r.begin(), r.end());
}
sort(result.begin(), result.end(), Format::formatSorter);
// something with formats.
if (dformat == "xhtml")
result = OutputParams::HTML;
+ else if (dformat == "docbook5")
+ result = OutputParams::DOCBOOK5;
else if (dformat == "text")
result = OutputParams::TEXT;
else if (dformat == "lyx")
}
-bool const & BufferParams::fullAuthorList() const
+bool BufferParams::fullAuthorList() const
{
return documentClass().fullAuthorList();
}