1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
21 #include <AccessibleBase.hxx>
22 #include <com/sun/star/accessibility/XAccessibleExtendedComponent.hpp>
24 namespace com::sun::star::accessibility
{ class XAccessible
; }
25 namespace com::sun::star::accessibility
{ class XAccessibleContext
; }
26 namespace com::sun::star::awt
{ class XFont
; }
30 class AccessibleTextHelper
;
32 /** Base class for all Chart Accessibility objects except the root node (see AccessibleChartView)
34 This class contains a reference to the ChartModel, thus, components can easily access all core functionality.
39 <li>define the getAccessibleName() method of XAccessibleContext</li>
40 <li>set the ChartModel using SetChartModel() for the first node before
41 creating any children</li>
42 <li>override UpdateChildren()</li>
48 typedef ::cppu::ImplInheritanceHelper
<
50 css::accessibility::XAccessibleExtendedComponent
51 > AccessibleChartElement_Base
;
54 class AccessibleChartElement
:
55 public impl::AccessibleChartElement_Base
58 AccessibleChartElement( const AccessibleElementInfo
& rAccInfo
,
59 bool bMayHaveChildren
);
60 virtual ~AccessibleChartElement() override
;
62 // ________ AccessibleBase ________
63 virtual bool ImplUpdateChildren() override
;
64 virtual css::uno::Reference
< css::accessibility::XAccessible
>
65 ImplGetAccessibleChildById( sal_Int64 i
) const override
;
66 virtual sal_Int64
ImplGetAccessibleChildCount() const override
;
68 // ________ XAccessibleContext ________
69 virtual OUString SAL_CALL
getAccessibleName() override
;
70 virtual OUString SAL_CALL
getAccessibleDescription() override
;
72 // ________ XAccessibleExtendedComponent ________
73 virtual css::uno::Reference
< css::awt::XFont
> SAL_CALL
getFont() override
;
74 virtual OUString SAL_CALL
getTitledBorderText() override
;
75 virtual OUString SAL_CALL
getToolTipText() override
;
77 // the following interface is implemented in AccessibleBase, however it is
78 // also a (non-virtual) base class of XAccessibleExtendedComponent Thus
79 // these methods have to be overridden and forward to AccessibleBase
81 // ________ XAccessibleComponent ________
82 virtual sal_Bool SAL_CALL
containsPoint( const css::awt::Point
& aPoint
) override
;
83 virtual css::uno::Reference
< css::accessibility::XAccessible
> SAL_CALL
getAccessibleAtPoint( const css::awt::Point
& aPoint
) override
;
84 virtual css::awt::Rectangle SAL_CALL
getBounds() override
;
85 virtual css::awt::Point SAL_CALL
getLocation() override
;
86 virtual css::awt::Point SAL_CALL
getLocationOnScreen() override
;
87 virtual css::awt::Size SAL_CALL
getSize() override
;
88 virtual void SAL_CALL
grabFocus() override
;
89 virtual sal_Int32 SAL_CALL
getForeground() override
;
90 virtual sal_Int32 SAL_CALL
getBackground() override
;
92 // ________ XServiceInfo ________
93 virtual OUString SAL_CALL
getImplementationName() override
;
97 rtl::Reference
< ::chart::AccessibleTextHelper
>
105 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */