/** * @param array $properties */ function _odtTableAddColumnUseProperties(array $properties = NULL) { // Overwrite/Create column style for actual column if $properties has any // meaningful params for a column-style (e.g. width). $table = $this->state->findClosestWithClass('table', 'table'); if ($table != NULL) { $table_column_styles = $table->getTableColumnStyles(); $auto_columns = $table->getTableAutoColumns(); $max_columns = $table->getTableMaxColumns(); $curr_column = $table->getTableCurrentColumn(); } $style_name = $table_column_styles[$curr_column]; $properties['style-name'] = $style_name; $style_obj = $this->factory->createTableColumnStyle($properties); $this->docHandler->addAutomaticStyle($style_obj); $style_name = $style_obj->getProperty('style-name'); // FIXME: check this double style name assignment... $table_column_styles[$curr_column] = $style_name; $curr_column++; $table->setTableCurrentColumn($curr_column); // Eventually add a new temp column if in auto mode if ($auto_columns === true) { if ($curr_column > $max_columns) { // Add temp column. $column_defs = $table->getTableColumnDefs(); $column_defs .= '<table:table-column table:style-name="' . $style_name . '"/>'; $table->setTableColumnDefs($column_defs); $table->setTableMaxColumns($max_columns + 1); } } }
/** * @param array $properties */ function _odtTableAddColumnUseProperties(array $properties = NULL) { // Overwrite/Create column style for actual column if $properties has any // meaningful params for a column-style (e.g. width). $style_name = $this->temp_table_column_styles[$this->temp_column]; $style_name = $this->factory->createTableColumnStyle($style, $properties, NULL, $style_name); $this->temp_table_column_styles[$this->temp_column] = $style_name; $this->autostyles[$style_name] = $style; $this->temp_column++; // Eventually add a new temp column if in auto mode if ($this->temp_autocols === true) { if ($this->temp_column > $this->temp_maxcols) { // Add temp column. $this->temp_cols .= '<table:table-column table:style-name="' . $style_name . '"/>'; $this->temp_maxcols++; } } }
/** * @param array $properties */ function _odtTableAddColumnUseProperties(array $properties = NULL) { // Overwrite/Create column style for actual column if $properties has any // meaningful params for a column-style (e.g. width). $style_name = $this->temp_table_column_styles[$this->temp_column]; $properties['style-name'] = $style_name; $style_obj = $this->factory->createTableColumnStyle($properties); $this->docHandler->addAutomaticStyle($style_obj); $style_name = $style_obj->getProperty('style-name'); // FIXME: check this double style name assignment... $this->temp_table_column_styles[$this->temp_column] = $style_name; $this->temp_column++; // Eventually add a new temp column if in auto mode if ($this->temp_autocols === true) { if ($this->temp_column > $this->temp_maxcols) { // Add temp column. $this->temp_cols .= '<table:table-column table:style-name="' . $style_name . '"/>'; $this->temp_maxcols++; } } }