1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
11 * OpenOffice.org is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
15 * OpenOffice.org is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License version 3 for more details
19 * (a copy is included in the LICENSE file that accompanied this code).
21 * You should have received a copy of the GNU Lesser General Public License
22 * version 3 along with OpenOffice.org. If not, see
23 * <http://www.openoffice.org/license.html>
24 * for a copy of the LGPLv3 License.
26 ************************************************************************/
28 #ifndef __com_sun_star_accessibility_XAccessibleKeyBinding_idl__
29 #define __com_sun_star_accessibility_XAccessibleKeyBinding_idl__
31 #ifndef __com_sun_star_uno_XInterface_idl__
32 #include
<com
/sun
/star
/uno
/XInterface.idl
>
34 #ifndef __com_sun_star_awt_KeyStroke_idl__
35 #include
<com
/sun
/star
/awt
/KeyStroke.idl
>
37 #ifndef __com_sun_star_lang_IndexOutOfBoundsException_idl__
38 #include
<com
/sun
/star
/lang
/IndexOutOfBoundsException.idl
>
41 module com
{ module sun
{ module star
{ module accessibility
{
43 /** This interface can be used to represent any number of key bindings which
44 then can be associated to a certain action.
46 <p>There can be zero, one, or more key bindings. Each key binding consists
47 of a sequence of <type scope="::com::sun::star::awt">KeyStroke</type>
48 objects. The association of an action with a key binding is established
49 by the <type>XAccessibleAction</type> interface returning an
50 <type>XAccessibleKeyBinding</type> object.</p>
52 <p>A key binding describes alternative ways how to invoke an action with
53 pressing one or more keys after each other. Each individual sequence of
58 published
interface XAccessibleKeyBinding
: ::com
::sun
::star
::uno
::XInterface
60 /** Return the number of available key bindings.
62 The returned value may be 0 to indicate that there are no key
63 bindings or the positive number of the available key bindings.
65 long getAccessibleKeyBindingCount
();
67 /** The returned sequence of key strokes describes one method to invoke
68 the associated action (the one from which you obtained the object at
69 which you called this method) by pressing keys. The keys specified
70 by each of the returned key strokes have to be pressed at the same
71 time (the Control-key and the A-key for example). The keys of
72 one key stroke have to be released before pressing those of the
73 next. The order of the key strokes in the sequence define the order
74 in which to press them.
76 The index selects one of alternative key bindings. It has to
77 non-negative and smaller then the number of key bindings as
78 returned by the <member>geetAccessibleKeyBindingCount()</member>
81 The returned sequence of key strokes specifies one way to invoke
82 the associated action. The sequence may be empty (but should
83 not be; better not to return such a key binding at all).
84 @throws ::com::sun::star::lang::IndexOutOfBoundsException
85 if the index is not valid.
87 sequence
<::com
::sun
::star
::awt
::KeyStroke
> getAccessibleKeyBinding
([in] long nIndex
)
88 raises
(::com
::sun
::star
::lang
::IndexOutOfBoundsException
);