]> git.lyx.org Git - lyx.git/blobdiff - src/tabular.h
* remove various xforms relicts, in particular:
[lyx.git] / src / tabular.h
index 6c70ed7e555c442f97bbde6ccc6e5e41b4d53fcf..77da49b087b52e6d78e45ad20bd1bd03c4e4968d 100644 (file)
@@ -23,7 +23,6 @@
 #include <iosfwd>
 #include <vector>
 
-class BufferView;
 class InsetTabular;
 class LCursor;
 class OutputParams;
@@ -128,6 +127,16 @@ public:
                ///
                SET_SPECIAL_MULTI,
                ///
+               SET_BOOKTABS,
+               ///
+               UNSET_BOOKTABS,
+               ///
+               SET_TOP_SPACE,
+               ///
+               SET_BOTTOM_SPACE,
+               ///
+               SET_INTERLINE_SPACE,
+               ///
                LAST_ACTION
        };
        ///
@@ -186,7 +195,7 @@ public:
 
        /// constructor
        LyXTabular(BufferParams const &, col_type columns_arg,
-                  row_type rows_arg, BufferView const *);
+                  row_type rows_arg);
 
        /// Returns true if there is a topline, returns false if not
        bool topLine(idx_type cell, bool onlycolumn = false) const;
@@ -204,7 +213,8 @@ public:
        ///
        bool isLastRow(idx_type cell) const;
 
-       ///
+       /// return space occupied by the second horizontal line and
+       /// interline space above row \p row in pixels
        int getAdditionalHeight(row_type row) const;
        ///
        int getAdditionalWidth(idx_type cell) const;
@@ -248,13 +258,13 @@ public:
        bool setMColumnPWidth(LCursor &, idx_type, LyXLength const &);
        ///
        void setAlignSpecial(idx_type cell, std::string const & special,
-                            Feature what);
+                            Feature what);
        ///
        LyXAlignment getAlignment(idx_type cell,
-                                 bool onlycolumn = false) const;
+                                 bool onlycolumn = false) const;
        ///
        VAlignment getVAlignment(idx_type cell,
-                                bool onlycolumn = false) const;
+                                bool onlycolumn = false) const;
        ///
        LyXLength const getPWidth(idx_type cell) const;
        ///
@@ -322,6 +332,10 @@ public:
        ///
        col_type right_column_of_cell(idx_type cell) const;
        ///
+       void setBookTabs(bool);
+       ///
+       bool useBookTabs() const;
+       ///
        void setLongTabular(bool);
        ///
        bool isLongTabular() const;
@@ -385,7 +399,7 @@ public:
        boost::shared_ptr<InsetText> getCellInset(idx_type cell) const;
        ///
        boost::shared_ptr<InsetText> getCellInset(row_type row,
-                                                 col_type column) const;
+                                                 col_type column) const;
        ///
        void setCellInset(row_type row, col_type column,
                          boost::shared_ptr<InsetText>) const;
@@ -404,7 +418,7 @@ public:
        class cellstruct {
        public:
                ///
-               cellstruct(BufferParams const &, BufferView const *);
+               cellstruct(BufferParams const &);
                ///
                cellstruct(cellstruct const &);
                ///
@@ -459,6 +473,18 @@ public:
                bool top_line;
                ///
                bool bottom_line;
+               /// Extra space between the top line and this row
+               LyXLength top_space;
+               /// Ignore top_space if true and use the default top space
+               bool top_space_default;
+               /// Extra space between this row and the bottom line
+               LyXLength bottom_space;
+               /// Ignore bottom_space if true and use the default bottom space
+               bool bottom_space_default;
+               /// Extra space between the bottom line and the next top line
+               LyXLength interline_space;
+               /// Ignore interline_space if true and use the default interline space
+               bool interline_space_default;
                /// This are for longtabulars only
                /// a row of endhead
                bool endhead;
@@ -516,6 +542,8 @@ public:
        ///
        int width_of_tabular;
        ///
+       bool use_booktabs;
+       ///
        bool rotate;
        //
        // for long tabulars
@@ -532,7 +560,7 @@ public:
 
        ///
        void init(BufferParams const &, row_type rows_arg,
-                 col_type columns_arg, BufferView const *);
+                 col_type columns_arg);
        ///
        void set_row_column_number_info();
        /// Returns true if a complete update is necessary, otherwise false