#include "OutputParams.h"
#include "output_latex.h"
#include "output_xhtml.h"
-#include "paragraph_funcs.h"
#include "ParagraphParameters.h"
#include "SpellChecker.h"
#include "sgml.h"
bool isTextAt(string const & str, pos_type pos) const;
- InsetCode Private::ownerCode() const
+ InsetCode ownerCode() const
{
return inset_owner_ ? inset_owner_->lyxCode() : NO_CODE;
}
}
}
- if (lyxrc.plaintext_linelen > 0
- && column > lyxrc.plaintext_linelen
+ if (runparams.linelen > 0
+ && column > runparams.linelen
&& i
&& text_[i - 1] != ' '
&& (i + 1 < int(text_.size()))
}
-bool Paragraph::forcePlainLayout() const
-{
- return inInset().forcePlainLayout();
-}
-
-
bool Paragraph::allowParagraphCustomization() const
{
return inInset().allowParagraphCustomization();
// FIXME This check should not be needed. Perhaps issue an
// error if it triggers.
- Layout const & style = forcePlainLayout() ?
+ Layout const & style = inInset().forcePlainLayout() ?
bparams.documentClass().plainLayout() : *d->layout_;
// Current base font for all inherited font changes, without any
return_value = false;
}
- if (allowcust && d->endTeXParParams(bparams, os, texrow, runparams))
+ if (allowcust && d->endTeXParParams(bparams, os, texrow, runparams)
+ && runparams.encoding != prev_encoding) {
runparams.encoding = prev_encoding;
+ if (!bparams.useXetex)
+ os << setEncoding(prev_encoding->iconvName());
+ }
LYXERR(Debug::LATEX, "Paragraph::latex... done " << this);
return return_value;
void Paragraph::collectWords()
{
pos_type n = size();
- WordLangTuple wl;
- docstring_list suggestions;
for (pos_type pos = 0; pos < n; ++pos) {
if (isWordSeparator(pos))
continue;
docstring word = asString(from, pos, AS_STR_NONE);
d->words_.insert(word);
}
- if (lyxrc.spellcheck_continuously
- && spellCheck(from, pos, wl, suggestions)) {
- for (size_t i = 0; i != suggestions.size(); ++i)
- d->words_.insert(suggestions[i]);
- }
}
}