InsetMathSideset(Buffer * buf, bool scriptl, bool scriptr,
MathAtom const & at);
///
- mode_type currentMode() const { return MATH_MODE; }
+ mode_type currentMode() const override { return MATH_MODE; }
///
- void metrics(MetricsInfo & mi, Dimension & dim) const;
+ void metrics(MetricsInfo & mi, Dimension & dim) const override;
///
- void draw(PainterInfo & pi, int x, int y) const;
+ void draw(PainterInfo & pi, int x, int y) const override;
///
- void metricsT(TextMetricsInfo const & mi, Dimension & dim) const;
+ void metricsT(TextMetricsInfo const & mi, Dimension & dim) const override;
///
- void drawT(TextPainter & pi, int x, int y) const;
+ void drawT(TextPainter & pi, int x, int y) const override;
/// move cursor backwards
- bool idxBackward(Cursor & cur) const;
+ bool idxBackward(Cursor & cur) const override;
/// move cursor forward
- bool idxForward(Cursor & cur) const;
+ bool idxForward(Cursor & cur) const override;
/// move cursor up or down
- bool idxUpDown(Cursor & cur, bool up) const;
- /// Target pos when we enter the inset while moving forward
- bool idxFirst(Cursor & cur) const;
- /// Target pos when we enter the inset while moving backwards
- bool idxLast(Cursor & cur) const;
+ bool idxUpDown(Cursor & cur, bool up) const override;
+ /// The index of the cell entered while moving backward
+ size_type lastIdx() const override { return 0; }
/// write LaTeX and Lyx code
- void write(WriteStream & os) const;
+ void write(TeXMathStream & os) const override;
/// write normalized content
- void normalize(NormalStream &) const;
+ void normalize(NormalStream &) const override;
/// write content as MathML
- void mathmlize(MathStream &) const;
+ void mathmlize(MathMLStream &) const override;
/// write content as HTML
- void htmlize(HtmlStream &) const;
+ void htmlize(HtmlStream &) const override;
/// returns nucleus
MathData const & nuc() const { return cell(0); }
/// top right index or single right cell
MathData & tr() { return cell(2 + scriptl_ + scriptr_); }
/// say that we have scripts
- void infoize(odocstream & os) const;
+ void infoize(odocstream & os) const override;
///
- InsetCode lyxCode() const { return MATH_SCRIPT_CODE; }
+ InsetCode lyxCode() const override { return MATH_SCRIPT_CODE; }
///
- void validate(LaTeXFeatures &features) const;
+ void validate(LaTeXFeatures &features) const override;
private:
- virtual Inset * clone() const;
+ Inset * clone() const override;
/// returns x offset of nucleus
int dxn(BufferView const & bv) const;
/// returns width of nucleus if any