if (!inset->isLetter() && !inset->isChar())
break;
odocstringstream os;
- if (inset->lyxCode() == lyx::QUOTE_CODE) {
+ if (inset->lyxCode() == lyx::QUOTE_CODE || inset->lyxCode() == lyx::SPACE_CODE) {
OutputParams op(0);
op.find_set_feature(OutputParams::SearchQuick);
inset->plaintext(os, op);
int InsetSpace::plaintext(odocstringstream & os,
- OutputParams const &, size_t) const
+ OutputParams const & rp, size_t) const
{
switch (params_.kind) {
case InsetSpaceParams::HFILL:
os.put(0x2003);
return 2;
case InsetSpaceParams::THIN:
- os.put(0x202f);
+ if (rp.find_effective())
+ // simple search
+ os << ' ';
+ else
+ os.put(0x202f);
return 1;
case InsetSpaceParams::MEDIUM:
os.put(0x200b); // ZERO WIDTH SPACE, makes the unbreakable medium space breakable
return 1;
case InsetSpaceParams::PROTECTED:
case InsetSpaceParams::CUSTOM_PROTECTED:
- os.put(0x00a0);
+ if (rp.find_effective())
+ // simple search
+ os << ' ';
+ else
+ os.put(0x00a0);
return 1;
case InsetSpaceParams::NEGTHIN:
case InsetSpaceParams::NEGMEDIUM: