]> git.lyx.org Git - lyx.git/blobdiff - src/paragraph.h
get rid of LYX_LIBS
[lyx.git] / src / paragraph.h
index d97b8c62a42ab75be979b704d4e402384a6adcbc..3a6999528e206009b402fba80e490298dac6a2f2 100644 (file)
 #include "LString.h"
 
 #include "insets/inset.h" // Just for Inset::Code
-#include "layout.h"
+#include "lyxfont.h" // Just for LyXFont::FONT_SIZE
 #include "support/types.h"
 
 class ParagraphParameters;
 class BufferParams;
 class TexRow;
-struct LaTeXFeatures;
+class LaTeXFeatures;
 class InsetBibKey;
 class BufferView;
 class Language;
@@ -123,6 +123,14 @@ public:
        Paragraph * TeXOnePar(Buffer const *, BufferParams const &,
                                 std::ostream &, TexRow & texrow,
                                 bool moving_arg);
+
+       /// 
+       int startTeXParParams(BufferParams const &, std::ostream &) const;
+
+       /// 
+       int endTeXParParams(BufferParams const &, std::ostream &) const;
+
+       
        ///
        bool simpleTeXOnePar(Buffer const *, BufferParams const &,
                             std::ostream &, TexRow & texrow, bool moving_arg);
@@ -159,8 +167,10 @@ public:
        void clearContents();
 
        ///
-       lyx::layout_type layout;
-
+       string const & layout() const;
+       ///
+       void layout(string const & new_layout);
+       
        ///
        void setCounter(int i, int v);
        ///
@@ -210,15 +220,13 @@ public:
        ///
        void setLabelWidthString(string const & s);
        ///
-       lyx::layout_type getLayout() const;
-       ///
        char getAlign() const;
-       ///
+       /// The nesting depth of a paragraph
        depth_type getDepth() const;
+       /// The maximal possible depth of a paragraph after this one
+       depth_type getMaxDepthAfter(Buffer const *) const;
        ///
-       void setLayout(lyx::layout_type new_layout);
-       ///
-       void setOnlyLayout(lyx::layout_type new_layout);
+       void applyLayout(string const & new_layout);
        ///
        int getFirstCounter(int i) const;
        ///
@@ -258,7 +266,7 @@ public:
        /// Returns the height of the highest font in range
        LyXFont::FONT_SIZE highestFontInRange(lyx::pos_type startpos,
                                              lyx::pos_type endpos,
-                                                                                 LyXFont::FONT_SIZE const def_size) const;
+                                             LyXFont::FONT_SIZE const def_size) const;
        ///
        void insertChar(lyx::pos_type pos, value_type c);
        ///
@@ -311,17 +319,14 @@ public:
        */ 
        void pasteParagraph(BufferParams const &);
 
-       /// used to remove the error messages
-       int autoDeleteInsets();
-
        /// returns -1 if inset not found
-       int getPositionOfInset(Inset * inset) const;
+       int getPositionOfInset(Inset const * inset) const;
 
        /// some good comment here John?
        Paragraph * getParFromID(int id) const;
 
        ///
-       int stripLeadingSpaces(LyXTextClassList::size_type tclass); 
+       int stripLeadingSpaces(lyx::textclass_type tclass); 
 
 #ifndef NO_PEXTRA_REALLY
        /* If I set a PExtra Indent on one paragraph of a ENV_LIST-TYPE
@@ -334,11 +339,14 @@ public:
 #endif
        ///
        bool sgmlConvertChar(char c, string & sgml_string);
+       ///
+       bool isFreeSpacing() const;
 
        ParagraphParameters & params();
        ParagraphParameters const & params() const;
 private:
-       
+       ///
+       string layout_;
        ///
        struct InsetTable {
                ///
@@ -368,6 +376,9 @@ public:
                }
                ///
                Inset * operator*() { return it->inset; }
+               ///
+               Inset * operator->() { return it->inset; }
+               
                ///
                lyx::pos_type getPos() const { return it->pos; }
                ///