@@ 7148-7163 (lines=16) @@ | ||
7145 | $row = self::getUInt2d($cellAddressStructure, 0) + 1; |
|
7146 | ||
7147 | // bit: 14; mask 0x4000; (1 = relative column index, 0 = absolute column index) |
|
7148 | if (!(0x4000 & self::getUInt2d($cellAddressStructure, 2))) { |
|
7149 | // offset: 2; size: 2; index to column or column offset + relative flags |
|
7150 | // bit: 7-0; mask 0x00FF; column index |
|
7151 | $colIndex = 0x00FF & self::getUInt2d($cellAddressStructure, 2); |
|
7152 | ||
7153 | $column = Coordinate::stringFromColumnIndex($colIndex + 1); |
|
7154 | $column = '$' . $column; |
|
7155 | } else { |
|
7156 | // offset: 2; size: 2; index to column or column offset + relative flags |
|
7157 | // bit: 7-0; mask 0x00FF; column index |
|
7158 | $relativeColIndex = 0x00FF & self::getInt2d($cellAddressStructure, 2); |
|
7159 | $colIndex = $baseCol + $relativeColIndex; |
|
7160 | $colIndex = ($colIndex < 256) ? $colIndex : $colIndex - 256; |
|
7161 | $colIndex = ($colIndex >= 0) ? $colIndex : $colIndex + 256; |
|
7162 | $column = Coordinate::stringFromColumnIndex($colIndex + 1); |
|
7163 | } |
|
7164 | ||
7165 | // bit: 15; mask 0x8000; (1 = relative row index, 0 = absolute row index) |
|
7166 | if (!(0x8000 & self::getUInt2d($cellAddressStructure, 2))) { |
|
@@ 7336-7352 (lines=17) @@ | ||
7333 | $lrIndex = self::getUInt2d($subData, 2); // adjust below |
|
7334 | ||
7335 | // bit: 14; mask 0x4000; (1 = relative column index, 0 = absolute column index) |
|
7336 | if (!(0x4000 & self::getUInt2d($subData, 4))) { |
|
7337 | // absolute column index |
|
7338 | // offset: 4; size: 2; first column with relative/absolute flags |
|
7339 | // bit: 7-0; mask 0x00FF; column index |
|
7340 | $fcIndex = 0x00FF & self::getUInt2d($subData, 4); |
|
7341 | $fc = Coordinate::stringFromColumnIndex($fcIndex + 1); |
|
7342 | $fc = '$' . $fc; |
|
7343 | } else { |
|
7344 | // column offset |
|
7345 | // offset: 4; size: 2; first column with relative/absolute flags |
|
7346 | // bit: 7-0; mask 0x00FF; column index |
|
7347 | $relativeFcIndex = 0x00FF & self::getInt2d($subData, 4); |
|
7348 | $fcIndex = $baseCol + $relativeFcIndex; |
|
7349 | $fcIndex = ($fcIndex < 256) ? $fcIndex : $fcIndex - 256; |
|
7350 | $fcIndex = ($fcIndex >= 0) ? $fcIndex : $fcIndex + 256; |
|
7351 | $fc = Coordinate::stringFromColumnIndex($fcIndex + 1); |
|
7352 | } |
|
7353 | ||
7354 | // bit: 15; mask 0x8000; (1 = relative row index, 0 = absolute row index) |
|
7355 | if (!(0x8000 & self::getUInt2d($subData, 4))) { |
|
@@ 7366-7382 (lines=17) @@ | ||
7363 | } |
|
7364 | ||
7365 | // bit: 14; mask 0x4000; (1 = relative column index, 0 = absolute column index) |
|
7366 | if (!(0x4000 & self::getUInt2d($subData, 6))) { |
|
7367 | // absolute column index |
|
7368 | // offset: 6; size: 2; last column with relative/absolute flags |
|
7369 | // bit: 7-0; mask 0x00FF; column index |
|
7370 | $lcIndex = 0x00FF & self::getUInt2d($subData, 6); |
|
7371 | $lc = Coordinate::stringFromColumnIndex($lcIndex + 1); |
|
7372 | $lc = '$' . $lc; |
|
7373 | } else { |
|
7374 | // column offset |
|
7375 | // offset: 4; size: 2; first column with relative/absolute flags |
|
7376 | // bit: 7-0; mask 0x00FF; column index |
|
7377 | $relativeLcIndex = 0x00FF & self::getInt2d($subData, 4); |
|
7378 | $lcIndex = $baseCol + $relativeLcIndex; |
|
7379 | $lcIndex = ($lcIndex < 256) ? $lcIndex : $lcIndex - 256; |
|
7380 | $lcIndex = ($lcIndex >= 0) ? $lcIndex : $lcIndex + 256; |
|
7381 | $lc = Coordinate::stringFromColumnIndex($lcIndex + 1); |
|
7382 | } |
|
7383 | ||
7384 | // bit: 15; mask 0x8000; (1 = relative row index, 0 = absolute row index) |
|
7385 | if (!(0x8000 & self::getUInt2d($subData, 6))) { |