/**
  * Calculate our padding widths from the specified table style.
  * @param TableStyle $style
  */
 public function setPaddingFromStyle(TableStyle $style)
 {
     $verticalBorderLen = strlen(sprintf($style->getBorderFormat(), $style->getVerticalBorderChar()));
     $paddingLen = strlen($style->getPaddingChar());
     $this->extraPaddingAtBeginningOfLine = 0;
     $this->extraPaddingAtEndOfLine = $verticalBorderLen;
     $this->paddingInEachCell = $verticalBorderLen + $paddingLen + 1;
 }
Beispiel #2
0
 /**
  * Gets column width.
  *
  * @param int $column
  *
  * @return int
  */
 private function getColumnSeparatorWidth()
 {
     return strlen(sprintf($this->style->getBorderFormat(), $this->style->getVerticalBorderChar()));
 }
Beispiel #3
0
 /**
  * Renders vertical column separator.
  */
 private function renderColumnSeparator()
 {
     $this->output->write(sprintf($this->style->getBorderFormat(), $this->style->getVerticalBorderChar()));
 }