Commit eb9739eb authored by Dmitry.Vikulov's avatar Dmitry.Vikulov Committed by Alexander.Trofimov

Учёт бордера при скролах графики

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@53282 954022d7-b5bf-4e40-9824-e11837661b57
parent e3ad84cb
...@@ -3729,10 +3729,14 @@ function DrawingObjects() { ...@@ -3729,10 +3729,14 @@ function DrawingObjects() {
var offsetX = worksheet.cols[worksheet.visibleRange.c1].left - worksheet.cellsLeft; var offsetX = worksheet.cols[worksheet.visibleRange.c1].left - worksheet.cellsLeft;
var offsetY = worksheet.rows[worksheet.visibleRange.r1].top - worksheet.cellsTop; var offsetY = worksheet.rows[worksheet.visibleRange.r1].top - worksheet.cellsTop;
x = worksheet.getCellLeft(updatedRange.c1, 0) - ptToPx(offsetX); var vr = worksheet.visibleRange;
y = worksheet.getCellTop(updatedRange.r1, 0) - ptToPx(offsetY); var borderOffsetX = (updatedRange.c1 <= vr.c1) ? 0 : 1;
w = worksheet.getCellLeft(updatedRange.c2, 0) - worksheet.getCellLeft(updatedRange.c1, 0); var borderOffsetY = (updatedRange.r1 <= vr.r1) ? 0 : 1;
h = worksheet.getCellTop(updatedRange.r2, 0) - worksheet.getCellTop(updatedRange.r1, 0);
x = ptToPx(worksheet.getCellLeft(updatedRange.c1, 1) - offsetX) - borderOffsetX;
y = ptToPx(worksheet.getCellTop(updatedRange.r1, 1) - offsetY) - borderOffsetY;
w = worksheet.getCellLeft(updatedRange.c2, 0) - worksheet.getCellLeft(updatedRange.c1, 0) + 1;
h = worksheet.getCellTop(updatedRange.r2, 0) - worksheet.getCellTop(updatedRange.r1, 0) + 1;
/*canvas.m_oContext.beginPath(); /*canvas.m_oContext.beginPath();
canvas.m_oContext.strokeStyle = "#FF0000"; canvas.m_oContext.strokeStyle = "#FF0000";
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment