33#include <osl/diagnose.h>
35#include <LibreOfficeKit/LibreOfficeKitEnums.h>
53#include <document.hxx>
94 const OUString& rTitle,
const Color& rColor,
bool bTextBelow,
151 Size aButSize( nBWidth, nBHeight );
153 aComboButton.
Draw(
Point(nButtonPos, nButtonY), aButSize );
158 bool bWasClip =
false;
160 bool bClip = ( aTextSize.
Width() > aOuter.
Right() - nBWidth - aInner.
Left() );
171 nClipEndX, nButtonY + nVer/2 + aTextSize.
Height())) );
174 pDev->
DrawText(
Point( nTextStart, nButtonY + nVer/2 ), rTitle );
199 if ( nX1 > 0 ) --nX1;
200 if ( nY1>=2 ) nY1 -= 2;
201 else if ( nY1 > 0 ) --nY1;
202 if ( nX2 < rDoc.
MaxCol() ) ++nX2;
203 if ( nY2 < rDoc.
MaxRow()-1 ) nY2 += 2;
204 else if ( nY2 < rDoc.
MaxRow() ) ++nY2;
205 ScRange aViewRange( nX1,nY1,nTab, nX2,nY2,nTab );
218 for (
size_t j = 0,
n = xRanges->size(); j <
n; ++j)
220 ScRange aRange = (*xRanges)[j];
234 aStartPos.AdjustX( -nLayoutSign );
235 aStartPos.AdjustY( -1 );
236 aEndPos.AdjustX( -nLayoutSign );
237 aEndPos.AdjustY( -1 );
239 bool bTextBelow = ( aRange.
aStart.
Row() == 0 );
243 for (
SCTAB nAct=nTab+1; nAct<nTabCount && rDoc.
IsScenario(nAct); nAct++)
246 OUString aDummyComment;
248 rDoc.
GetName( nAct, aCurrent );
252 if (aCurrent.isEmpty())
253 aCurrent =
ScResId( STR_EMPTYDATA );
258 aCurrent, aColor, bTextBelow,
260 rDoc, rViewData, bLayoutRTL );
266 const std::vector<ScHighlightEntry>& rHighlightRanges )
269 for (
const auto& rHighlightRange : rHighlightRanges)
271 ScRange aRange = rHighlightRange.aRef;
277 rHighlightRange.aColor,
false );
339 if (aScaleX == rEntry.aScaleX && aScaleY == rEntry.aScaleY)
341 if (rCursorRect == rEntry.aRect)
345 rEntry.aRect = rCursorRect;
365 if (pViewShell != pThisViewShell && pViewShell->
GetDocId() == pThisViewShell->
GetDocId())
373 if (aZoomX == aScaleX && aZoomY == aScaleY)
376 LOK_CALLBACK_INVALIDATE_VIEW_CURSOR,
"rectangle", rCursorRect.
toString());
430 aMirroredPixel.
SetLeft( nWidth - 1 - aPixRect.
Right() );
431 aMirroredPixel.
SetRight( nWidth - 1 - aPixRect.
Left() );
435 while ( nScrX <= aMirroredPixel.
Left() && nX1 < rDoc.
MaxCol() )
441 while ( nScrX <= aMirroredPixel.
Right() && nX2 < rDoc.
MaxCol() )
481 OSL_ENSURE( rDoc.
ValidCol(nX2) && rDoc.
ValidRow(nY2),
"GridWin Draw area too big" );
517 nMirrorWidth = aScrPos.X() - nEndPixel;
518 aScrPos.setX( nEndPixel + 1 );
526 SCCOL nCurEndX = nCurX;
527 SCROW nCurEndY = nCurY;
528 rDoc.
ExtendMerge( nCurX, nCurY, nCurEndX, nCurEndY, nTab );
530 ( nCurEndX+1 >= nX1 && nCurX <= nX2+1 && nCurEndY+1 >= nY1 && nCurY <= nY2+1 );
538 rDoc.
ExtendMerge( nHdlX, nHdlY, nHdlX, nHdlY, nTab );
552 rDoc.
FillInfo( aTabInfo, nX1, nY1, nX2, nY2, nTab,
559 nScrX, nScrY, nX1, nY1, nX2, nY2,
nPPTX,
nPPTY,
566 bool bLogicText = bTextWysiwyg;
582 xFmtVirtDev->SetMapMode(
MapMode(MapUnit::Map100thMM));
604class SuppressEditViewMessagesGuard
607 SuppressEditViewMessagesGuard(
EditView& rEditView) :
608 mrEditView(rEditView),
609 mbOrigSuppressFlag(rEditView.IsSuppressLOKMessages())
611 if (!mbOrigSuppressFlag)
612 mrEditView.SuppressLOKMessages(
true);
615 ~SuppressEditViewMessagesGuard()
617 if (mrEditView.IsSuppressLOKMessages() != mbOrigSuppressFlag)
618 mrEditView.SuppressLOKMessages(mbOrigSuppressFlag);
623 const bool mbOrigSuppressFlag;
647 return nMirrorX - 1 - nPosX;
658int lcl_GetMultiLineHeight(
EditEngine* pEditEngine)
662 if (nParagraphs > 1 || (nParagraphs > 0 && pEditEngine->
GetLineCount(0) > 1))
664 for (
int nPara = 0; nPara < nParagraphs; nPara++)
681 bool bNoBackgroundAndGrid = bIsTiledRendering
683 comphelper::LibreOfficeKit::Compat::scNoGridBackground);
734 if ( nEditEndCol >= nX1 && nEditCol <= nX2 && nEditEndRow >= nY1 && nEditRow <= nY2 )
744 if (bIsTiledRendering)
755 bool bLokRTL = bLayoutRTL && bIsTiledRendering;
756 std::unique_ptr<ScLokRTLContext> pLokRTLCtxt(
768 if(rDoc.
MaxCol() == nX2 && !bLokRTL)
772 aDrawingRectPixel.
SetLeft( 0 );
787 aDrawingRectLogic =
PixelToLogic(aDrawingRectPixel, aDrawMode);
792 bool bInPlaceVisCursor =
false;
799 bInPlaceVisCursor = pInPlaceCrsr && pInPlaceCrsr->
IsVisible();
800 if (bInPlaceVisCursor)
801 pInPlaceCrsr->Hide();
821 pTargetPaintWindow = pDrawView->
BeginDrawLayers(pContentDev, aDrawingRegion);
822 OSL_ENSURE(pTargetPaintWindow,
"BeginDrawLayers: Got no SdrPaintWindow (!)");
824 if (!bIsTiledRendering)
838 if ( !bIsTiledRendering && ( nX2 == rDoc.
MaxCol() || nY2 == rDoc.
MaxRow() ) )
854 if (aDrawRect.
Right() >= aDrawRect.
Left())
869 if (aDrawRect.
Bottom() >= aDrawRect.
Top())
892 if (bGridFirst && (bGrid || bPage))
895 if (bNoBackgroundAndGrid)
896 aOutputData.
DrawGrid(*pContentDev,
false ,
false ,
true );
898 aOutputData.
DrawGrid(*pContentDev, bGrid, bPage);
903 if (!bGridFirst && (bGrid || bPage) && !bNoBackgroundAndGrid)
904 aOutputData.
DrawGrid(*pContentDev, bGrid, bPage);
945 if (bIsTiledRendering)
952 aMap.SetOrigin(aOrigin);
959 DrawButtons(nX1, nX2, rTableInfo, pContentDev, pLokRTLCtxt.get());
975 if ( bHasChange || bHasScenario || !rHigh.empty() )
994 if (bIsTiledRendering)
1009 if (bIsTiledRendering)
1032 if ( pRangeFinder && !pRangeFinder->
IsHidden() &&
1035 sal_uInt16
nCount =
static_cast<sal_uInt16
>(pRangeFinder->
Count());
1060 if (bIsTiledRendering)
1068 + aOutputData.
nScrX);
1071 + aOutputData.
nScrY);
1072 const double twipFactor = 15 * 1.76388889;
1073 aOrigin =
Point(aOrigin.getX() * twipFactor,
1074 aOrigin.getY() * twipFactor);
1093 if (bIsTiledRendering)
1100 bool bEnterLoop = bIsTiledRendering || pViewShell != pThisViewShell;
1109 bool bOtherEditMode = rOtherViewData.
HasEditView(eOtherWhich);
1114 bOtherEditMode = bOtherEditMode
1115 && ( nCol2 >= nX1 && nCol1 <= nX2 && nRow2 >= nY1 && nRow1 <= nY2 );
1116 if (bOtherEditMode && rOtherViewData.
GetRefTabNo() == nTab)
1129 if (bIsTiledRendering)
1133 aEnd.AdjustY(lcl_GetMultiLineHeight(pEditEngine));
1140 aStart.setX(pLokRTLCtxt->docToTilePos(aStart.X()));
1141 aEnd.setX(pLokRTLCtxt->docToTilePos(aEnd.X()));
1146 aEnd.AdjustX( -(2 * nLayoutSign) );
1161 aBackground += aOrigin;
1164 static const double twipFactor = 15 * 1.76388889;
1166 aOrigin =
Point((aOrigin.getX() * twipFactor) /
static_cast<double>(aDrawMode.
GetScaleX()),
1167 (aOrigin.getY() * twipFactor) /
static_cast<double>(aDrawMode.
GetScaleY()));
1197 SuppressEditViewMessagesGuard aGuard(*pOtherEditView);
1200 if (bIsTiledRendering)
1204 pOtherEditView->
Paint(aEditRect, &rDevice);
1209 comphelper::LibreOfficeKit::Compat::scPrintTwipsMsgs))
1219 MapMode aMM(MapUnit::MapTwip);
1227 aCursorRect.
Move(aCursPos.getX(), 0);
1234 if (!bIsTiledRendering)
1251 if (bInPlaceEditing)
1268 aStart.setX(pLokRTLCtxt->docToTilePos(aStart.X()));
1269 aEnd.setX(pLokRTLCtxt->docToTilePos(aEnd.X()));
1274 aEnd.AdjustX( -(2 * nLayoutSign) );
1283 if (bIsTiledRendering)
1291 aBackground += aOrigin;
1297 if (bIsTiledRendering)
1304 static const double twipFactor = 15 * 1.76388889;
1306 aOrigin =
Point((aOrigin.getX() * twipFactor) /
static_cast<double>(aDrawMode.
GetScaleX()),
1307 (aOrigin.getY() * twipFactor) /
static_cast<double>(aDrawMode.
GetScaleY()));
1314 if (bIsTiledRendering)
1326 SuppressEditViewMessagesGuard aGuard(*pEditView);
1331 comphelper::LibreOfficeKit::Compat::scPrintTwipsMsgs))
1340 MapMode aMM(MapUnit::MapTwip);
1348 aCursorRect.
Move(aCursPos.getX(), 0);
1373 if (bInPlaceVisCursor)
1374 pInPlaceCrsr->Show();
1402 std::set<SCCOL> aColBreaks;
1403 std::set<SCROW> aRowBreaks;
1406 if (aColBreaks.size() == 0 || aRowBreaks.size() == 0)
1416 template<
typename IndexType>
1417 void lcl_getBoundingRowColumnforTile(
ScViewData& rViewData,
1419 sal_Int32& nTopLeftTileOffset, sal_Int32& nTopLeftTileOrigin,
1420 sal_Int32& nTopLeftTileIndex, sal_Int32& nBottomRightTileIndex)
1422 const bool bColumnHeader = std::is_same<IndexType, SCCOL>::value;
1426 IndexType nStartIndex = -1;
1427 IndexType nEndIndex = -1;
1437 aBoundsProvider.Compute(rStartNearest, rEndNearest, nTileStartPosPx, nTileEndPosPx);
1438 aBoundsProvider.GetStartIndexAndPosition(nStartIndex, nStartPosPx); ++nStartIndex;
1439 aBoundsProvider.GetEndIndexAndPosition(nEndIndex, nEndPosPx);
1441 nTopLeftTileOffset = nTileStartPosPx - nStartPosPx;
1442 nTopLeftTileOrigin = nStartPosPx;
1443 nTopLeftTileIndex = nStartIndex;
1444 nBottomRightTileIndex = nEndIndex;
1447 void lcl_RTLAdjustTileColOffset(
ScViewData& rViewData, sal_Int32& nTileColOffset,
1451 auto GetColWidthPx = [&rDoc, nTab, fPPTX](
SCCOL nCol) {
1452 const sal_uInt16 nSize = rDoc.
GetColWidth(nCol, nTab);
1460 nTileColOffset += (nEndColPos - nTileEndPx - nTileColOffset);
1469 explicit ScLOKProxyObjectContact(
1472 const char* pDebugName) :
1473 ObjectContactOfPageView(rPageWindow, pDebugName),
1474 mpScDrawView(pDrawView)
1492 if (pPageView->PageWindowCount() > 0)
1493 pSdrPageWindow = pPageView->GetPageWindow(0);
1494 if (!pSdrPageWindow)
1500 if (pTargetSdrObject)
1501 rTarget = pTargetSdrObject->GetViewContact().GetViewObjectContact(rObjContact).getGridOffset();
1510 mpScDrawView(rData.GetScDrawView())
1515 SdrPageWindow& rPageWindow,
const char* pDebugName)
const override
1520 return new ScLOKProxyObjectContact(mpScDrawView, rPageWindow, pDebugName);
1529 int nOutputWidth,
int nOutputHeight,
1530 int nTilePosX,
int nTilePosY,
1554 const bool bChangeZoom = (aFracX != origZoomX || aFracY != origZoomY);
1562 pDrawView->resetGridOffsetsForAllSdrPageViews();
1565 const double fTilePosXPixel =
static_cast<double>(nTilePosX) * nOutputWidth / nTileWidth;
1566 const double fTilePosYPixel =
static_cast<double>(nTilePosY) * nOutputHeight / nTileHeight;
1567 const double fTileBottomPixel =
static_cast<double>(nTilePosY + nTileHeight) * nOutputHeight / nTileHeight;
1568 const double fTileRightPixel =
static_cast<double>(nTilePosX + nTileWidth) * nOutputWidth / nTileWidth;
1577 sal_Int32 nTopLeftTileRowOffset = 0;
1578 sal_Int32 nTopLeftTileColOffset = 0;
1579 sal_Int32 nTopLeftTileRowOrigin = 0;
1580 sal_Int32 nTopLeftTileColOrigin = 0;
1582 sal_Int32 nTopLeftTileRow = 0;
1583 sal_Int32 nTopLeftTileCol = 0;
1584 sal_Int32 nBottomRightTileRow = 0;
1585 sal_Int32 nBottomRightTileCol = 0;
1587 lcl_getBoundingRowColumnforTile<SCROW>(
mrViewData,
1588 fTilePosYPixel, fTileBottomPixel,
1589 nTopLeftTileRowOffset, nTopLeftTileRowOrigin,
1590 nTopLeftTileRow, nBottomRightTileRow);
1592 lcl_getBoundingRowColumnforTile<SCCOL>(
mrViewData,
1593 fTilePosXPixel, fTileRightPixel,
1594 nTopLeftTileColOffset, nTopLeftTileColOrigin,
1595 nTopLeftTileCol, nBottomRightTileCol);
1598 nBottomRightTileCol++;
1599 nBottomRightTileRow++;
1601 if (nBottomRightTileCol > rDoc.
MaxCol())
1602 nBottomRightTileCol = rDoc.
MaxCol();
1611 lcl_RTLAdjustTileColOffset(
mrViewData, nTopLeftTileColOffset,
1612 fTileRightPixel, nBottomRightTileCol, nTab,
1621 if (nEndCol < nBottomRightTileCol)
1622 nEndCol = nBottomRightTileCol;
1624 if (nEndRow < nBottomRightTileRow)
1625 nEndRow = nBottomRightTileRow;
1627 nTopLeftTileCol = std::max<sal_Int32>(nTopLeftTileCol, 0);
1628 nTopLeftTileRow = std::max<sal_Int32>(nTopLeftTileRow, 0);
1637 MapMode aAbsMode = aOriginalMode;
1638 const Point aOrigin(-nTopLeftTileColOrigin, -nTopLeftTileRowOrigin);
1643 rDoc.
FillInfo(aTabInfo, nTopLeftTileCol, nTopLeftTileRow,
1644 nBottomRightTileCol, nBottomRightTileRow,
1645 nTab, fPPTX, fPPTY,
false,
false);
1651 -nTopLeftTileColOffset,
1652 -nTopLeftTileRowOffset,
1653 nTopLeftTileCol, nTopLeftTileRow,
1654 nBottomRightTileCol, nBottomRightTileRow,
1655 fPPTX, fPPTY,
nullptr,
nullptr);
1662 comphelper::LibreOfficeKit::Compat::scPrintTwipsMsgs);
1681 DrawContent(rDevice, aTabInfo, aOutputData,
true);
1686 nTilePosX, nTilePosY, nTileWidth, nTileHeight, bLayoutRTL);
1691 rDoc.
ResetChanged(
ScRange(nTopLeftTileCol, nTopLeftTileRow, nTab, nBottomRightTileCol, nBottomRightTileRow, nTab));
1698 pDrawView->resetGridOffsetsForAllSdrPageViews();
1704 aCellBMP.
Mirror(BmpMirrorFlags::Horizontal);
1714 pResultRectangle =
nullptr;
1717 aRectangle = *pRectangle;
1728 pResultRectangle = &aRectangle;
1732 if (pResultRectangle && pResultRectangle->
Left() < 0
1736 if (pResultRectangle->
Right() < 0)
1750 if (pInputHandler && pInputHandler->
IsInputMode())
1757 if (
nType == LOK_SETTEXTSELECTION_RESET)
1770 bool bWasEmpty =
false;
1771 if (aRangeList.
empty())
1778 aRangeList.
Combine().
GetVars(nCol1, nRow1, nTab1, nCol2, nRow2, nTab2);
1789 case LOK_SETTEXTSELECTION_START:
1790 if (nNewPosX != nCol1 || nNewPosY != nRow1 || bWasEmpty)
1792 pTabView->
SetCursor(nNewPosX, nNewPosY);
1798 case LOK_SETTEXTSELECTION_END:
1799 if (nNewPosX != nCol2 || nNewPosY != nRow2 || bWasEmpty)
1804 pTabView->
MarkCursor(nNewPosX, nNewPosY, nTab);
1842 LineInfo aLineInfo(LineStyle::Dash, 2);
1849 aLineInfo.
SetLineCap(css::drawing::LineCap_ROUND);
1851 for (
int i=nX1;
i<nX2;
i++) {
1855 rRenderContext.
DrawLine(aStart,aEnd,aLineInfo);
1858 for (
int i=nY1;
i<nY2;
i++) {
1862 rRenderContext.
DrawLine(aStart,aEnd,aLineInfo);
1881 OUString aPageStr =
ScResId( STR_PGNUM );
1891 std::unique_ptr<ScEditEngineDefaulter> pEditEng;
1904 pEditEng->SetRefMapMode(rRenderContext.
GetMapMode());
1905 auto pEditDefaults = std::make_unique<SfxItemSet>( pEditEng->GetEmptyItemSet() );
1908 pEditEng->SetDefaults( std::move(pEditDefaults) );
1911 sal_uInt16
nCount = sal::static_int_cast<sal_uInt16>( pPageData->
GetCount() );
1932 aStart.AdjustX( -2 );
1933 aStart.AdjustY( -2 );
1936 if ( aStart.X() < -10 ) aStart.setX( -10 );
1937 if ( aStart.Y() < -10 ) aStart.setY( -10 );
1938 if ( aEnd.X() > aWinSize.
Width() + 10 )
1939 aEnd.setX( aWinSize.
Width() + 10 );
1940 if ( aEnd.Y() > aWinSize.
Height() + 10 )
1941 aEnd.setY( aWinSize.
Height() + 10 );
1954 for (nColPos=0; nColPos+1<nColBreaks; nColPos++)
1956 SCCOL nBreak = pColEnd[nColPos]+1;
1957 if ( nBreak >= nX1 && nBreak <= nX2+1 )
1973 for (nRowPos=0; nRowPos+1<nRowBreaks; nRowPos++)
1975 SCROW nBreak = pRowEnd[nRowPos]+1;
1976 if ( nBreak >= nY1 && nBreak <= nY2+1 )
1992 for (nRowPos=0; nRowPos<nRowBreaks; nRowPos++)
1994 SCROW nPrEndY = pRowEnd[nRowPos];
1995 if ( nPrEndY >= nY1 && nPrStartY <= nY2 )
1998 for (nColPos=0; nColPos<nColBreaks; nColPos++)
2000 SCCOL nPrEndX = pColEnd[nColPos];
2001 if ( nPrEndX >= nX1 && nPrStartX <= nX2 )
2004 nPrStartX, nPrStartY,
eWhich,
true );
2006 nPrEndX+1,nPrEndY+1,
eWhich,
true );
2010 nPageNo +=
static_cast<tools::Long>(nColPos)*nRowBreaks+nRowPos;
2012 nPageNo +=
static_cast<tools::Long>(nRowPos)*nColBreaks+nColPos;
2014 OUString aThisPageStr = aPageStr.replaceFirst(
"%1", OUString::number(nPageNo));
2023 pEditEng->SetTextCurrentDefaults( aThisPageStr );
2024 Size aSize100( pEditEng->CalcTextWidth(), pEditEng->GetTextHeight() );
2027 tools::Long nSizeX = 40 * ( aPageEnd.X() - aPageStart.X() ) / aSize100.
Width();
2028 tools::Long nSizeY = 60 * ( aPageEnd.Y() - aPageStart.Y() ) / aSize100.
Height();
2029 nHeight = std::min(nSizeX,nSizeY);
2035 Size aTextSize( pEditEng->CalcTextWidth(), pEditEng->GetTextHeight() );
2036 Point aPos( (aPageStart.X()+aPageEnd.X()-aTextSize.
Width())/2,
2037 (aPageStart.Y()+aPageEnd.Y()-aTextSize.
Height())/2 );
2038 pEditEng->Draw(rRenderContext, aPos);
2044 rRenderContext.
SetFont( aFont );
2050 tools::Long nSizeX = 40 * ( aPageEnd.X() - aPageStart.X() ) / aSize100.
Width();
2051 tools::Long nSizeY = 60 * ( aPageEnd.Y() - aPageStart.Y() ) / aSize100.
Height();
2053 rRenderContext.
SetFont( aFont );
2058 Point aPos( (aPageStart.X()+aPageEnd.X()-aTextSize.
Width())/2,
2059 (aPageStart.Y()+aPageEnd.Y()-aTextSize.
Height())/2 );
2060 rRenderContext.
DrawText( aPos, aThisPageStr );
2063 nPrStartX = nPrEndX + 1;
2066 nPrStartY = nPrEndY + 1;
2085 std::unique_ptr<ScQueryParam> pQueryParam;
2095 for (nArrY=1; nArrY+1<nArrCount; nArrY++)
2097 if ( pRowInfo[nArrY].bAutoFilter && pRowInfo[nArrY].bChanged )
2099 RowInfo* pThisRowInfo = &pRowInfo[nArrY];
2101 nRow = pThisRowInfo->
nRowNo;
2103 for (nCol=nX1; nCol<=nX2; nCol++)
2113 bool bNewData =
true;
2121 pDBData->
GetArea( nAreaTab, nStartCol, nStartRow, nEndCol, nEndRow );
2122 if ( nCol >= nStartCol && nCol <= nEndCol &&
2123 nRow >= nStartRow && nRow <= nEndRow )
2139 bool bArrowState =
false;
2140 if (pQueryParam->bInplace)
2143 for (nQuery = 0; nQuery <
nCount; ++nQuery)
2147 const ScQueryEntry& rEntry = pQueryParam->GetEntry(nQuery);
2158 SCCOL nStartCol= nCol;
2159 SCROW nStartRow = nRow;
2167 aScrPos.setX(pLokRTLContext->
docToTilePos(aScrPos.X()));
2179 if ( pRowInfo[nArrY].bPivotButton && pRowInfo[nArrY].bChanged )
2181 RowInfo* pThisRowInfo = &pRowInfo[nArrY];
2182 nRow = pThisRowInfo->
nRowNo;
2183 for (nCol=nX1; nCol<=nX2; nCol++)
2221 pQueryParam.reset();
2247 SCCOL nNextCol = nCol + 1;
2253 bool bNextCell = ( nNextCol <= rDoc.
MaxCol() );
2257 if ( nAvailable < aBtnSize.
Width() )
2259 if ( nCellSizeY < aBtnSize.
Height() )
2263 aPos.AdjustX(nCellSizeX * nLayoutSign );
2265 aPos.AdjustX( -(aBtnSize.
Width() * nLayoutSign) );
2266 aPos.AdjustY(nCellSizeY - aBtnSize.
Height() );
2270 aPos.AdjustX( -(aBtnSize.
Width()-1) );
2285 OSL_FAIL(
"Auto filter button without DBData");
2288 bool bSimpleQuery =
true;
2289 bool bColumnFound =
false;
2293 bSimpleQuery =
false;
2298 for (nQuery = 0; nQuery <
nCount && bSimpleQuery; ++nQuery)
2302 bColumnFound =
true;
2306 bSimpleQuery =
false;
2309 return ( bSimpleQuery && bColumnFound );
2324 ::std::vector< tools::Rectangle >& rPixelRects )
const
2330 ::std::vector< tools::Rectangle >& rRects,
2331 bool bInPrintTwips)
const
2364 if (nX2 < nPosX || nY2 < nPosY)
2379 tools::Long nEndX = aScrEndPos.X() + (nWidth - 1) * nLayoutSign;
2381 sal_uInt16 nHeightTwips = rDoc.
GetRowHeight( nY2, nTab );
2404 SCCOL nTestX2 = nX2;
2405 SCROW nTestY2 = nY2;
2407 rDoc.
ExtendMerge( nX1,nY1, nTestX2,nTestY2, nTab );
2412 if (nTestX2 < nPosX || nTestY2 < nPosY)
2414 SCCOL nRealX1 = nX1;
2424 if (nXRight > rDoc.
MaxCol())
2428 if (nYBottom > rDoc.
MaxRow())
2429 nYBottom = rDoc.
MaxRow();
2432 if (nX1 > nXRight || nY1 > nYBottom)
2446 if (nX2 > nMaxTiledCol)
2448 if (nY2 > nMaxTiledRow)
2457 bool bWasHidden =
false;
2458 for (
SCROW nY=nY1; nY<=nY2; nY++)
2460 bool bFirstRow = ( nY == nPosY );
2461 bool bDoHidden =
false;
2462 sal_uInt16 nHeightTwips = rDoc.
GetRowHeight( nY,nTab );
2463 bool bDoRow = ( nHeightTwips != 0 );
2483 SCCOL nLoopEndX = nX2;
2486 SCCOL nStartX = nX1;
2497 for (
SCCOL nX=nX1; nX<=nLoopEndX; nX++)
2505 tools::Long nEndX = nScrX + ( nWidth - 1 ) * nLayoutSign;
2513 (rDoc.
RowHidden(nThisY-1, nTab) || bFirstRow) )
2516 pPattern = rDoc.
GetPattern( nX, nThisY, nTab );
2528 pPattern = rDoc.
GetPattern( nThisX, nThisY, nTab );
2542 Point aEndPos = bInPrintTwips ?
2545 if ( aEndPos.X() * nLayoutSign > nScrX * nLayoutSign && aEndPos.Y() > nScrY )
2548 aEndPos.X()-nLayoutSign,aEndPos.Y()-1 ) );
2551 else if ( nEndX * nLayoutSign >= nScrX * nLayoutSign && nEndY >= nScrY )
2558 nScrX = nEndX + nLayoutSign;
2568 Window::DataChanged(rDCEvt);
2570 if ( !((rDCEvt.
GetType() == DataChangedEventType::PRINTER) ||
2571 (rDCEvt.
GetType() == DataChangedEventType::DISPLAY) ||
2572 (rDCEvt.
GetType() == DataChangedEventType::FONTS) ||
2573 (rDCEvt.
GetType() == DataChangedEventType::FONTSUBSTITUTION) ||
2574 ((rDCEvt.
GetType() == DataChangedEventType::SETTINGS) &&
2575 (rDCEvt.
GetFlags() & AllSettingsFlags::STYLE))) )
2581 if ( (rDCEvt.
GetType() == DataChangedEventType::SETTINGS) &&
2582 (rDCEvt.
GetFlags() & AllSettingsFlags::STYLE) )
2615 if (pTimer != &maShowPageBreaksTimer)
2626 const SCTAB nCurrentTab = mrViewData.GetTabNo();
2645 ScDocShell* pDocSh = mrViewData.GetDocShell();
size_t SCSIZE
size_t typedef to be able to find places where code was changed from USHORT to size_t and is used to ...
void PutInOrder(T &nStart, T &nEnd)
const StyleSettings & GetStyleSettings() const
bool Mirror(BmpMirrorFlags nMirrorFlags)
DataChangedEventType GetType() const
AllSettingsFlags GetFlags() const
sal_Int32 GetParagraphCount() const
static rtl::Reference< SfxItemPool > CreatePool()
sal_uInt32 GetLineHeight(sal_Int32 nParagraph)
sal_Int32 GetLineCount(sal_Int32 nParagraph) const
tools::Rectangle GetEditCursor() const
void SetOutputArea(const tools::Rectangle &rRect)
Color const & GetBackgroundColor() const
OutputDevice & GetOutputDevice() const
vcl::Cursor * GetCursor() const
EditEngine * GetEditEngine() const
const tools::Rectangle & GetOutputArea() const
void Paint(const tools::Rectangle &rRect, OutputDevice *pTargetDevice=nullptr)
void SetDashCount(sal_uInt16 nDashCount)
void SetDotCount(sal_uInt16 nDotCount)
void SetLineCap(css::drawing::LineCap eLineCap)
void SetDistance(double nDistance)
void SetDotLen(double nDotLen)
static void PaintAllChartsOnTile(VirtualDevice &rDevice, int nOutputWidth, int nOutputHeight, int nTilePosX, int nTilePosY, tools::Long nTileWidth, tools::Long nTileHeight, bool bNegativeX=false)
void SetOrigin(const Point &rOrigin)
void SetScaleY(const Fraction &rScaleY)
const Fraction & GetScaleX() const
const Point & GetOrigin() const
const Fraction & GetScaleY() const
void SetScaleX(const Fraction &rScaleX)
virtual vcl::Region GetActiveClipRegion() const
void SetFont(const vcl::Font &rNewFont)
SAL_WARN_UNUSED_RESULT Point PixelToLogic(const Point &rDevicePt) const
Size GetOutputSizePixel() const
void DrawRect(const tools::Rectangle &rRect)
void DrawLine(const Point &rStartPt, const Point &rEndPt)
bool IsClipRegion() const
SAL_WARN_UNUSED_RESULT Point LogicToLogic(const Point &rPtSource, const MapMode *pMapModeSource, const MapMode *pMapModeDest) const
tools::Long GetTextWidth(const OUString &rStr, sal_Int32 nIndex=0, sal_Int32 nLen=-1, vcl::text::TextLayoutCache const *=nullptr, SalLayoutGlyphs const *const pLayoutCache=nullptr) const
void DrawBitmap(const Point &rDestPt, const Bitmap &rBitmap)
void SetPixelOffset(const Size &rOffset)
virtual Bitmap GetBitmap(const Point &rSrcPt, const Size &rSize) const
const MapMode & GetMapMode() const
tools::Long GetTextHeight() const
void DrawText(const Point &rStartPt, const OUString &rStr, sal_Int32 nIndex=0, sal_Int32 nLen=-1, std::vector< tools::Rectangle > *pVector=nullptr, OUString *pDisplayText=nullptr, const SalLayoutGlyphs *pLayoutCache=nullptr)
const AllSettings & GetSettings() const
void GetArea(SCTAB &rTab, SCCOL &rCol1, SCROW &rRow1, SCCOL &rCol2, SCROW &rRow2) const
SC_DLLPUBLIC void GetQueryParam(ScQueryParam &rQueryParam) const
virtual void SetModified(bool=true) override
void PostPaint(SCCOL nStartCol, SCROW nStartRow, SCTAB nStartTab, SCCOL nEndCol, SCROW nEndRow, SCTAB nEndTab, PaintPartFlags nPart, sal_uInt16 nExtFlags=0)
void ResetChanged(const ScRange &rRange)
SC_DLLPUBLIC bool IsScenario(SCTAB nTab) const
ScSheetLimits & GetSheetLimits() const
SC_DLLPUBLIC sal_uInt16 GetRowHeight(SCROW nRow, SCTAB nTab, bool bHiddenAsZero=true) const
SC_DLLPUBLIC sal_uInt16 GetColWidth(SCCOL nCol, SCTAB nTab, bool bHiddenAsZero=true) const
bool ValidRow(SCROW nRow) const
void UpdatePageBreaks(SCTAB nTab, const ScRange *pUserArea=nullptr)
SC_DLLPUBLIC bool ExtendMerge(SCCOL nStartCol, SCROW nStartRow, SCCOL &rEndCol, SCROW &rEndRow, SCTAB nTab, bool bRefresh=false)
void MarkScenario(SCTAB nSrcTab, SCTAB nDestTab, ScMarkData &rDestMark, bool bResetMark=true, ScScenarioFlags nNeededBits=ScScenarioFlags::NONE) const
SC_DLLPUBLIC SCCOL MaxCol() const
const ScDBData * GetDBAtCursor(SCCOL nCol, SCROW nRow, SCTAB nTab, ScDBDataPortion ePortion) const
SC_DLLPUBLIC ScDocumentPool * GetPool()
SC_DLLPUBLIC SCROW MaxRow() const
void FillInfo(ScTableInfo &rTabInfo, SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, SCTAB nTab, double fColScale, double fRowScale, bool bPageMode, bool bFormulaMode, const ScMarkData *pMarkData=nullptr)
void PrepareFormulaCalc()
Call this before any operations that might trigger one or more formula cells to get calculated.
bool HasScenarioRange(SCTAB nTab, const ScRange &rRange) const
SC_DLLPUBLIC ScBreakType HasRowBreak(SCROW nRow, SCTAB nTab) const
SC_DLLPUBLIC SvtScriptType GetStringScriptType(const OUString &rString)
SC_DLLPUBLIC void GetTiledRenderingArea(SCTAB nTab, SCCOL &rEndCol, SCROW &rEndRow) const
Return the number of columns / rows that should be visible for the tiled rendering.
SC_DLLPUBLIC void GetScenarioData(SCTAB nTab, OUString &rComment, Color &rColor, ScScenarioFlags &rFlags) const
SC_DLLPUBLIC void ExtendTotalMerge(ScRange &rRange) const
SC_DLLPUBLIC ScBreakType HasColBreak(SCCOL nCol, SCTAB nTab) const
SC_DLLPUBLIC ScDrawLayer * GetDrawLayer()
SC_DLLPUBLIC bool RowHidden(SCROW nRow, SCTAB nTab, SCROW *pFirstRow=nullptr, SCROW *pLastRow=nullptr) const
void ExtendHidden(SCCOL &rX1, SCROW &rY1, SCCOL &rX2, SCROW &rY2, SCTAB nTab)
SC_DLLPUBLIC void GetAllColBreaks(std::set< SCCOL > &rBreaks, SCTAB nTab, bool bPage, bool bManual) const
void SetPageSize(SCTAB nTab, const Size &rSize)
bool ValidCol(SCCOL nCol) const
bool IsInInterpreter() const
SC_DLLPUBLIC void ExtendOverlapped(SCCOL &rStartCol, SCROW &rStartRow, SCCOL nEndCol, SCROW nEndRow, SCTAB nTab) const
SC_DLLPUBLIC bool ColHidden(SCCOL nCol, SCTAB nTab, SCCOL *pFirstCol=nullptr, SCCOL *pLastCol=nullptr) const
bool HasBackgroundDraw(SCTAB nTab, const tools::Rectangle &rMMRect) const
SC_DLLPUBLIC void GetAllRowBreaks(std::set< SCROW > &rBreaks, SCTAB nTab, bool bPage, bool bManual) const
SC_DLLPUBLIC OUString GetString(SCCOL nCol, SCROW nRow, SCTAB nTab, const ScInterpreterContext *pContext=nullptr) const
ScChangeTrack * GetChangeTrack() const
SC_DLLPUBLIC bool IsLayoutRTL(SCTAB nTab) const
SfxPrinter * GetPrinter(bool bCreateIfNotExist=true)
SC_DLLPUBLIC bool GetName(SCTAB nTab, OUString &rName) const
SC_DLLPUBLIC const SfxPoolItem * GetAttr(SCCOL nCol, SCROW nRow, SCTAB nTab, sal_uInt16 nWhich) const
SC_DLLPUBLIC const ScPatternAttr * GetPattern(SCCOL nCol, SCROW nRow, SCTAB nTab) const
Size GetPageSize(SCTAB nTab) const
SC_DLLPUBLIC const ScDocOptions & GetDocOptions() const
SC_DLLPUBLIC bool IsActiveScenario(SCTAB nTab) const
SC_DLLPUBLIC SCTAB GetTableCount() const
void GetMargins(const ScPatternAttr *pPattern, tools::Long &nLeftMargin, tools::Long &nTopMargin, tools::Long &nRightMargin, tools::Long &BottomMargin) const
tools::Long GetIndent(const ScPatternAttr *pPattern) const
static SC_DLLPUBLIC SvtScriptType GetDefaultScriptType()
tools::Rectangle aInvertRect
void LogicInvalidate(const tools::Rectangle *pRectangle) override
SvtScriptType nPageScript
void Draw(SCCOL nX1, SCROW nY1, SCCOL nX2, SCROW nY2, ScUpdateMode eMode)
void initiatePageBreaks()
void GetRectsAnyFor(const ScMarkData &rMarkData, ::std::vector< tools::Rectangle > &rRects, bool bInPrintTwips) const
MapMode GetDrawMapMode(bool bForce=false)
MapMode for the drawinglayer objects.
ScDDComboBoxButton aComboButton
void DoInvertRect(const tools::Rectangle &rPixel)
void UpdateHeaderOverlay()
void SetCellSelectionPixel(int nType, int nPixelX, int nPixelY)
Update the cell selection according to what handles have been dragged.
bool NeedLOKCursorInvalidation(const tools::Rectangle &rCursorRect, const Fraction aScaleX, const Fraction aScaleY)
tools::Rectangle GetListValButtonRect(const ScAddress &rButtonPos)
virtual void DataChanged(const DataChangedEvent &rDCEvt) override
void DrawRedraw(ScOutputData &rOutputData, SdrLayerID nLayer)
void DrawContent(OutputDevice &rDevice, const ScTableInfo &rTableInfo, ScOutputData &aOutputData, bool bLogicText)
Draw content of the gridwindow; shared between the desktop and the tiled rendering.
tools::Rectangle aRepaintPixel
std::shared_ptr< sc::SpellCheckContext > mpSpellCheckCxt
void SetupInitialPageBreaks(const ScDocument &rDoc, SCTAB nTab)
sal_uInt16 nCursorHideCount
void DrawButtons(SCCOL nX1, SCCOL nX2, const ScTableInfo &rTabInfo, OutputDevice *pContentDev, const ScLokRTLContext *pLokRTLContext)
void DrawHiddenIndicator(SCCOL nX1, SCROW nY1, SCCOL nX2, SCROW nY2, vcl::RenderContext &rRenderContext)
std::vector< LOKCursorEntry > maLOKLastCursor
std::unique_ptr< ScNoteMarker, o3tl::default_delete< ScNoteMarker > > mpNoteMarker
void flushOverlayManager()
bool IsAutoFilterActive(SCCOL nCol, SCROW nRow, SCTAB nTab)
void GetSelectionRectsPrintTwips(::std::vector< tools::Rectangle > &rRects) const
void DrawSdrGrid(const tools::Rectangle &rDrawingRect, OutputDevice *pContentDev)
void PaintTile(VirtualDevice &rDevice, int nOutputWidth, int nOutputHeight, int nTilePosX, int nTilePosY, tools::Long nTileWidth, tools::Long nTileHeight)
void DrawPagePreview(SCCOL nX1, SCROW nY1, SCCOL nX2, SCROW nY2, vcl::RenderContext &rRenderContext)
void InvalidateLOKViewCursor(const tools::Rectangle &rCursorRect, const Fraction aScaleX, const Fraction aScaleY)
void GetPixelRectsFor(const ScMarkData &rMarkData, ::std::vector< tools::Rectangle > &rPixelRects) const
convert rMarkData into pixel rectangles for this view
virtual void PrePaint(vcl::RenderContext &rRenderContext) override
Timer maShowPageBreaksTimer
void GetSelectionRects(::std::vector< tools::Rectangle > &rPixelRects) const
bool UpdateVisibleRange()
VisibleRange maVisibleRange
std::unique_ptr< FmFormView > mpLOKDrawView
LibreOfficeKit needs a persistent FmFormView for tiled rendering, otherwise the invalidations from dr...
virtual void Paint(vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect) override
void AddRect(const tools::Rectangle &rRect)
Used to store the necessary information about the (combined-)tile area relevant to coordinate transfo...
ScLokRTLContext(const ScOutputData &rOutputData, const tools::Long nTileDeviceOriginPixelX)
const ScOutputData & mrOutputData
tools::Long docToTilePos(tools::Long nPosX) const
Converts from document x pixel position to the corresponding pixel position w.r.t the tile device ori...
const tools::Long mnTileDevOriginX
todo: It should be possible to have MarkArrays for each table, in order to enable "search all" across...
const ScRange & GetMultiMarkArea() const
const ScRange & GetMarkArea() const
bool IsMultiMarked() const
void FillRangeListWithMarks(ScRangeList *pList, bool bClear, SCTAB nForTab=-1) const
Create a range list of marks.
ScRangeList GetMarkedRanges() const
void SetMarking(bool bFlag)
bool IsCellMarked(SCCOL nCol, SCROW nRow, bool bNoSimple=false) const
SCCOL GetColMerge() const
SCROW GetRowMerge() const
bool IsHorOverlapped() const
bool IsOverlapped() const
bool IsVerOverlapped() const
svtools::ColorConfig & GetColorConfig()
ScInputHandler * GetInputHdl(ScTabViewShell *pViewSh=nullptr, bool bUseRef=true)
Input-Handler.
SC_DLLPUBLIC const ScInputOptions & GetInputOptions()
tools::Long GetScrH() const
void SetFmtDevice(OutputDevice *pRDev)
void SetEditCell(SCCOL nCol, SCROW nRow)
void DrawStrings(bool bPixelToLogic=false)
void SetViewShell(ScTabViewShell *pSh)
void SetSyntaxMode(bool bNewMode)
void SetMirrorWidth(tools::Long nNew)
void SetSolidBackground(bool bSet)
void DrawSparklines(vcl::RenderContext &rRenderContext)
void SetShowNullValues(bool bSet)
void DrawFrame(vcl::RenderContext &rRenderContext)
void SetShowSpellErrors(bool bSet)
void DrawNoteMarks(vcl::RenderContext &rRenderContext)
void DrawBackground(vcl::RenderContext &rRenderContext)
void SetGridColor(const Color &rColor)
void SetMarkClipped(bool bSet)
void DrawEdit(bool bPixelToLogic)
void DrawGrid(vcl::RenderContext &rRenderContext, bool bGrid, bool bPage, bool bMergeCover=false)
void DrawDocumentBackground()
void SetUseStyleColor(bool bSet)
void SetSpellCheckContext(const sc::SpellCheckContext *pCxt)
void SetShowFormulas(bool bSet)
void DrawRefMark(SCCOL nRefStartX, SCROW nRefStartY, SCCOL nRefEndX, SCROW nRefEndY, const Color &rColor, bool bHandle)
Draws reference mark and returns its properties.
void SetDrawView(FmFormView *pNew)
void SetPagebreakMode(ScPageBreakData *pPageData)
void SetContentDevice(OutputDevice *pContentDev)
void DrawFormulaMarks(vcl::RenderContext &rRenderContext)
tools::Long GetScrW() const
ScPrintRangeData & GetData(size_t i)
static void GetFont(vcl::Font &rFont, const SfxItemSet &rItemSet, ScAutoFontColorMode eAutoMode, const OutputDevice *pOutDev=nullptr, const Fraction *pScale=nullptr, const SfxItemSet *pCondSet=nullptr, SvtScriptType nScript=SvtScriptType::NONE, const Color *pBackConfigColor=nullptr, const Color *pTextConfigColor=nullptr)
Static helper function to fill a font object from the passed item set.
const SfxPoolItem & GetItem(sal_uInt16 nWhichP) const
void FillEditItemSet(SfxItemSet *pEditSet, const SfxItemSet *pCondSet=nullptr) const
Converts all Calc items contained in the own item set to edit engine items and puts them into pEditSe...
const value_type & getNearestByPosition(tools::Long nPos) const
tools::Long computePosition(index_type nIndex, const std::function< long(index_type)> &getSizePx)
const SCCOL * GetPageEndX() const
const SCROW * GetPageEndY() const
const ScRange & GetPrintRange() const
tools::Long GetFirstPage() const
ScRangeFindData & GetObject(sal_uLong nIndex)
const OUString & GetDocName() const
void GetVars(SCCOL &nCol1, SCROW &nRow1, SCTAB &nTab1, SCCOL &nCol2, SCROW &nRow2, SCTAB &nTab2) const
bool Intersects(const ScRange &rRange) const
void UpdateInputHandler(bool bForce=false, bool bStopEditing=true)
void InitBlockMode(SCCOL nCurX, SCROW nCurY, SCTAB nCurZ, bool bTestNeg=false, bool bCols=false, bool bRows=false, bool bForceNeg=false)
void DoneBlockMode(bool bContinue=false)
const std::vector< ScHighlightEntry > & GetHighlightRanges() const
void MarkCursor(SCCOL nCurX, SCROW nCurY, SCTAB nCurZ, bool bCols=false, bool bRows=false, bool bCellSelection=false)
static void UpdateInputLine()
ScViewData & GetViewData()
SC_DLLPUBLIC void SetCursor(SCCOL nPosX, SCROW nPosY, bool bNew=false)
ScDrawView * GetScDrawView()
void RepeatResize(bool bUpdateFix=true)
ScPageBreakData * GetPageBreakData()
Point GetPrintTwipsPos(SCCOL nCol, SCROW nRow) const
returns the position (top-left corner) of the requested cell in print twips coordinates.
SCCOL GetEditEndCol() const
SCROW GetEditEndRow() const
static void AddPixelsWhile(tools::Long &rScrY, tools::Long nEndPixels, SCROW &rPosY, SCROW nEndRow, double nPPTY, const ScDocument *pDoc, SCTAB nTabNo)
while (rScrY <= nEndPixels && rPosY <= nEndRow) add pixels of row heights converted with nPPTY to rSc...
bool GetMergeSizePixel(SCCOL nX, SCROW nY, tools::Long &rSizeXPix, tools::Long &rSizeYPix) const
const ScViewOptions & GetOptions() const
bool IsSyntaxMode() const
ScMarkData & GetMarkData()
const Fraction & GetZoomY() const
SCROW GetEditStartRow() const
ScDocument & GetDocument() const
ScPositionHelper & GetLOKHeightHelper()
SCROW GetPosY(ScVSplitPos eWhich, SCTAB nForTab=-1) const
SCCOL GetRefStartX() const
SCCOL GetEditStartCol() const
const MapMode & GetLogicMode(ScSplitPos eWhich)
ScSplitPos GetEditActivePart() const
ScDocShell * GetDocShell() const
ScGridWindow * GetActiveWin()
void GetPosFromPixel(tools::Long nClickX, tools::Long nClickY, ScSplitPos eWhich, SCCOL &rPosX, SCROW &rPosY, bool bTestMerge=true, bool bRepair=false, SCTAB nForTab=-1)
ScTabViewShell * GetViewShell() const
static tools::Long ToPixel(sal_uInt16 nTwips, double nFactor)
ScDBFunc * GetView() const
SCROW VisibleCellsY(ScVSplitPos eWhichY) const
ScSplitPos GetActivePart() const
void GetEditView(ScSplitPos eWhich, EditView *&rViewPtr, SCCOL &rCol, SCROW &rRow)
Point GetScrPos(SCCOL nWhereX, SCROW nWhereY, ScSplitPos eWhich, bool bAllowNeg=false, SCTAB nForTab=-1) const
SCTAB GetRefStartZ() const
ScPositionHelper & GetLOKWidthHelper()
void SetZoom(const Fraction &rNewX, const Fraction &rNewY, std::vector< SCTAB > &tabs)
SCROW GetRefStartY() const
SCCOL VisibleCellsX(ScHSplitPos eWhichX) const
const Fraction & GetZoomX() const
SCTAB GetRefTabNo() const
bool IsPagebreakMode() const
void SetScenButSize(const Size &rNew)
SfxBindings & GetBindings()
bool HasEditView(ScSplitPos eWhich) const
ScDrawView * GetScDrawView()
SCCOL GetPosX(ScHSplitPos eWhich, SCTAB nForTab=-1) const
bool GetOption(ScViewOption eOpt) const
Color const & GetGridColor(OUString *pStrName=nullptr) const
void disposeAndReset(reference_type *pBody)
const sdr::contact::ObjectContact & GetObjectContact() const
void EndDrawLayers(SdrPaintWindow &rPaintWindow, bool bPaintFormLayer)
SdrPageView * GetSdrPageView() const
SdrPaintWindow * BeginDrawLayers(OutputDevice *pOut, const vcl::Region &rReg, bool bDisableIntersect=false)
OutputDevice & GetTargetOutputDevice()
virtual sdr::contact::ObjectContact * createViewSpecificObjectContact(SdrPageWindow &rPageWindow, const char *pDebugName) const
void Invalidate(sal_uInt16 nId)
const SfxPoolItem & GetDefaultItem(sal_uInt16 nWhich) const
static void notifyInvalidation(SfxViewShell const *pThisView, tools::Rectangle const *)
static void notifyOtherView(const SfxViewShell *pThisView, SfxViewShell const *pOtherView, int nType, std::string_view rKey, const OString &rPayload)
OUString GetTitle(sal_uInt16 nMaxLen=0) const
ViewShellDocId GetDocId() const override
static SAL_WARN_UNUSED_RESULT SfxViewShell * GetNext(const SfxViewShell &rPrev, bool bOnlyVisible=true, const std::function< bool(const SfxViewShell *)> &isViewShell=nullptr)
static SAL_WARN_UNUSED_RESULT SfxViewShell * GetFirst(bool bOnlyVisible=true, const std::function< bool(const SfxViewShell *)> &isViewShell=nullptr)
constexpr tools::Long Height() const
void setWidth(tools::Long nWidth)
void setHeight(tools::Long nHeight)
constexpr tools::Long Width() const
const vcl::Font & GetAppFont() const
void SetPriority(TaskPriority ePriority)
virtual void Start(bool bStartTimer=true) override
reference_type * get() const
void SetFontSize(const Size &)
void SetColor(const Color &)
const Size & GetFontSize() const
void SetAlignment(TextAlign)
Point LogicToPixel(const Point &rLogicPt) const
bool IsMapModeEnabled() const
const AllSettings & GetSettings() const
const MapMode & GetMapMode() const
::OutputDevice const * GetOutDev() const
Point PixelToLogic(const Point &rDevicePt) const
virtual Size GetSizePixel() const
Size GetOutputSizePixel() const
virtual void Invalidate(InvalidateFlags nFlags=InvalidateFlags::NONE)
virtual const SystemEnvData * GetSystemData() const
constexpr ::Color COL_LIGHTGRAY(0xC0, 0xC0, 0xC0)
constexpr ::Color COL_BLACK(0x00, 0x00, 0x00)
constexpr ::Color COL_TRANSPARENT(ColorTransparency, 0xFF, 0xFF, 0xFF, 0xFF)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT(EE_CHAR_START+2)
constexpr TypedWhichId< SvxColorItem > EE_CHAR_COLOR(EE_CHAR_START+0)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT_CTL(EE_CHAR_START+20)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT_CJK(EE_CHAR_START+19)
constexpr SdrLayerID SC_LAYER_FRONT(0)
constexpr SdrLayerID SC_LAYER_INTERN(2)
constexpr SdrLayerID SC_LAYER_BACK(1)
static void lcl_DrawScenarioFrames(OutputDevice *pDev, ScViewData &rViewData, ScSplitPos eWhich, SCCOL nX1, SCROW nY1, SCCOL nX2, SCROW nY2)
static void lcl_DrawOneFrame(vcl::RenderContext *pDev, const tools::Rectangle &rInnerPixel, const OUString &rTitle, const Color &rColor, bool bTextBelow, double nPPTX, double nPPTY, const Fraction &rZoomY, ScDocument &rDoc, ScViewData &rButtonViewData, bool bLayoutRTL)
static void lcl_DrawHighlight(ScOutputData &rOutputData, const ScViewData &rViewData, const std::vector< ScHighlightEntry > &rHighlightRanges)
static void lcl_LimitRect(tools::Rectangle &rRect, const tools::Rectangle &rVisible)
IMPL_LINK(ScGridWindow, InitiatePageBreaksTimer, Timer *, pTimer, void)
static void lcl_GetEditAreaTLOffset(tools::Long &nOffsetX, tools::Long &nOffsetY, const ScAddress &rAddr, const ScViewData &rViewData, ScDocument &rDoc)
tools::Long const nTopMargin
tools::Long const nLeftMargin
bool isCompatFlagSet(Compat flag)
void setLocalRendering(bool bLocalRendering=true)
constexpr auto toTwips(N number, Length from)
constexpr Point convert(const Point &rPoint, o3tl::Length eFrom, o3tl::Length eTo)
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
vcl::Font GetFont(vcl::Font const &rFont, DrawModeFlags nDrawMode, StyleSettings const &rStyleSettings)
HashMap_OWString_Interface aMap
#define SC_SCENARIO_VSPACE
#define SC_SCENARIO_HSPACE
@ SC_AUTOCOL_BLACK
always use black
OUString ScResId(TranslateId aId)
constexpr TypedWhichId< ScMergeFlagAttr > ATTR_MERGE_FLAG(145)
constexpr TypedWhichId< ScPatternAttr > ATTR_PATTERN(156)
constexpr TypedWhichId< ScMergeAttr > ATTR_MERGE(144)
ScCellInfo & cellInfo(SCCOL nCol)
Each instance of this struct represents a single filtering criteria.
SC_DLLPUBLIC const ScQueryEntry & GetEntry(SCSIZE n) const
SC_DLLPUBLIC SCSIZE GetEntryCount() const
std::unique_ptr< RowInfo[]> mpRowInfo