1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_a11y_sdnTextAccessible_h_
8 #define mozilla_a11y_sdnTextAccessible_h_
10 #include "ISimpleDOM.h"
11 #include "IUnknownImpl.h"
13 #include "MsaaAccessible.h"
21 class sdnTextAccessible final
: public ISimpleDOMText
{
23 explicit sdnTextAccessible(MsaaAccessible
* aMsaa
) : mMsaa(aMsaa
){};
24 ~sdnTextAccessible() {}
30 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE
get_domText(
31 /* [retval][out] */ BSTR __RPC_FAR
* aText
);
33 virtual HRESULT STDMETHODCALLTYPE
get_clippedSubstringBounds(
34 /* [in] */ unsigned int startIndex
,
35 /* [in] */ unsigned int endIndex
,
36 /* [out] */ int __RPC_FAR
* aX
,
37 /* [out] */ int __RPC_FAR
* aY
,
38 /* [out] */ int __RPC_FAR
* aWidth
,
39 /* [out] */ int __RPC_FAR
* aHeight
);
41 virtual HRESULT STDMETHODCALLTYPE
get_unclippedSubstringBounds(
42 /* [in] */ unsigned int aStartIndex
,
43 /* [in] */ unsigned int aEndIndex
,
44 /* [out] */ int __RPC_FAR
* aX
,
45 /* [out] */ int __RPC_FAR
* aY
,
46 /* [out] */ int __RPC_FAR
* aWidth
,
47 /* [out] */ int __RPC_FAR
* aHeight
);
49 virtual HRESULT STDMETHODCALLTYPE
scrollToSubstring(
50 /* [in] */ unsigned int aStartIndex
,
51 /* [in] */ unsigned int aEndIndex
);
53 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE
get_fontFamily(
54 /* [retval][out] */ BSTR __RPC_FAR
* aFontFamily
);
58 * Return child frame containing offset on success.
60 nsIFrame
* GetPointFromOffset(nsIFrame
* aContainingFrame
, int32_t aOffset
,
61 bool aPreferNext
, nsPoint
& aOutPoint
);
63 RefPtr
<MsaaAccessible
> mMsaa
;
67 } // namespace mozilla