Lines Matching full:this

20         $last_call = end($this->calls);
21 $this->writeCall(['table_end', [], $last_call[2]]);
23 $this->process();
24 $this->callWriter->finalise();
25 unset($this->callWriter);
31 foreach ($this->calls as $call) {
34 $this->tableStart($call);
37 $this->tableRowClose($call);
38 $this->tableRowOpen(['tablerow_open', $call[1], $call[2]]);
42 $this->tableCell($call);
45 $this->tableRowClose($call);
46 $this->tableEnd($call);
49 $this->tableDefault($call);
53 $this->callWriter->writeCalls($this->tableCalls);
55 return $this->callWriter;
60 $this->tableCalls[] = ['table_open', $call[1], $call[2]];
61 $this->tableCalls[] = ['tablerow_open', [], $call[2]];
62 $this->firstCell = true;
67 $this->tableCalls[] = ['table_close', $call[1], $call[2]];
68 $this->finalizeTable();
73 $this->tableCalls[] = $call;
74 $this->currentCols = 0;
75 $this->firstCell = true;
76 $this->lastCellType = 'tablecell';
77 $this->maxRows++;
78 if ($this->inTableHead) {
79 $this->currentRow = ['tablecell' => 0, 'tableheader' => 0];
85 if ($this->inTableHead && ($this->inTableHead = $this->isTableHeadRow())) {
86 $this->countTableHeadRows++;
89 while ($discard = array_pop($this->tableCalls)) {
93 if (!empty($this->currentRow[$discard[0]])) {
94 $this->currentRow[$discard[0]]--;
97 $this->tableCalls[] = ['tablerow_close', [], $call[2]];
99 if ($this->currentCols > $this->maxCols) {
100 $this->maxCols = $this->currentCols;
106 $td = $this->currentRow['tablecell'];
107 $th = $this->currentRow['tableheader'];
117 if ($this->inTableHead) {
118 $this->currentRow[$call[0]]++;
120 if (!$this->firstCell) {
122 $lastCall = end($this->tableCalls);
126 $this->tableCalls[] = ['colspan', [], $call[2]];
129 $this->tableCalls[] = [$this->lastCellType . '_close', [], $call[2]];
130 $this->tableCalls[] = [$call[0] . '_open', [1, null, 1], $call[2]];
131 $this->lastCellType = $call[0];
133 $this->tableCalls[] = [$call[0] . '_open', [1, null, 1], $call[2]];
134 $this->lastCellType = $call[0];
135 $this->firstCell = false;
138 $this->currentCols++;
143 $this->tableCalls[] = $call;
150 if ($this->tableCalls[0][0] == 'table_open') {
152 $this->tableCalls[0][1][] = $this->maxCols - 1;
153 $this->tableCalls[0][1][] = $this->maxRows;
154 $this->tableCalls[0][1][] = array_shift($this->tableCalls[0][1]);
166 if ($this->inTableHead) {
167 $this->inTableHead = false;
168 $this->countTableHeadRows = 0;
175 while (++$key < count($this->tableCalls)) {
176 $call = $this->tableCalls[$key];
180 if ($this->countTableHeadRows) {
181 … array_splice($this->tableCalls, $key + 1, 0, [['tablethead_open', [], $call[2]]]);
197 … $prev = in_array($this->tableCalls[$key - 1][0], ['tablecell_open', 'tableheader_open']);
198 … $next = in_array($this->tableCalls[$key + 1][0], ['tablecell_close', 'tableheader_close']);
201 $this->tableCalls[$key - 1][1][1] = 'left';
205 $this->tableCalls[$key - 1][1][1] = 'right';
209 if ($this->tableCalls[$cellKey[$lastRow][$lastCell]][1][1] == 'right') {
210 $this->tableCalls[$cellKey[$lastRow][$lastCell]][1][1] = 'center';
212 $this->tableCalls[$cellKey[$lastRow][$lastCell]][1][1] = 'left';
217 $this->tableCalls[$key][0] = 'cdata';
221 $this->tableCalls[$key - 1][1][0] = false;
225 $this->tableCalls[$i][0] == 'tablecell_open' ||
226 $this->tableCalls[$i][0] == 'tableheader_open'
228 if (false !== $this->tableCalls[$i][1][0]) {
229 $this->tableCalls[$i][1][0]++;
241 if ($this->tableCalls[$key - 1][0] == 'cdata') {
244 $this->tableCalls[$key][0] = 'cdata';
249 … if (!$this->countTableHeadRows || ($lastRow - 1 != $this->countTableHeadRows)) {
252 … $this->tableCalls[$cellKey[$i][$lastCell]][0] == 'tablecell_open' ||
253 … $this->tableCalls[$cellKey[$i][$lastCell]][0] == 'tableheader_open'
255 … if ($this->tableCalls[$cellKey[$i][$lastCell]][1][2] >= $lastRow - $i) {
263 // No spanning cell found, so convert this cell to
265 $this->tableCalls[$key][0] = 'cdata';
266 $this->tableCalls[$key][1][0] = '';
269 $this->tableCalls[$cellKey[$spanning_cell][$lastCell]][1][2]++;
271 $this->tableCalls[$key - 1][1][2] = false;
282 while (++$lastCell < $this->maxCols) {
289 array_splice($this->tableCalls, $key, 0, $moreCalls);
293 if ($this->countTableHeadRows == $lastRow) {
294 … array_splice($this->tableCalls, $key + 1, 0, [['tablethead_close', [], $call[2]]]);
301 $cnt = count($this->tableCalls);
303 if ($this->tableCalls[$key][0] == 'cdata') {
306 while ($this->tableCalls[$key][0] == 'cdata') {
307 $this->tableCalls[$ckey][1][0] .= $this->tableCalls[$key][1][0];
316 unset($this->tableCalls[$delete]);
318 $this->tableCalls = array_values($this->tableCalls);