Ignore:
Timestamp:
Mar 8, 2010, 12:52:58 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.6.2 sources.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/gui/text/qtextcursor.cpp

    r561 r651  
    11/****************************************************************************
    22**
    3 ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
     3** Copyright (C) 20 Nokia Corporation and/or its subsidiary(-ies).
    44** All rights reserved.
    55** Contact: Nokia Corporation ([email protected])
     
    863863    \ingroup shared
    864864
    865 
    866     Text cursors are objects that are used to access and modify the contents
    867     and underlying structure of text documents via a programming interface
    868     that mimics the behavior of a cursor in a text editor. QTextCursor contains
    869     information about both the cursor's position within a QTextDocument and any
    870     selection that it has made.
     865    Text cursors are objects that are used to access and modify the
     866   
     867   
     868    t
     869   
     870    has made.
    871871
    872872    QTextCursor is modeled on the way a text cursor behaves in a text
    873     editor, providing a programmatic means of performing standard actions
    874     through the user interface. A document can be thought of as a
    875     single string of characters with the cursor's position() being \e
    876     between any two characters (or at the very beginning or very end
    877     of the document). Documents can also contain tables, lists,
    878     images, and other objects in addition to text but, from the developer's
    879     point of view, the document can be treated as one long string.
    880     Some portions of that string can be considered to lie within particular
    881     blocks (e.g. paragraphs), or within a table's cell, or a list's item,
    882     or other structural elements. When we refer to "current character" we
    883     mean the character immediately after the cursor position() in the
    884     document; similarly the "current block" is the block that contains the
    885     cursor position().
     873    editor, providing a programmatic means of performing standard
     874    actions through the user interface. A document can be thought of
     875    as a single string of characters. The cursor's current position()
     876    then is always either \e between two consecutive characters in the
     877    string, or else \e before the very first character or \e after the
     878    very last character in the string.  Documents can also contain
     879    tables, lists, images, and other objects in addition to text but,
     880    from the developer's point of view, the document can be treated as
     881    one long string.  Some portions of that string can be considered
     882    to lie within particular blocks (e.g. paragraphs), or within a
     883    table's cell, or a list's item, or other structural elements. When
     884    we refer to "current character" we mean the character immediately
     885    \e before the cursor position() in the document. Similarly, the
     886    "current block" is the block that contains the cursor position().
    886887
    887888    A QTextCursor also has an anchor() position. The text that is
     
    941942
    942943    Cursor movements are limited to valid cursor positions. In Latin
    943     writing this is usually after every character in the text. In some
    944     other writing systems cursor movements are limited to "clusters"
    945     (e.g. a syllable in Devanagari, or a base letter plus diacritics).
    946     Functions such as movePosition() and deleteChar() limit cursor
    947     movement to these valid positions.
     944    writing this is between any two consecutive characters in the
     945    text, before the first character, or after the last character. In
     946    some other writing systems cursor movements are limited to
     947    "clusters" (e.g. a syllable in Devanagari, or a base letter plus
     948    diacritics).  Functions such as movePosition() and deleteChar()
     949    limit cursor movement to these valid positions.
    948950
    949951    \sa \link richtext.html Rich Text Processing\endlink
     
    17401742
    17411743/*!
    1742     Returns the format of the character immediately before the cursor position(). If the cursor is
    1743     positioned at the beginning of a text block that is not empty then the format of the character
     1744    Returns the format of the character immediately before the cursor
     1745    position(). If the cursor is positioned at the beginning of a text
     1746    block that is not empty then the format of the character
    17441747    immediately after the cursor is returned.
    17451748
Note: See TracChangeset for help on using the changeset viewer.