diff --git a/src/Buffer.cpp b/src/Buffer.cpp index b5dc10bd56..ae6d82e94b 100644 --- a/src/Buffer.cpp +++ b/src/Buffer.cpp @@ -3144,7 +3144,8 @@ static void setLabel(Buffer const & buf, ParIterator & it) // Compute the item depth of the paragraph par.itemdepth = getItemDepth(it); - if (layout.margintype == MARGIN_MANUAL) { + if (layout.margintype == MARGIN_MANUAL + || layout.latextype == LATEX_BIB_ENVIRONMENT) { if (par.params().labelWidthString().empty()) par.params().labelWidthString(par.translateIfPossible(layout.labelstring(), bp)); } else { diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp index 87c878b192..37d2957f8d 100644 --- a/src/Paragraph.cpp +++ b/src/Paragraph.cpp @@ -1589,7 +1589,8 @@ docstring const & Paragraph::labelString() const // the next two functions are for the manual labels docstring const Paragraph::getLabelWidthString() const { - if (d->layout_->margintype == MARGIN_MANUAL) + if (d->layout_->margintype == MARGIN_MANUAL + || d->layout_->latextype == LATEX_BIB_ENVIRONMENT) return d->params_.labelWidthString(); else return _("Senseless with this layout!"); diff --git a/src/output_latex.cpp b/src/output_latex.cpp index 534bf48be4..4736530e83 100644 --- a/src/output_latex.cpp +++ b/src/output_latex.cpp @@ -169,8 +169,12 @@ TeXEnvironment(Buffer const & buf, << pit->params().labelWidthString() << "}\n"; } else if (style.labeltype == LABEL_BIBLIO) { - // ale970405 - os << '{' << bibitemWidest(buf) << "}\n"; + if (pit->params().labelWidthString().empty()) + os << '{' << bibitemWidest(buf) << "}\n"; + else + os << '{' + << pit->params().labelWidthString() + << "}\n"; } else os << from_ascii(style.latexparam()) << '\n'; texrow.newline();