49#include <inputwin.hxx>
55#include <bitmaps.hlst>
60#include <document.hxx>
72#include <com/sun/star/frame/XLayoutManager.hpp>
88using com::sun::star::uno::UNO_QUERY;
90using com::sun::star::frame::XLayoutManager;
95constexpr ToolBoxItemId SID_INPUT_FUNCTION (SC_VIEW_START + 47);
105 SC_NAME_INPUT_NAMEDRANGE_LOCAL,
106 SC_NAME_INPUT_NAMEDRANGE_GLOBAL,
107 SC_NAME_INPUT_DATABASE,
110 SC_NAME_INPUT_DEFINE,
111 SC_NAME_INPUT_BAD_NAME,
112 SC_NAME_INPUT_BAD_SELECTION,
131 pWin->SetSizePixel( pWin->CalcWindowSizePixel() );
133 SetAlignment(SfxChildAlignment::LOWESTTOP);
134 pBindings->Invalidate( FID_TOGGLEINPUTLINE );
166 pInputHdl ( nullptr ),
167 mpViewShell ( nullptr ),
169 mnStandardItemHeight(0),
170 bIsOkCancelMode ( false ),
183 OSL_ENSURE( pViewSh,
"no view shell for input window" );
192 InsertItem (SID_INPUT_FUNCTION,
Image(StockImage::Yes, RID_BMP_INPUT_FUNCTION), ToolBoxItemBits::NONE, 2);
198 if (!bIsLOKMobilePhone)
200 InsertItem (SID_INPUT_SUM,
Image(StockImage::Yes, RID_BMP_INPUT_SUM), ToolBoxItemBits::DROPDOWN, 3);
201 InsertItem (SID_INPUT_EQUAL,
Image(StockImage::Yes, RID_BMP_INPUT_EQUAL), ToolBoxItemBits::NONE, 4);
202 InsertItem (SID_INPUT_CANCEL,
Image(StockImage::Yes, RID_BMP_INPUT_CANCEL), ToolBoxItemBits::NONE, 5);
203 InsertItem (SID_INPUT_OK,
Image(StockImage::Yes, RID_BMP_INPUT_OK), ToolBoxItemBits::NONE, 6);
223 if (!bIsLOKMobilePhone)
344 if (curItemId == SID_INPUT_FUNCTION)
351 SfxCallMode::SYNCHRON | SfxCallMode::RECORD );
358 else if (curItemId == SID_INPUT_CANCEL)
363 else if (curItemId == SID_INPUT_OK)
369 else if (curItemId == SID_INPUT_SUM)
374 bool bSubTotal =
false;
375 bool bRangeFinder =
false;
376 const OUString aFormula = pViewSh->
DoAutoSum(bRangeFinder, bSubTotal,
ocSum);
377 if (!aFormula.isEmpty())
389 const sal_Int32 nOpen = aFormula.indexOf(
'(');
390 const sal_Int32 nLen = aFormula.getLength();
391 if (nOpen != -1 && nLen > nOpen)
393 ESelection aSel(0, nOpen + (bSubTotal ? 3 : 1), 0, nLen - 1);
406 else if (curItemId == SID_INPUT_EQUAL)
420 sal_Int32 nStartPos = 1;
421 sal_Int32 nEndPos = 1;
426 const OUString& rString =
mxTextWindow->GetTextString();
427 const sal_Int32 nLen = rString.getLength();
456 sal_Int32 nStartPara = 0, nEndPara = 0;
484 Window::PixelInvalidate(&aRect);
488 Window::PixelInvalidate(
nullptr);
499 if (
vcl::Window* pWorkWindow = pFrameWindowImpl->GetParent())
501 if (
vcl::Window* pImplBorderWindow = pWorkWindow->GetParent())
503 Size aSize = pImplBorderWindow->GetSizePixel();
505 pImplBorderWindow->SetSizePixel(aSize);
519 Size aSize = aStartSize;
537 int nNormalHeight =
mxTextWindow->GetPixelHeightForLines(1);
539 if (nInitialTopMargin > 0)
540 nTopOffset = nInitialTopMargin;
546 if (aStartSize != aSize)
576 sal_Int32 nLen = rString.getLength();
599 if (rString.getLength() <= 32767)
619 ShowItem ( SID_INPUT_CANCEL,
true );
703 if (
SC_MOD()->IsEditMode() )
744 if (
nType == StateChangedType::InitShow )
Resize();
749 if ( rDCEvt.
GetType() == DataChangedEventType::SETTINGS && (rDCEvt.
GetFlags() & AllSettingsFlags::STYLE) )
752 SetItemImage(SID_INPUT_FUNCTION,
Image(StockImage::Yes, RID_BMP_INPUT_FUNCTION));
788 bool bResetPointerPos =
false;
793 bResetPointerPos =
true;
799 bResetPointerPos =
true;
803 bResetPointerPos =
true;
807 if (bResetPointerPos)
860 const OUString aFormula = pViewSh->
DoAutoSum(bRangeFinder, bSubTotal, eCode);
861 if ( aFormula.isEmpty() )
865 const sal_Int32 aOpen = aFormula.indexOf(
'(');
866 const sal_Int32 aLen = aFormula.getLength();
878 if ( aOpen != -1 && aLen > aOpen )
880 ESelection aSel( 0, aOpen + (bSubTotal ? 3 : 1), 0, aLen-1 );
891 :
InterimItemWindow(pParent,
"modules/scalc/ui/inputbar.ui",
"InputBar", true, reinterpret_cast<sal_uInt64>(pViewSh))
892 , mxBackground(m_xBuilder->weld_container(
"background"))
894 , mxButtonUp(m_xBuilder->weld_button(
"up"))
895 , mxButtonDown(m_xBuilder->weld_button(
"down"))
938 if ((rDCEvt.
GetType() == DataChangedEventType::SETTINGS) && (rDCEvt.
GetFlags() & AllSettingsFlags::STYLE))
1042 if (command.empty())
1045 bool bSubTotal =
false;
1046 bool bRangeFinder =
false;
1048 if ( command ==
u"sum" )
1052 else if ( command ==
u"average" )
1056 else if ( command ==
u"max" )
1060 else if ( command ==
u"min" )
1064 else if ( command ==
u"count" )
1068 else if ( command ==
u"counta" )
1072 else if ( command ==
u"product" )
1076 else if (command ==
u"stdev")
1080 else if (command ==
u"stdevp")
1084 else if (command ==
u"var")
1088 else if (command ==
u"varp")
1093 AutoSum( bRangeFinder, bSubTotal, eCode );
1101 if (nCurID == SID_INPUT_SUM)
1106 std::unique_ptr<weld::Menu> xPopMenu(xBuilder->weld_menu(
"menu"));
1107 MenuHdl(xPopMenu->popup_at_rect(pPopupParent, aRect));
1113 if (mxTextWndGroup->GetNumLines() > 1)
1114 mxTextWndGroup->SetNumLines(1);
1116 mxTextWndGroup->SetNumLines(mxTextWndGroup->GetLastNumExpandedLines());
1154 if ( xPropSet.is() )
1156 css::uno::Any aValue = xPropSet->getPropertyValue(
"LayoutManager");
1157 aValue >>= xLayoutManager;
1160 if ( !xLayoutManager.is() )
1163 xLayoutManager->lock();
1164 DataChangedEvent aFakeUpdate( DataChangedEventType::SETTINGS,
nullptr, AllSettingsFlags::STYLE );
1180 xLayoutManager->unlock();
1192 : mxTextWnd(new
ScTextWnd(*this, pViewSh))
1193 , mxScrollWin(rParent.GetBuilder().weld_scrolled_window(
"scrolledwindow", true))
1194 , mxTextWndWin(new
weld::CustomWeld(rParent.GetBuilder(),
"sc_input_window", *mxTextWnd))
1230 mxTextWnd->InsertAccessibleTextData(rTextData);
1245 return mxTextWnd->GetLastNumExpandedLines();
1250 mxTextWnd->SetLastNumExpandedLines(nLastExpandedLines);
1290 mxTextWnd->RemoveAccessibleTextData(rTextData);
1333 mxTextWnd->DoScroll();
1348 pView->Invalidate();
1384 OutputDevice& rDevice = GetDrawingArea()->get_ref_device();
1410 Size aOutputSize = GetOutputSizePixel();
1411 OutputDevice& rDevice = GetDrawingArea()->get_ref_device();
1417 if (
m_xEditView->GetVisArea().Top() > nMaxVisAreaTop)
1441 OutputDevice& rDevice = GetDrawingArea()->get_ref_device();
1445 int nCurrentDocPos =
m_xEditView->GetVisArea().Top();
1446 int nStepIncrement = GetTextHeight();
1447 int nPageIncrement = aOutputSize.
Height();
1448 int nPageSize = aOutputSize.
Height();
1458 nPageSize = std::min(nPageSize, nUpper);
1462 nStepIncrement, nPageIncrement, nPageSize);
1470 auto currentDocPos =
m_xEditView->GetVisArea().Top();
1502 std::unique_ptr<SfxPoolItem> pNewItem(rFontItem.
Clone());
1508 pNewItem.reset(rHeightItem.
Clone());
1514 pNewItem.reset(rWeightItem.
Clone());
1520 pNewItem.reset(rItalicItem.
Clone());
1526 pNewItem.reset(rLangItem.
Clone());
1560 std::unique_ptr<ScFieldEditEngine> pNew;
1570 pNew->SetExecuteURL(
false );
1573 Size barSize = GetOutputSizePixel();
1575 m_xEditEngine->SetPaperSize( GetDrawingArea()->get_ref_device().PixelToLogic(
Size(barSize.
Width(),10000)) );
1578 m_xEditEngine->SetReplaceLeadingSingleQuotationMark(
false );
1583 auto pSet = std::make_unique<SfxItemSet>(
m_xEditEngine->GetEmptyItemSet() );
1595 bool bFilled =
false;
1624 ScResId(STR_ACC_EDITLINE_NAME),
1625 ScResId(STR_ACC_EDITLINE_DESCR));
1633 m_xEditView->SetControlWord(
n | EVControlBits::SINGLELINEPASTE );
1654 if ( nScript & SvtScriptType::COMPLEX )
1661 bIsInsertMode(true),
1662 bFormulaMode (false),
1664 mpViewShell(pViewSh),
1665 mrGroupBar(rParent),
1685 return SC_MOD()->IsEditMode();
1702 bool bClickOnSelection =
false;
1708 if (!bClickOnSelection)
1740 bool bConsumed =
false;
1761 if ( nCommand == CommandEventId::StartDrag )
1765 if ( pEndViewSh != pStartViewSh && pStartViewSh !=
nullptr )
1776 else if ( nCommand == CommandEventId::EndExtTextInput )
1785 else if ( nCommand == CommandEventId::CursorPos )
1789 else if ( nCommand == CommandEventId::InputLanguageChange )
1799 rBindings.
Invalidate( SID_ATTR_CHAR_FONTHEIGHT );
1802 else if ( nCommand == CommandEventId::ContextMenu )
1811 Size aSize = GetOutputSizePixel();
1814 if (IsMouseCaptured())
1820 else if ( nCommand == CommandEventId::Wheel )
1824 else if ( nCommand == CommandEventId::GestureSwipe )
1828 else if ( nCommand == CommandEventId::GestureLongPress )
1832 else if ( nCommand == CommandEventId::ModKeyChange )
1857 sal_Int32 nParaStart, nParaEnd, nPosStart, nPosEnd;
1859 nParaStart = pParaPoint ? pParaPoint->
X() : 0;
1860 nParaEnd = pParaPoint ? pParaPoint->
Y() : 0;
1861 nPosStart =
m_xEditView->GetPosNoField(nParaStart, aSelectionStartEnd.
X());
1862 nPosEnd =
m_xEditView->GetPosNoField(nParaEnd, aSelectionStartEnd.
Y());
1882 return sSelection.isEmpty();
1891 if (!
SC_MOD()->InputKeyEvent( rKEvt ))
1928 nControl |= EEControlBits::AUTOCORRECT;
1930 if ( nControl != nOld )
1943 if (m_xEditView && !bInputMode)
1957 SetScrollBarRange();
2000 std::vector<ReferenceMark> aReferenceMarks;
2011 while (
i < rStr1.getLength() )
2014 if ( *pStr1 != *pStr2 )
2047 if (
auto pDocShell =
dynamic_cast<ScDocShell*
>( pObjSh) )
2054 bPaintAll = ( nOldScript & SvtScriptType::COMPLEX ) || ( nNewScript & SvtScriptType::COMPLEX );
2066 if (rNewString.getLength() >
aString.getLength())
2073 if ( nSize1>0 && nSize2>0 )
2074 nTextSize = std::max( nSize1, nSize2 );
2076 nTextSize = GetOutputSizePixel().Width();
2078 Point aLogicStart = GetDrawingArea()->get_ref_device().PixelToLogic(
Point(0,0));
2082 nInvPos += GetTextWidth(
aString.copy(0,nDifPos));
2124 std::unique_ptr<ScFieldEditEngine> pNew;
2133 pNew->SetExecuteURL(
false );
2136 const bool bPrevUpdateLayout =
m_xEditEngine->SetUpdateLayout(
false );
2140 auto pSet = std::make_unique<SfxItemSet>(
m_xEditEngine->GetEmptyItemSet() );
2158 ScResId(STR_ACC_EDITLINE_NAME),
2159 ScResId(STR_ACC_EDITLINE_DESCR));
2195 pDrawingArea->
set_cursor(PointerStyle::Text);
2249 "ScTextWnd::InsertAccessibleTextData - passed object already registered" );
2256 AccTextDataVector::iterator aIt = ::std::find(
maAccTextDatas.begin(), aEnd, &rTextData );
2257 OSL_ENSURE( aIt != aEnd,
"ScTextWnd::RemoveAccessibleTextData - passed object not registered" );
2265 CustomWidgetController::Invalidate();
2276 ,
m_xWidget(m_xBuilder->weld_combo_box(
"pos_window"))
2277 , m_nAsyncGetFocusId(nullptr)
2278 , nTipVisible(nullptr)
2279 , bFormulaMode(false)
2350 return OUString::Concat(rName) +
" (" + rTableName +
")";
2359 if (
auto pDocShell =
dynamic_cast<ScDocShell*
>( pObjSh) )
2364 m_xWidget->append_separator(
"separator");
2367 std::set<OUString> aSet;
2369 for (
const auto& rEntry : *pRangeNames)
2371 if (rEntry.second->IsValidReference(aDummy))
2372 aSet.
insert(rEntry.second->GetName());
2377 if (pLocalRangeName && !pLocalRangeName->
empty())
2379 OUString aTableName;
2381 for (
const auto& rEntry : *pLocalRangeName)
2383 if (rEntry.second->IsValidReference(aDummy))
2389 for (
const auto& rItem : aSet)
2403 OUString aFirstName;
2410 sal_uInt32 nListCount = pFuncList->
GetCount();
2411 for (sal_uInt16
i=0;
i<nMRUCount;
i++)
2413 sal_uInt16
nId = pMRUList[
i];
2414 for (sal_uInt32 j=0; j<nListCount; j++)
2420 if (aFirstName.isEmpty())
2443 if (
auto pEventHint =
dynamic_cast<const SfxEventHint*
>(&rHint) )
2446 if ( nEventId == SfxEventHintId::ActivateDoc )
2452 if (nHintId == SfxHintId::ScAreasChanged || nHintId == SfxHintId::ScNavigatorUpdateAll)
2468 ScNameInputType eRet = SC_NAME_INPUT_BAD_NAME;
2491 if (rText ==
ScResId(STR_MANAGE_NAMES))
2492 eRet = SC_MANAGE_NAMES;
2494 eRet = SC_NAME_INPUT_RANGE;
2496 eRet = SC_NAME_INPUT_CELL;
2499 eRet = ((eNameScope ==
RUTL_NAMES_LOCAL) ? SC_NAME_INPUT_NAMEDRANGE_LOCAL :
2500 SC_NAME_INPUT_NAMEDRANGE_GLOBAL);
2503 eRet = SC_NAME_INPUT_DATABASE;
2505 ( nNumeric = rText.toInt32() ) > 0 && nNumeric <= rDoc.
MaxRow()+1 )
2506 eRet = SC_NAME_INPUT_ROW;
2507 else if ( rDoc.
GetTable( rText, nNameTab ) )
2508 eRet = SC_NAME_INPUT_SHEET;
2513 eRet = SC_NAME_INPUT_DEFINE;
2515 eRet = SC_NAME_INPUT_BAD_SELECTION;
2518 eRet = SC_NAME_INPUT_BAD_NAME;
2528 if (
m_xWidget->changed_by_direct_pick())
2543 case SC_NAME_INPUT_CELL:
2544 pStrId = STR_NAME_INPUT_CELL;
2546 case SC_NAME_INPUT_RANGE:
2547 case SC_NAME_INPUT_NAMEDRANGE_LOCAL:
2548 case SC_NAME_INPUT_NAMEDRANGE_GLOBAL:
2549 pStrId = STR_NAME_INPUT_RANGE;
2551 case SC_NAME_INPUT_DATABASE:
2552 pStrId = STR_NAME_INPUT_DBRANGE;
2554 case SC_NAME_INPUT_ROW:
2555 pStrId = STR_NAME_INPUT_ROW;
2557 case SC_NAME_INPUT_SHEET:
2558 pStrId = STR_NAME_INPUT_SHEET;
2560 case SC_NAME_INPUT_DEFINE:
2561 pStrId = STR_NAME_INPUT_DEFINE;
2575 aPos = LogicToPixel( pCur->
GetPos() );
2576 aPos = OutputToScreenPixel( aPos );
2579 OUString aText =
ScResId(pStrId);
2580 QuickHelpFlags const nAlign = QuickHelpFlags::Left|QuickHelpFlags::Bottom;
2586 bool bOpenManageNamesDialog =
false;
2587 OUString aText =
m_xWidget->get_active_text();
2588 if ( !aText.isEmpty() )
2593 if ( aText ==
ScResId(STR_FUNCTIONLIST_MORE) )
2600 if ( pViewFrm && !pViewFrm->
GetChildWindow( SID_OPENDLG_FUNCTION ) )
2602 SfxCallMode::SYNCHRON | SfxCallMode::RECORD );
2624 if (
eType == SC_NAME_INPUT_BAD_NAME ||
eType == SC_NAME_INPUT_BAD_SELECTION )
2626 TranslateId pId = (
eType == SC_NAME_INPUT_BAD_NAME) ? STR_NAME_ERROR_NAME : STR_NAME_ERROR_SELECTION;
2629 else if (
eType == SC_NAME_INPUT_DEFINE )
2640 if ( aNewRanges.
insert(pNew) )
2647 else if (
eType == SC_MANAGE_NAMES)
2650 bOpenManageNamesDialog =
true;
2654 bool bForceGlobalName =
false;
2656 if (
eType == SC_NAME_INPUT_CELL ||
eType == SC_NAME_INPUT_RANGE)
2664 else if (
eType == SC_NAME_INPUT_NAMEDRANGE_GLOBAL)
2666 bForceGlobalName =
true;
2672 SfxBoolItem aForceGlobalName( FN_PARAM_3, bForceGlobalName );
2675 SfxCallMode::SYNCHRON | SfxCallMode::RECORD,
2676 { &aPosItem, &aUnmarkItem, &aForceGlobalName });
2686 if (bOpenManageNamesDialog)
2688 const sal_uInt16
nId = ScNameDlgWrapper::GetChildWindowId();
2693 SC_MOD()->SetRefDialog(
nId, pWnd ==
nullptr );
2705 bool bHandled =
true;
2707 switch (rKEvt.GetKeyCode().GetCode())
2722 ReleaseFocus_Impl();
2730 return bHandled || ChildKeyInput(rKEvt);
2735 m_nAsyncGetFocusId =
nullptr;
2741 if (m_nAsyncGetFocusId)
2749 if (m_nAsyncGetFocusId)
2752 m_nAsyncGetFocusId =
nullptr;
BaseContainerNodeSharedPtr & mrParent
SfxApplication * SfxGetpApp()
const MouseSettings & GetMouseSettings() const
const StyleSettings & GetStyleSettings() const
static bool GetLayoutRTL()
static const AllSettings & GetSettings()
static ImplSVEvent * PostUserEvent(const Link< void *, void > &rLink, void *pCaller=nullptr, bool bReferenceLink=false)
static std::unique_ptr< weld::Builder > CreateBuilder(weld::Widget *pParent, const OUString &rUIFile, bool bMobile=false, sal_uInt64 nLOKWindowId=0)
static void RemoveUserEvent(ImplSVEvent *nUserEvent)
OUString uppercase(const OUString &rStr, sal_Int32 nPos, sal_Int32 nCount) const
CommandEventId GetCommand() const
const Point & GetMousePosPixel() const
void * GetEventData() const
bool IsMouseEvent() const
DataChangedEventType GetType() const
AllSettingsFlags GetFlags() const
Size GetSizePixel() const override
Size GetOutputSizePixel() const
sal_Int32 GetParagraphCount() const
const Size & GetPaperSize() const
sal_Int32 GetTextLen() const
static rtl::Reference< SfxItemPool > CreatePool()
static void SetFontInfoInItemSet(SfxItemSet &rItemSet, const vcl::Font &rFont)
tools::Rectangle GetVisArea() const
void SetSelection(const ESelection &rNewSel)
vcl::Cursor * GetCursor() const
EditEngine * GetEditEngine() const
void SetVisArea(const tools::Rectangle &rRect)
bool SetEditEngineUpdateLayout(bool bUpdate)
static void * ShowPopover(vcl::Window *pParent, const tools::Rectangle &rScreenRect, const OUString &rText, QuickHelpFlags nStyle)
static void HidePopover(vcl::Window const *pParent, void *nId)
virtual void Resize() override
virtual void dispose() override
std::unique_ptr< weld::Container > m_xContainer
void InitControlBase(weld::Widget *pWidget)
const Point & GetPosPixel() const
MouseMiddleButtonAction GetMiddleButtonAction() const
Size GetOutputSize() const
const vcl::Font & GetFont() const
void SetFont(const vcl::Font &rNewFont)
SAL_WARN_UNUSED_RESULT Point PixelToLogic(const Point &rDevicePt) const
SAL_WARN_UNUSED_RESULT Point LogicToLogic(const Point &rPtSource, const MapMode *pMapModeSource, const MapMode *pMapModeDest) const
SAL_WARN_UNUSED_RESULT Point LogicToPixel(const Point &rLogicPt) const
const MapMode & GetMapMode() const
tools::Long GetTextHeight() const
constexpr tools::Long Y() const
void setX(tools::Long nX)
void setY(tools::Long nY)
tools::Long AdjustY(tools::Long nVertMove)
tools::Long AdjustX(tools::Long nHorzMove)
constexpr tools::Long X() const
SC_DLLPUBLIC ScRefFlags Parse(const OUString &, const ScDocument &, const Details &rDetails=detailsOOOa1, ExternalInfo *pExtInfo=nullptr, const css::uno::Sequence< css::sheet::ExternalLinkInfo > *pExternalLinks=nullptr, sal_Int32 *pSheetEndPos=nullptr, const OUString *pErrRef=nullptr)
sal_uInt16 GetLRUFuncListCount() const
sal_uInt16 * GetLRUFuncList() const
void ModifyRangeNames(const ScRangeName &rNewRanges, SCTAB nTab=-1)
const ScDocument & GetDocument() const
SC_DLLPUBLIC SfxItemPool * GetEnginePool() const
SC_DLLPUBLIC bool GetTable(const OUString &rName, SCTAB &rTab) const
SC_DLLPUBLIC formula::FormulaGrammar::AddressConvention GetAddressConvention() const
SC_DLLPUBLIC SCROW MaxRow() const
SC_DLLPUBLIC SvtScriptType GetStringScriptType(const OUString &rString)
SC_DLLPUBLIC SfxItemPool * GetEditPool() const
SC_DLLPUBLIC ScRangeName * GetRangeName(SCTAB nTab) const
SC_DLLPUBLIC CellType GetCellType(SCCOL nCol, SCROW nRow, SCTAB nTab) const
SC_DLLPUBLIC bool GetName(SCTAB nTab, OUString &rName) const
SC_DLLPUBLIC SCTAB GetTableCount() const
static OUString ModifyDelimiters(const OUString &rOld)
Stores and generates human readable descriptions for spreadsheet-functions, e.g. functions used in fo...
sal_uInt16 nFIndex
Unique function index.
std::optional< OUString > mxFuncName
Function name.
List of spreadsheet functions.
const ScFuncDesc * GetFunction(sal_uInt32 nIndex) const
sal_uInt32 GetCount() const
static ScFunctionList * GetStarCalcFunctionList()
static std::optional< SvtSysLocale > oSysLocale
static SC_DLLPUBLIC const CharClass & getCharClass()
ScInputHandler * GetInputHdl(ScTabViewShell *pViewSh=nullptr, bool bUseRef=true)
Input-Handler.
void InputChanged(const EditView *pView)
void SetInEditCommand(bool bNew)
SC_DLLPUBLIC void InputEnterHandler(ScEnterMode nBlockMode=ScEnterMode::NORMAL, bool bBeforeSavingInLOK=false)
void InputCancelHandler()
void InputSelection(const EditView *pView)
std::unique_ptr< weld::ComboBox > m_xWidget
void SetPos(const OUString &rPosStr)
void SetFormulaMode(bool bSet)
ScPosWnd(vcl::Window *pParent)
ImplSVEvent * m_nAsyncGetFocusId
virtual void Notify(SfxBroadcaster &rBC, const SfxHint &rHint) override
virtual void dispose() override
virtual ~ScPosWnd() override
static OUString createLocalRangeName(std::u16string_view rName, std::u16string_view rTableName)
static SC_DLLPUBLIC IsNameValidType IsNameValid(const OUString &rName, const ScDocument &rDoc)
SC_DLLPUBLIC ScRangeData * findByUpperName(const OUString &rName)
SC_DLLPUBLIC bool insert(ScRangeData *p, bool bReuseFreeIndex=true)
Insert object into set.
static bool MakeRangeFromName(const OUString &rName, const ScDocument &rDoc, SCTAB nCurTab, ScRange &rRange, RutlNameScope eScope=RUTL_NAMES, ScAddress::Details const &rDetails=ScAddress::detailsOOOa1, bool bUseDetailsPos=false)
OUString Format(const ScDocument &rDocument, ScRefFlags nFlags=ScRefFlags::ZERO, const ScAddress::Details &rDetails=ScAddress::detailsOOOa1, bool bFullAddressNotation=false) const
Returns string with formatted cell range from aStart to aEnd, according to provided address conventio...
ScRefFlags ParseAny(const OUString &, const ScDocument &, const ScAddress::Details &rDetails=ScAddress::detailsOOOa1)
ScRefFlags Parse(const OUString &, const ScDocument &, const ScAddress::Details &rDetails=ScAddress::detailsOOOa1, ScAddress::ExternalInfo *pExtInfo=nullptr, const css::uno::Sequence< css::sheet::ExternalLinkInfo > *pExternalLinks=nullptr, const OUString *pErrRef=nullptr)
void UpdateInputHandler(bool bForce=false, bool bStopEditing=true)
OUString DoAutoSum(bool &rRangeFinder, bool &rSubTotal, const OpCode eCode)
void SetFormShellAtTop(bool bSet)
static ScTabViewShell * GetActiveViewShell()
const ScInputHandler * GetInputHandler() const
bool SfxKeyInput(const KeyEvent &rKEvt)
void ErrorMessage(TranslateId pGlobStrId)
tools::Long GetGridHeight(ScVSplitPos eWhich)
ScViewData & GetViewData()
tools::Long GetLastNumExpandedLines() const
virtual void RemoveAccessibleTextData(ScAccessibleEditLineTextData &rTextData) override
std::unique_ptr< ScTextWnd > mxTextWnd
virtual EditView * GetEditView() const override
const OutputDevice & GetEditViewDevice() const
virtual void StopEditEngine(bool bAll) override
virtual bool HasEditView() const override
virtual void SetFormulaMode(bool bSet) override
void SetNumLines(tools::Long nLines)
int GetPixelHeightForLines(tools::Long nLines)
virtual const OUString & GetTextString() const override
virtual void StartEditEngine() override
virtual ~ScTextWndGroup() override
std::unique_ptr< weld::ScrolledWindow > mxScrollWin
virtual bool IsInputActive() override
virtual void InsertAccessibleTextData(ScAccessibleEditLineTextData &rTextData) override
virtual tools::Long GetNumLines() const override
ScTextWndGroup(ScInputBarGroup &pParent, ScTabViewShell *pViewSh)
vcl::Window & GetVclParent()
virtual void MakeDialogEditView() override
Point GetCursorScreenPixelPos(bool bBelowLine)
virtual void TextGrabFocus() override
weld::ScrolledWindow & GetScrollWin()
void SetLastNumExpandedLines(tools::Long nLastExpandedLines)
virtual void SetTextString(const OUString &rString) override
ScTextWndGroup & mrGroupBar
virtual void GetFocus() override
virtual void Resize() override
virtual bool MouseButtonUp(const MouseEvent &rMEvt) override
AccTextDataVector maAccTextDatas
virtual void SetDrawingArea(weld::DrawingArea *pDrawingArea) override
virtual void Paint(vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect) override
bool IsInputActive() override
void UpdateAutoCorrFlag()
rtl::Reference< ScAccessibleEditObject > pAcc
virtual void RemoveAccessibleTextData(ScAccessibleEditLineTextData &rTextData) override
const OutputDevice & GetEditViewDevice() const
virtual const OUString & GetTextString() const override
int GetEditEngTxtHeight() const
virtual void EditViewScrollStateChange() override
virtual bool MouseButtonDown(const MouseEvent &rMEvt) override
virtual void StartEditEngine() override
virtual bool CanFocus() const override
ScTabViewShell * mpViewShell
int GetPixelHeightForLines(tools::Long nLines)
virtual void InsertAccessibleTextData(ScAccessibleEditLineTextData &rTextData) override
virtual bool StartDrag() override
virtual void MakeDialogEditView() override
virtual bool MouseMove(const MouseEvent &rMEvt) override
virtual void StopEditEngine(bool bAll) override
virtual ~ScTextWnd() override
virtual void TextGrabFocus() override
void SetNumLines(tools::Long nLines)
virtual void SetFormulaMode(bool bSet) override
virtual void StyleUpdated() override
tools::Long mnLastExpandedLines
virtual EditView * GetEditView() const override
virtual bool Command(const CommandEvent &rCEvt) override
virtual void SetTextString(const OUString &rString) override
virtual tools::Long GetNumLines() const override
virtual css::uno::Reference< css::accessibility::XAccessible > CreateAccessible() override
virtual bool HasEditView() const override
virtual bool KeyInput(const KeyEvent &rKEvt) override
ScTextWnd(ScTextWndGroup &rParent, ScTabViewShell *pViewSh)
rtl::Reference< svt::OStringTransferable > m_xHelper
SfxDispatcher & GetDispatcher()
void SetFormulaBarLines(sal_Int16 nLines)
ScDocument & GetDocument() const
ScDocShell * GetDocShell() const
ScMarkType GetSimpleArea(SCCOL &rStartCol, SCROW &rStartRow, SCTAB &rStartTab, SCCOL &rEndCol, SCROW &rEndRow, SCTAB &rEndTab) const
ScDBFunc * GetView() const
ScSplitPos GetActivePart() const
ScAddress GetCurPos() const
bool HasEditView(ScSplitPos eWhich) const
sal_Int16 GetFormulaBarLines() const
SfxDispatcher * GetDispatcher() const
void Invalidate(sal_uInt16 nId)
virtual SfxChildWinInfo GetInfo() const
const SfxPoolItem * Execute(sal_uInt16 nSlot, SfxCallMode nCall=SfxCallMode::SLOT, const SfxPoolItem **pArgs=nullptr, sal_uInt16 nModi=0, const SfxPoolItem **pInternalArgs=nullptr)
const SfxPoolItem * ExecuteList(sal_uInt16 nSlot, SfxCallMode nCall, std::initializer_list< SfxPoolItem const * > args, std::initializer_list< SfxPoolItem const * > internalargs=std::initializer_list< SfxPoolItem const * >())
SfxViewFrame * GetFrame() const
void ExecutePopup(const OUString &rResName, vcl::Window *pWin=nullptr, const Point *pPos=nullptr)
const css::uno::Reference< css::frame::XFrame > & GetFrameInterface() const
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
void StartListening(SfxBroadcaster &rBroadcaster, DuplicateHandling eDuplicateHanding=DuplicateHandling::Unexpected)
void EndListening(SfxBroadcaster &rBroadcaster, bool bRemoveAllDuplicates=false)
bool IsInModalMode() const
static SAL_WARN_UNUSED_RESULT SfxObjectShell * Current()
void SetWhich(sal_uInt16 nId)
virtual SfxPoolItem * Clone(SfxItemPool *pPool=nullptr) const=0
SfxViewShell * GetViewShell() const
static SAL_WARN_UNUSED_RESULT SfxViewFrame * Current()
SfxBindings & GetBindings()
SfxDispatcher * GetDispatcher()
SfxChildWindow * GetChildWindow(sal_uInt16)
SfxFrame & GetFrame() const
bool isLOKMobilePhone() const
SfxViewFrame & GetViewFrame() const
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)
static SAL_WARN_UNUSED_RESULT SfxViewShell * Current()
bool isLOKDesktop() const
vcl::Window * GetWindow() const
constexpr tools::Long Height() const
constexpr tools::Long getWidth() const
void setWidth(tools::Long nWidth)
void setHeight(tools::Long nHeight)
constexpr tools::Long Width() const
const Color & GetWindowColor() const
const Color & GetWindowTextColor() const
const Color & GetFaceColor() const
const vcl::Font & GetAppFont() const
void SetPropLineSpace(const sal_uInt16 nProp)
reference_type * get() const
static VclPtr< reference_type > Create(Arg &&... arg)
std::unique_ptr< EditEngine > m_xEditEngine
virtual void Paint(vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect) override
std::unique_ptr< EditView > m_xEditView
virtual OutputDevice & EditViewOutputDevice() const override
virtual bool MouseButtonDown(const MouseEvent &rMEvt) override
virtual bool MouseButtonUp(const MouseEvent &rMEvt) override
virtual void GetFocus() override
const Point & GetPos() const
tools::Long GetHeight() const
void SetFontSize(const Size &)
void SetTransparent(bool bTransparent)
void SetFillColor(const Color &)
void SetColor(const Color &)
void SetWeight(FontWeight)
const Size & GetFontSize() const
Point OutputToScreenPixel(const Point &rPos) const
vcl::Window * GetParent() const
tools::Long GetOutOffXPixel() const
void SetLOKNotifier(const vcl::ILibreOfficeKitNotifier *pNotifier, bool bParent=false)
Point LogicToPixel(const Point &rLogicPt) const
virtual void SetSizePixel(const Size &rNewSize)
void ReleaseLOKNotifier()
void Enable(bool bEnable=true, bool bChild=true)
tools::Long GetOutOffYPixel() const
void SetAccessibleName(const OUString &rName)
const vcl::ILibreOfficeKitNotifier * GetLOKNotifier() const
void SetPointerPosPixel(const Point &rPos)
bool IsRTLEnabled() const
virtual Size GetSizePixel() const
virtual void DataChanged(const DataChangedEvent &rDCEvt)
Point GetPointerPosPixel()
virtual void SetPointer(PointerStyle)
void SetPaintTransparent(bool bTransparent)
void Invalidate(InvalidateFlags nFlags=InvalidateFlags::NONE)
virtual OutputDevice & get_ref_device()=0
virtual void set_cursor(PointerStyle ePointerStyle)=0
constexpr ::Color COL_BLACK(0x00, 0x00, 0x00)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO_CJK(EE_CHAR_START+17)
constexpr TypedWhichId< SvxAdjustItem > EE_PARA_JUST(EE_PARA_START+16)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT(EE_CHAR_START+2)
constexpr TypedWhichId< SvxLanguageItem > EE_CHAR_LANGUAGE_CTL(EE_CHAR_START+16)
constexpr TypedWhichId< SvxWeightItem > EE_CHAR_WEIGHT(EE_CHAR_START+4)
constexpr TypedWhichId< SvxWeightItem > EE_CHAR_WEIGHT_CTL(EE_CHAR_START+22)
constexpr TypedWhichId< SvxPostureItem > EE_CHAR_ITALIC(EE_CHAR_START+7)
constexpr TypedWhichId< SvxLineSpacingItem > EE_PARA_SBL(EE_PARA_START+15)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT_CTL(EE_CHAR_START+20)
constexpr TypedWhichId< SvxWeightItem > EE_CHAR_WEIGHT_CJK(EE_CHAR_START+21)
constexpr TypedWhichId< SvxLanguageItem > EE_CHAR_LANGUAGE_CJK(EE_CHAR_START+15)
constexpr TypedWhichId< SvxPostureItem > EE_CHAR_ITALIC_CJK(EE_CHAR_START+23)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO_CTL(EE_CHAR_START+18)
constexpr TypedWhichId< SvxPostureItem > EE_CHAR_ITALIC_CTL(EE_CHAR_START+24)
constexpr TypedWhichId< SvxLanguageItem > EE_CHAR_LANGUAGE(EE_CHAR_START+14)
constexpr TypedWhichId< SvxScriptSpaceItem > EE_PARA_ASIANCJKSPACING(EE_PARA_START+4)
constexpr TypedWhichId< SvxFontHeightItem > EE_CHAR_FONTHEIGHT_CJK(EE_CHAR_START+19)
constexpr TypedWhichId< SvxFontItem > EE_CHAR_FONTINFO(EE_CHAR_START+1)
constexpr OUStringLiteral HID_INSWIN_FUNC
constexpr OUStringLiteral HID_INSWIN_SUMME
constexpr OUStringLiteral HID_INSWIN_INPUT
constexpr OUStringLiteral HID_INSWIN_CANCEL
constexpr OUStringLiteral HID_SC_INPUTWIN
constexpr OUStringLiteral HID_INSWIN_CALC
constexpr OUStringLiteral HID_INSWIN_OK
constexpr OUStringLiteral HID_INSWIN_POS
constexpr sal_uInt16 KEY_RETURN
constexpr sal_uInt16 KEY_ESCAPE
#define LINK(Instance, Class, Member)
#define LINE_SPACE_DEFAULT_HEIGHT
class SAL_NO_VTABLE XPropertySet
bool isdigitAsciiString(std::string_view rString)
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
void SetPointFont(OutputDevice &rDevice, const vcl::Font &rFont)
weld::Window * GetPopupParent(vcl::Window &rOutWin, tools::Rectangle &rRect)
OUString ScResId(TranslateId aId)
SFX_IMPL_CHILDWINDOW_WITHID(SvxSearchDialogWrapper, SID_SEARCH_DLG)
WinBits const WB_CLIPCHILDREN
WinBits const WB_NOSHADOW