X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fmathed%2FMathMacro.h;h=050abe1849d4b2d3e432df0527c95fad91d0c08e;hb=565475a43917af9c52a3d9d8272e020160d0b971;hp=48acb298cf8dec689a108676440466dfbf81a7fd;hpb=12314897982e07afd8926c997f66d7bb08e7e1fd;p=lyx.git diff --git a/src/mathed/MathMacro.h b/src/mathed/MathMacro.h index 48acb298cf..050abe1849 100644 --- a/src/mathed/MathMacro.h +++ b/src/mathed/MathMacro.h @@ -58,15 +58,15 @@ public: virtual bool notifyCursorLeaves(Cursor &); /// Remove cell (starting from 0) - void removeArgument(size_t pos); + void removeArgument(pos_type pos); /// Insert empty cell (starting from 0) - void insertArgument(size_t pos); + void insertArgument(pos_type pos); /// void validate(LaTeXFeatures &) const; /// - void MathMacro::write(WriteStream & os) const; + void write(WriteStream & os) const; /// void maple(MapleStream &) const; /// @@ -87,6 +87,7 @@ public: enum DisplayMode { DISPLAY_INIT, + DISPLAY_NONGREEDY_INIT, DISPLAY_UNFOLDED, DISPLAY_NORMAL, }; @@ -111,7 +112,7 @@ public: } /// - int optionals() const { return optionals_; } + size_t optionals() const { return optionals_; } /// void setOptionals(int n) { if (n <= int(nargs())) @@ -121,6 +122,7 @@ public: protected: friend class MathData; friend class ArgumentProxy; + friend class Cursor; /// update the display mode (should only be called after detaching arguments) void setDisplayMode(DisplayMode mode); @@ -158,9 +160,9 @@ private: /// number of arguments that were really attached size_t attachedArgsNum_; /// cursor position during last draw - int previousCurIdx_; + idx_type previousCurIdx_; /// optional argument attached? (only in DISPLAY_NORMAL mode) - int optionals_; + size_t optionals_; /// fold mode to be set in next metrics call? bool nextFoldMode_; /// if macro_ == true, then here is a copy of the macro