mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 01:59:02 +00:00
parent
aaa6150089
commit
5017a0a1c6
@ -369,6 +369,7 @@
|
||||
\TestPackage{subfig}
|
||||
\TestPackage{subscript}
|
||||
\TestPackage{Sweave}
|
||||
\TestPackage{tablefootnote}
|
||||
\TestPackage{tcolorbox}
|
||||
\TestPackage{textcomp}
|
||||
\TestPackage{thswitch}
|
||||
|
@ -5178,8 +5178,8 @@ Notes: The package
|
||||
footnote
|
||||
\family default
|
||||
is needed by \SpecialChar LyX
|
||||
to allow footnotes in non-floating tables and multi-page
|
||||
table headers and footers.
|
||||
to allow footnotes in description items, non-floating tables
|
||||
and multi-page table headers and footers.
|
||||
|
||||
\end_layout
|
||||
|
||||
@ -5307,6 +5307,35 @@ longtable
|
||||
to be able to output correctly multipage tables.
|
||||
\end_layout
|
||||
|
||||
\begin_layout Subsection
|
||||
tablefootnote
|
||||
\end_layout
|
||||
|
||||
\begin_layout Description
|
||||
Found:
|
||||
\begin_inset Info
|
||||
type "package"
|
||||
arg "tablefootnote"
|
||||
\end_inset
|
||||
|
||||
|
||||
\end_layout
|
||||
|
||||
\begin_layout Description
|
||||
CTAN:
|
||||
\family typewriter
|
||||
macros/latex/contrib/tablefootnote/
|
||||
\end_layout
|
||||
|
||||
\begin_layout Description
|
||||
Notes: The package
|
||||
\family sans
|
||||
tablefootnote
|
||||
\family default
|
||||
is needed by \SpecialChar LyX
|
||||
to be able to output footnotes in floating tables.
|
||||
\end_layout
|
||||
|
||||
\begin_layout Subsection
|
||||
textcomp
|
||||
\end_layout
|
||||
|
@ -122,6 +122,13 @@ InsetLayout Foot:InTitle
|
||||
EndHTMLStyle
|
||||
End
|
||||
|
||||
InsetLayout Foot:InFloatTable
|
||||
CopyStyle Foot
|
||||
LatexName tablefootnote
|
||||
Requires tablefootnote
|
||||
End
|
||||
|
||||
|
||||
InsetLayout Note:Comment
|
||||
LabelString Comment
|
||||
LatexType environment
|
||||
|
@ -975,6 +975,7 @@ char const * simplefeatures[] = {
|
||||
"forest",
|
||||
"varwidth",
|
||||
"footnote",
|
||||
"tablefootnote",
|
||||
};
|
||||
|
||||
char const * bibliofeatures[] = {
|
||||
|
@ -34,13 +34,17 @@ using namespace std;
|
||||
namespace lyx {
|
||||
|
||||
InsetFoot::InsetFoot(Buffer * buf)
|
||||
: InsetFootlike(buf), intitle_(false)
|
||||
: InsetFootlike(buf), intitle_(false), infloattable_(false)
|
||||
{}
|
||||
|
||||
|
||||
docstring InsetFoot::layoutName() const
|
||||
{
|
||||
return intitle_ ? from_ascii("Foot:InTitle") : from_ascii("Foot");
|
||||
if (intitle_)
|
||||
return from_ascii("Foot:InTitle");
|
||||
else if (infloattable_)
|
||||
return from_ascii("Foot:InFloatTable");
|
||||
return from_ascii("Foot");
|
||||
}
|
||||
|
||||
|
||||
@ -54,7 +58,13 @@ void InsetFoot::updateBuffer(ParIterator const & it, UpdateType utype)
|
||||
}
|
||||
|
||||
intitle_ = false;
|
||||
for (size_type sl = 0 ; sl < it.depth() ; ++ sl) {
|
||||
infloattable_ = false;
|
||||
bool intable = false;
|
||||
if (it.innerInsetOfType(TABULAR_CODE) != 0)
|
||||
intable = true;
|
||||
if (it.innerInsetOfType(FLOAT_CODE) != 0)
|
||||
infloattable_ = intable;
|
||||
for (size_type sl = 0 ; sl < it.depth() ; ++sl) {
|
||||
if (it[sl].text() && it[sl].paragraph().layout().intitle) {
|
||||
intitle_ = true;
|
||||
break;
|
||||
|
@ -48,6 +48,8 @@ private:
|
||||
docstring custom_label_;
|
||||
///
|
||||
bool intitle_;
|
||||
///
|
||||
bool infloattable_;
|
||||
};
|
||||
|
||||
|
||||
|
@ -3427,7 +3427,7 @@ void Tabular::validate(LaTeXFeatures & features) const
|
||||
// Tell footnote that we need a savenote
|
||||
// environment in non-long tables or
|
||||
// longtable headers/footers
|
||||
if (!is_long_tabular)
|
||||
else if (!is_long_tabular && !features.inFloat())
|
||||
features.saveNoteEnv("tabular");
|
||||
else if (!isValidRow(cellRow(cell)))
|
||||
features.saveNoteEnv("longtable");
|
||||
|
Loading…
Reference in New Issue
Block a user