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 .
20 #ifndef INCLUDED_SC_SOURCE_UI_INC_ACCESSIBLEPAGEHEADER_HXX
21 #define INCLUDED_SC_SOURCE_UI_INC_ACCESSIBLEPAGEHEADER_HXX
23 #include "AccessibleContextBase.hxx"
24 #include <editeng/svxenum.hxx>
28 class ScAccessiblePageHeaderArea
;
31 class ScAccessiblePageHeader
: public ScAccessibleContextBase
34 ScAccessiblePageHeader( const ::com::sun::star::uno::Reference
<
35 ::com::sun::star::accessibility::XAccessible
>& rxParent
,
36 ScPreviewShell
* pViewShell
, bool bHeader
, sal_Int32 nIndex
);
39 virtual ~ScAccessiblePageHeader();
41 using ScAccessibleContextBase::IsDefunc
;
44 using ScAccessibleContextBase::disposing
;
45 virtual void SAL_CALL
disposing() SAL_OVERRIDE
;
47 //===== SfxListener =====================================================
49 virtual void Notify( SfxBroadcaster
& rBC
, const SfxHint
& rHint
) SAL_OVERRIDE
;
51 //===== XAccessibleComponent ============================================
53 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessible
> SAL_CALL
54 getAccessibleAtPoint( const ::com::sun::star::awt::Point
& aPoint
)
55 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
56 virtual void SAL_CALL
grabFocus() throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
58 //===== XAccessibleContext ==============================================
60 virtual sal_Int32 SAL_CALL
getAccessibleChildCount() throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
61 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessible
> SAL_CALL
62 getAccessibleChild( sal_Int32 i
)
63 throw (::com::sun::star::lang::IndexOutOfBoundsException
,
64 ::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
65 virtual sal_Int32 SAL_CALL
getAccessibleIndexInParent() throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
66 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessibleStateSet
> SAL_CALL
67 getAccessibleStateSet() throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
69 //===== XServiceInfo ====================================================
71 virtual OUString SAL_CALL
getImplementationName()
72 throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
73 virtual ::com::sun::star::uno::Sequence
< OUString
> SAL_CALL
getSupportedServiceNames()
74 throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
76 //===== internal ========================================================
77 void SetCurrentIndexInParent(sal_Int32 nNew
) { mnIndex
= nNew
; }
80 virtual OUString SAL_CALL
createAccessibleDescription() throw(::com::sun::star::uno::RuntimeException
) SAL_OVERRIDE
;
81 virtual OUString SAL_CALL
createAccessibleName() throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
83 virtual Rectangle
GetBoundingBoxOnScreen() const throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
84 virtual Rectangle
GetBoundingBox() const throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
87 ScPreviewShell
* mpViewShell
;
90 typedef std::vector
< ScAccessiblePageHeaderArea
* > ScHFAreas
;
92 sal_Int32 mnChildCount
;
95 const com::sun::star::uno::Reference
<
96 ::com::sun::star::accessibility::XAccessibleStateSet
>& rxParentStates
);
98 void AddChild(const EditTextObject
* pArea
, sal_uInt32 nIndex
, SvxAdjust eAdjust
);
103 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */