21#include <com/sun/star/accessibility/AccessibleRole.hpp>
22#include <com/sun/star/accessibility/AccessibleStateType.hpp>
23#include <com/sun/star/accessibility/AccessibleEventId.hpp>
62 if( pCSh->IsTableMode() )
68 SwSelBoxes const& rBoxes(pCSh->GetTableCursor()->GetSelectedBoxes());
69 bRet = rBoxes.
find(pBox) != rBoxes.
end();
84 rStateSet |= AccessibleStateType::SELECTABLE;
86 rStateSet |= AccessibleStateType::RESIZABLE;
94 rStateSet |= AccessibleStateType::SELECTED;
104 , m_aSelectionHelper( *this )
105 , m_bIsSelected( false )
112 css::uno::Reference<css::accessibility::XAccessible> xTableReference(
114 css::uno::Reference<css::accessibility::XAccessibleContext> xContextTable(
115 xTableReference, css::uno::UNO_QUERY);
118 || xContextTable->getAccessibleRole() != AccessibleRole::TABLE),
119 "sw.a11y",
"bad accessible context");
128 std::scoped_lock aGuard(
m_Mutex );
140 bool bChanged = bOld != bNew;
154 bool bChanged =
false;
158 while( aIter != aVisList.
end() )
167 GetMap()->GetContextImpl( pLower,
false ) );
170 assert(xAccImpl->GetFrame()->IsCellFrame());
201 AccessibleEventObject
aEvent;
202 aEvent.EventId = AccessibleEventId::STATE_CHANGED;
203 aEvent.NewValue <<= AccessibleStateType::FOCUSED;
204 xChildImpl->FireAccessibleEvent(
aEvent );
212 if( pTabFrame->IsFollow() )
228 std::scoped_lock aGuard(
m_Mutex );
260 GetMap()->GetContextImpl( pParent,
false ) );
270 GetMap()->GetContextImpl( pParent,
false ) );
283 aR <<= uno::Reference<XAccessibleExtendedAttributes>(
this);
290 aR <<= uno::Reference<XAccessibleSelection>(
this);
295 uno::Reference<XAccessibleValue> xValue =
this;
302 return SwAccessibleContext::queryInterface( rType );
311 SwAccessibleContext::getTypes() ).
getTypes();
316 return css::uno::Sequence<sal_Int8>();
347 bool bValid = (aNumber >>= fValue);
375 css::uno::Any strRet;
377 assert(pFrameFormat);
381 OUString strFormula = tbl_formula.
GetFormula()
382 .replaceAll(
u"\\",
u"\\\\")
383 .replaceAll(
u";",
u"\\;")
384 .replaceAll(
u"=",
u"\\=")
385 .replaceAll(
u",",
u"\\,")
386 .replaceAll(
u":",
u"\\:");
387 OUString strFor =
"Formula:" + strFormula +
";";
405 uno::Reference<XAccessibleComponent> xComponentDoc(xAccDoc, uno::UNO_QUERY);
406 if (xComponentDoc.is())
412 return sal_Int32(crBack);
417 sal_Int64 nChildIndex )
423 sal_Int64 nChildIndex )
443 sal_Int64 nSelectedChildIndex )
449 sal_Int64 nSelectedChildIndex )
constexpr OUStringLiteral sImplementationName
constexpr OUStringLiteral sAccessibleServiceName
const Color & GetColor() const
virtual css::uno::Any SAL_CALL getMinimumValue() override
SwFrameFormat * GetTableBoxFormat() const
sal_Int32 SAL_CALL getBackground() override
virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getSelectedAccessibleChild(sal_Int64 nSelectedChildIndex) override
virtual void InvalidatePosOrSize(const SwRect &rFrame) override
virtual css::uno::Any SAL_CALL queryInterface(const css::uno::Type &aType) override
virtual css::uno::Any SAL_CALL getMinimumIncrement() override
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
bool InvalidateChildrenCursorPos(const SwFrame *pFrame)
virtual ~SwAccessibleCell() override
virtual sal_Int64 SAL_CALL getSelectedAccessibleChildCount() override
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() override
SwAccessibleCell(std::shared_ptr< SwAccessibleMap > const &pInitMap, const SwCellFrame *pCellFrame)
virtual sal_Bool SAL_CALL setCurrentValue(const css::uno::Any &aNumber) override
virtual void SAL_CALL selectAccessibleChild(sal_Int64 nChildIndex) override
virtual void SAL_CALL clearAccessibleSelection() override
virtual OUString SAL_CALL getAccessibleDescription() override
Return this object's description.
virtual void Dispose(bool bRecursive, bool bCanSkipInvisible=true) override
virtual css::uno::Any SAL_CALL getCurrentValue() override
virtual OUString SAL_CALL getImplementationName() override
virtual void SAL_CALL selectAllAccessibleChildren() override
SwAccessibleSelectionHelper m_aSelectionHelper
css::uno::Any SAL_CALL getExtendedAttributes() override
virtual void GetStates(sal_Int64 &rStateSet) override
rtl::Reference< SwAccessibleTable > m_pAccTable
virtual sal_Bool SAL_CALL isAccessibleChildSelected(sal_Int64 nChildIndex) override
bool InvalidateMyCursorPos()
virtual void SAL_CALL deselectAccessibleChild(sal_Int64 nSelectedChildIndex) override
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() override
virtual void InvalidateCursorPos_() override
virtual css::uno::Any SAL_CALL getMaximumValue() override
virtual bool HasCursor() override
virtual sal_Bool SAL_CALL supportsService(const OUString &sServiceName) override
Return whether the specified service is supported by this class.
const_iterator end() const
const_iterator begin() const
virtual void Dispose(bool bRecursive, bool bCanSkipInvisible=true)
const OUString & GetName() const
void FireStateChangedEvent(sal_Int64 nState, bool bNewState)
void SetName(const OUString &rName)
virtual void GetStates(sal_Int64 &rStateSet)
virtual css::uno::Reference< css::accessibility::XAccessible > SAL_CALL getAccessibleParent() override
SwAccessibleMap * GetMap()
SwViewShell * GetShell()
convenience method to get the SwViewShell through accessibility map
virtual void InvalidatePosOrSize(const SwRect &rFrame)
css::uno::Reference< css::accessibility::XAccessible > getAccessibleParentImpl()
bool IsInPagePreview() const
static sw::access::SwAccessibleChild GetChild(SwAccessibleMap &rAccMap, const SwRect &rVisArea, const SwFrame &rFrame, sal_Int32 &rPos, bool bInPagePreview)
const SwFrame * GetFrame() const
const SwFrame * GetParent() const
const SwRect & GetVisArea() const
void SetCursorContext(const ::rtl::Reference< SwAccessibleContext > &rCursorContext)
SwViewShell * GetShell() const
bool isAccessibleChildSelected(sal_Int64 nChildIndex)
void selectAccessibleChild(sal_Int64 nChildIndex)
void selectAllAccessibleChildren()
css::uno::Reference< css::accessibility::XAccessible > getSelectedAccessibleChild(sal_Int64 nSelectedChildIndex)
void deselectAccessibleChild(sal_Int64 nChildIndex)
sal_Int64 getSelectedAccessibleChildCount()
const SvxBrushItem & GetBackground(bool=true) const
SwCellFrame is one table cell in the document layout.
const SwTableBox * GetTabBox() const
Base class of the Writer layout elements.
const SwAttrSet * GetAttrSet() const
WARNING: this may not return correct RES_PAGEDESC/RES_BREAK items for SwTextFrame,...
Of course Writer needs its own rectangles.
SwTabFrame is one table in the document layout, containing rows (which contain cells).
SwTabFrame * FindMaster(bool bFirstMaster=false) const
const SwTabFrame * GetFollow() const
SwTableBox is one table cell in the document model.
SwFrameFormat * GetFrameFormat()
css::uno::Sequence< css::uno::Type > SAL_CALL getTypes()
const_iterator find(const Value &x) const
const_iterator end() const
bool IsAccessible(bool bPagePreview) const
const SwFrame * GetSwFrame() const
constexpr ::Color COL_AUTO(ColorTransparency, 0xFF, 0xFF, 0xFF, 0xFF)
#define SAL_WARN_IF(condition, area, stream)
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)