- Main Page
- Namespaces
- Data Structures
- Files
- Directories

- File List
- Globals

# Accessibility_Text.idl

Go to the documentation of this file.

    00001 /*
    00002  * AT-SPI - Assistive Technology Service Provider Interface
    00003  * (Gnome Accessibility Project; http://developer.gnome.org/projects/gap)
    00004  *
    00005  * Copyright 2001 Sun Microsystems, Inc.
    00006  *
    00007  * This library is free software; you can redistribute it and/or
    00008  * modify it under the terms of the GNU Library General Public
    00009  * License as published by the Free Software Foundation; either
    00010  * version 2 of the License, or (at your option) any later version.
    00011  *
    00012  * This library is distributed in the hope that it will be useful,
    00013  * but WITHOUT ANY WARRANTY; without even the implied warranty of
    00014  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    00015  * Library General Public License for more details.
    00016  *
    00017  * You should have received a copy of the GNU Library General Public
    00018  * License along with this library; if not, write to the
    00019  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    00020  * Boston, MA 02111-1307, USA.
    00021  */
    00022
    00023 module Accessibility {
    00024
    00029   enum TEXT_BOUNDARY_TYPE {
    00030     TEXT_BOUNDARY_CHAR,
    00033     TEXT_BOUNDARY_WORD_START,
    00036     TEXT_BOUNDARY_WORD_END,
    00043     TEXT_BOUNDARY_SENTENCE_START,
    00049     TEXT_BOUNDARY_SENTENCE_END,
    00055     TEXT_BOUNDARY_LINE_START,
    00059     TEXT_BOUNDARY_LINE_END
    00063   };
    00064
    00072   enum TEXT_CLIP_TYPE {
    00073     TEXT_CLIP_NONE,
    00074     TEXT_CLIP_MIN,
    00075     TEXT_CLIP_MAX,
    00076     TEXT_CLIP_BOTH
    00077   };
    00078
    00119   interface Text : Bonobo::Unknown {
    00120
    00124     struct Range {
    00125       long startOffset;
    00126       long endOffset;
    00127       string content;
    00128       any  data;
    00129     };
    00130
    00131     typedef sequence<Range> RangeList;
    00132
    00136     readonly attribute long characterCount;
    00137
    00144     readonly attribute long caretOffset;
    00145
    00156     string getText (in long startOffset, in long endOffset);
    00157
    00164     boolean setCaretOffset (in long offset);
    00165
    00183     string getTextBeforeOffset (in long offset, in TEXT_BOUNDARY_TYPE type,
    00184                                 out long startOffset, out long endOffset);
    00202     string getTextAtOffset (in long offset, in TEXT_BOUNDARY_TYPE type,
    00203                                                         out long startOffset, out long endOffset);
    00222     string getTextAfterOffset (in long offset, in TEXT_BOUNDARY_TYPE type,
    00223                                                         out long startOffset, out long endOffset);
    00228     unsigned long getCharacterAtOffset (in long offset);  /* long instead of wchar,
    00229                                                            * to allow unicode chars > 16 bits
    00230                                                            */
    00243     string getAttributeValue (in long offset, in string attributeName,
    00244                               out long startOffset,
    00245                               out long endOffset,
    00246                               out boolean defined);
    00252     string getAttributes (in long offset,
    00253                           out long startOffset, out long endOffset);
    00260     string getDefaultAttributes ();
    00282     void getCharacterExtents (in long offset, out long x, out long y, out long width, out long height, in short coordType);
    00292     long getOffsetAtPoint (in long x, in long y, in short coordType);
    00302     long getNSelections ();
    00307     void getSelection (in long selectionNum, out long startOffset, out long endOffset);
    00317     boolean addSelection (in long startOffset, in long endOffset);
    00323     boolean removeSelection (in long selectionNum);
    00336     boolean setSelection (in long selectionNum, in long startOffset, in long endOffset);
    00356     void    getRangeExtents (in long startOffset, in long endOffset,
    00357                              out long x, out long y,
    00358                              out long width, out long height, in short coordType);
    00359
    00382     RangeList getBoundedRanges (in long x, in long y,
    00383                                 in long width, in long height,
    00384                                 in short coordType,
    00385                                 in TEXT_CLIP_TYPE xClipType,
    00386                                 in TEXT_CLIP_TYPE yClipType);
    00387
    00438     AttributeSet getAttributeRun (in long offset,
    00439                                   out long startOffset,
    00440                                   out long endOffset,
    00441                                   in boolean includeDefaults);
    00452     AttributeSet getDefaultAttributeSet ();
    00453
    00459     void unImplemented ();
    00460     void unImplemented2 ();
    00462   };
    00463 };