Ling Li's patch + small stuff

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@6359 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
André Pönitz 2003-03-06 08:10:50 +00:00
parent 09ee1f5664
commit 4bb1522fa6
6 changed files with 30 additions and 6 deletions

View File

@ -1,3 +1,12 @@
2003-03-05 Ling Li <ling@caltech.edu>
* math_casesinset.[Ch] (validate): request feature "amsmath"
2003-03-04 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
* math_braceinset.C (metrics): fix computation of descent
2003-03-04 Angus Leeming <leeming@lyx.org>
* command_inset.[Ch] (createDialogStr): a new function to generate

View File

@ -140,7 +140,12 @@ void InsetFormulaBase::handleFont
}
// Check if uses AMS macros
BufferView * InsetFormulaBase::view() const
{
return view_.lock().get();
}
void InsetFormulaBase::validate(LaTeXFeatures &) const
{}

View File

@ -49,6 +49,8 @@ public:
public:
///
// Don't use this for AMS validation as long as there is no
// user-accessible way to override "false positives"
virtual void validate(LaTeXFeatures &) const;
///
virtual Inset * clone(Buffer const &, bool same_id = false) const = 0;
@ -89,11 +91,8 @@ public:
///
virtual void updateLocal(BufferView * bv, bool mark_dirty);
///
#warning move this to formulabase.C (Lgb)
// And shouldn't this really return a shared_ptr<BufferView> instead?
BufferView * view() const {
return view_.lock().get();
}
BufferView * view() const;
///
virtual bool searchForward(BufferView *, string const &,

View File

@ -5,6 +5,7 @@
#include "math_parser.h"
#include "math_mathmlstream.h"
#include "math_support.h"
#include "LaTeXFeatures.h"
#include "support/LOstream.h"
@ -65,3 +66,10 @@ void MathCasesInset::infoize(std::ostream & os) const
{
os << "Cases ";
}
void MathCasesInset::validate(LaTeXFeatures & features) const
{
features.require("amsmath");
MathGridInset::validate(features);
}

View File

@ -5,6 +5,7 @@
#include "math_gridinset.h"
class LaTeXFeatures;
class MathCasesInset : public MathGridInset {
public:
@ -25,6 +26,8 @@ public:
void maple(MapleStream &) const;
///
void write(WriteStream & os) const;
///
void validate(LaTeXFeatures & features) const;
};
#endif

View File

@ -331,7 +331,7 @@ void MathHullInset::validate(LaTeXFeatures & features) const
features.require("boldsymbol");
//features.binom = true;
MathNestInset::validate(features);
MathGridInset::validate(features);
}