mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-06 00:10:59 +00:00
* src/Text.cpp (getPossibleLabel):
- remove line breaks from label proposals (fixes bug 4334) git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21489 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
a88884aaa2
commit
cd4c58fb92
@ -85,6 +85,7 @@ namespace lyx {
|
||||
|
||||
using support::bformat;
|
||||
using support::contains;
|
||||
using support::rsplit;
|
||||
using support::split;
|
||||
|
||||
using cap::cutSelection;
|
||||
@ -1274,6 +1275,10 @@ docstring Text::getPossibleLabel(Cursor & cur) const
|
||||
|
||||
docstring text;
|
||||
docstring par_text = pars_[pit].asString(cur.buffer(), false);
|
||||
string piece;
|
||||
// the return string of math matrices might contain linebreaks
|
||||
// FIXME: unicode
|
||||
par_text = from_utf8(rsplit(to_utf8(par_text), piece, '\n'));
|
||||
for (int i = 0; i < lyxrc.label_init_length; ++i) {
|
||||
if (par_text.empty())
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user