#include <config.h>
-#ifdef __GNUG__
-#pragma implementation
-#endif
-
// temporary until verified (08/08/2001 Jug)
#define SPECIAL_COLUM_HANDLING 1
}
-LyXTabular::lttype::lttype()
+LyXTabular::ltType::ltType()
{
topDL = false;
bottomDL = false;
LyXTabular & LyXTabular::operator=(LyXTabular const & lt)
{
#if 0
-#warning This while method should look like this: (Lgb)
+#warning This whole method should look like this: (Lgb)
LyXTabular tmp(lt);
tmp.swap(*this);
cell_info = c_info;
++row;
for (int j = 0; j < columns_; ++j) {
- cell_info[row][j].inset.clear();
+ cell_info[row][j].inset.clear(false);
+ if (bp.tracking_changes)
+ cell_info[row][j].inset.markNew(true);
}
#endif
Reinit();
cell_info = c_info;
//++column;
for (int i = 0; i < rows_; ++i) {
- //cell_info[i][column].inset.clear();
- cell_info[i][column + 1].inset.clear();
+ cell_info[i][column + 1].inset.clear(false);
+ if (bp.tracking_changes)
+ cell_info[i][column + 1].inset.markNew(true);
}
Reinit();
}
}
-bool LyXTabular::TopAlreadyDrawed(int cell) const
+bool LyXTabular::topAlreadyDrawn(int cell) const
{
int row = row_of_cell(cell);
if ((row > 0) && !GetAdditionalHeight(row)) {
}
-bool LyXTabular::LeftAlreadyDrawed(int cell) const
+bool LyXTabular::leftAlreadyDrawn(int cell) const
{
int column = column_of_cell(cell);
if (column > 0) {
cellinfo_of_cell(cell+i)->multicolumn = CELL_PART_OF_MULTICOLUMN;
cellinfo_of_cell(cell)->inset.appendParagraphs(buffer->params,
cellinfo_of_cell(cell+i)->inset.paragraph());
- cellinfo_of_cell(cell+i)->inset.clear();
+ cellinfo_of_cell(cell+i)->inset.clear(false);
}
#else
for (number--; number > 0; --number) {
if (column_info[i].left_line)
os << '|';
if (!column_info[i].p_width.zero()) {
- switch (column_info[i].alignment) {
- case LYX_ALIGN_LEFT:
- os << ">{\\raggedright}";
- break;
- case LYX_ALIGN_RIGHT:
- os << ">{\\raggedleft}";
- break;
- case LYX_ALIGN_CENTER:
- os << ">{\\centering}";
- break;
- }
+ switch (column_info[i].alignment) {
+ case LYX_ALIGN_LEFT:
+ os << ">{\\raggedright}";
+ break;
+ case LYX_ALIGN_RIGHT:
+ os << ">{\\raggedleft}";
+ break;
+ case LYX_ALIGN_CENTER:
+ os << ">{\\centering}";
+ break;
+ case LYX_ALIGN_NONE:
+ case LYX_ALIGN_BLOCK:
+ case LYX_ALIGN_LAYOUT:
+ case LYX_ALIGN_SPECIAL:
+ break;
+ }
switch (column_info[i].valignment) {
case LYX_VALIGN_TOP:
LyXTabular::BoxType LyXTabular::UseParbox(int cell) const
{
- Paragraph * par = GetCellInset(cell)->paragraph();
+ ParagraphList const & parlist = GetCellInset(cell)->paragraphs;
+ ParagraphList::iterator cit = parlist.begin();
+ ParagraphList::iterator end = parlist.end();
- for (; par; par = par->next()) {
- for (int i = 0; i < par->size(); ++i) {
- if (par->getChar(i) == Paragraph::META_NEWLINE)
+ for (; cit != end; ++cit) {
+ for (int i = 0; i < cit->size(); ++i) {
+ if (cit->getChar(i) == Paragraph::META_NEWLINE)
return BOX_PARBOX;
}
}