mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 05:16:21 +00:00
fix bug 568
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5028 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
839002cb96
commit
1776a3d0af
@ -7,7 +7,6 @@
|
||||
make sure that -lXpm is used when linking. Require LYX_PATH_XPM.
|
||||
(LYX_USE_XFORMS_IMAGE_LOADER): use XPM_LIB here
|
||||
|
||||
|
||||
2002-08-14 John Levon <levon@movementarian.org>
|
||||
|
||||
* configure.in:
|
||||
|
@ -8,6 +8,7 @@ src/converter.C
|
||||
src/CutAndPaste.C
|
||||
src/debug.C
|
||||
src/exporter.C
|
||||
src/ext_l10n.h
|
||||
src/FloatList.C
|
||||
src/frontends/controllers/biblio.C
|
||||
src/frontends/controllers/ButtonController.h
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-08-20 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
|
||||
|
||||
* text2.C (setCounter): when searching for right label for a
|
||||
caption, make sure to recurse to parent insets (so that a caption
|
||||
in a minipage in a figure float works) (bug #568)
|
||||
|
||||
2002-08-19 André Pönitz <poenitz@gmx.net>
|
||||
|
||||
|
18
src/text2.C
18
src/text2.C
@ -1339,13 +1339,23 @@ void LyXText::setCounter(Buffer const * buf, Paragraph * par) const
|
||||
|
||||
// the caption hack:
|
||||
if (layout->labeltype == LABEL_SENSITIVE) {
|
||||
bool isOK (par->inInset() && par->inInset()->owner() &&
|
||||
(par->inInset()->owner()->lyxCode() == Inset::FLOAT_CODE));
|
||||
Paragraph * tmppar = par;
|
||||
Inset * in = 0;
|
||||
bool isOK = false;
|
||||
while (tmppar && tmppar->inInset()
|
||||
// the single '=' is intended below
|
||||
&& (in = tmppar->inInset()->owner())) {
|
||||
if (in->lyxCode() == Inset::FLOAT_CODE) {
|
||||
isOK = true;
|
||||
break;
|
||||
} else {
|
||||
tmppar = in->parOwner();
|
||||
}
|
||||
}
|
||||
|
||||
if (isOK) {
|
||||
InsetFloat * tmp = static_cast<InsetFloat*>(par->inInset()->owner());
|
||||
Floating const & fl
|
||||
= floatList.getType(tmp->type());
|
||||
= floatList.getType(static_cast<InsetFloat*>(in)->type());
|
||||
|
||||
buf->counters().step(fl.name());
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user