X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FBufferParams.cpp;h=9d45d80d1034738d704496c9b275829dbbe652e1;hb=5887601f6836ebf6f2b16cc7587a98cc3aa6c391;hp=58a02c8683c6d47139efb955f679231e2f1aaf87;hpb=fe85162a29893e98bd3426d15c9a9eb62aa90f6b;p=lyx.git diff --git a/src/BufferParams.cpp b/src/BufferParams.cpp index 58a02c8683..9d45d80d10 100644 --- a/src/BufferParams.cpp +++ b/src/BufferParams.cpp @@ -21,18 +21,17 @@ #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 "ModuleList.h" #include "Font.h" #include "Lexer.h" #include "LyXRC.h" @@ -49,7 +48,6 @@ #include "support/convert.h" #include "support/debug.h" -#include "support/docstream.h" #include "support/FileName.h" #include "support/filetools.h" #include "support/gettext.h" @@ -567,7 +565,7 @@ AuthorList const & BufferParams::authors() const } -void BufferParams::addAuthor(Author a) +void BufferParams::addAuthor(Author const & a) { author_map_[a.bufferId()] = pimpl_->authorlist.record(a); } @@ -1741,8 +1739,7 @@ bool BufferParams::writeLaTeX(otexstream & os, LaTeXFeatures & features, 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 '" @@ -2184,8 +2181,7 @@ bool BufferParams::writeLaTeX(otexstream & os, LaTeXFeatures & features, 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 '" @@ -3511,7 +3507,7 @@ string const & BufferParams::defaultBiblioStyle() const } -bool const & BufferParams::fullAuthorList() const +bool BufferParams::fullAuthorList() const { return documentClass().fullAuthorList(); }