This is an internal class for Fl_Text_Buffer to manage text selections.  
 More...
#include <Fl_Text_Buffer.H>
|  | 
| int | end () const | 
|  | Return the byte offset to the character after the last selected character. 
 | 
|  | 
| int | includes (int pos) const | 
|  | Return true if position poswith indentationdispIndexis in the Fl_Text_Selection.
 | 
|  | 
| int | position (int *start, int *end) const | 
|  | Return the positions of this selection. 
 | 
|  | 
| bool | selected () const | 
|  | Returns true if any text is selected. 
 | 
|  | 
| void | selected (bool b) | 
|  | Modify the 'selected' flag. 
 | 
|  | 
| void | set (int start, int end) | 
|  | Set the selection range. 
 | 
|  | 
| int | start () const | 
|  | Return the byte offset to the first selected character. 
 | 
|  | 
| void | update (int pos, int nDeleted, int nInserted) | 
|  | Updates a selection after text was modified. 
 | 
|  | 
|  | 
| int | mEnd | 
|  | byte offset to the character after the last selected character 
 | 
|  | 
| bool | mSelected | 
|  | this flag is set if any text is selected 
 | 
|  | 
| int | mStart | 
|  | byte offset to the first selected character 
 | 
|  | 
This is an internal class for Fl_Text_Buffer to manage text selections. 
This class works correctly with UTF-8 strings assuming that the parameters for all calls are on character boundaries. 
◆ end()
  
  | 
        
          | int Fl_Text_Selection::end | ( |  | ) | const |  | inline | 
 
Return the byte offset to the character after the last selected character. 
- Returns
- byte offset 
 
 
◆ position()
      
        
          | int Fl_Text_Selection::position | ( | int * | start, | 
        
          |  |  | int * | end ) const | 
      
 
Return the positions of this selection. 
- Parameters
- 
  
    | start | return byte offset to first selected character |  | end | return byte offset pointing after last selected character |  
 
- Returns
- true if selected 
 
 
◆ selected() [1/2]
  
  | 
        
          | bool Fl_Text_Selection::selected | ( |  | ) | const |  | inline | 
 
Returns true if any text is selected. 
- Returns
- a non-zero number if any text has been selected, or 0 if no text is selected. 
 
 
◆ selected() [2/2]
  
  | 
        
          | void Fl_Text_Selection::selected | ( | bool | b | ) |  |  | inline | 
 
Modify the 'selected' flag. 
- Parameters
- 
  
  
 
 
◆ set()
      
        
          | void Fl_Text_Selection::set | ( | int | start, | 
        
          |  |  | int | end ) | 
      
 
Set the selection range. 
- Parameters
- 
  
    | start | byte offset to first selected character |  | end | byte offset pointing after last selected character |  
 
 
 
◆ start()
  
  | 
        
          | int Fl_Text_Selection::start | ( |  | ) | const |  | inline | 
 
Return the byte offset to the first selected character. 
- Returns
- byte offset 
 
 
◆ update()
      
        
          | void Fl_Text_Selection::update | ( | int | pos, | 
        
          |  |  | int | nDeleted, | 
        
          |  |  | int | nInserted ) | 
      
 
Updates a selection after text was modified. 
Updates an individual selection for changes in the corresponding text 
- Parameters
- 
  
    | pos | byte offset into text buffer at which the change occurred |  | nDeleted | number of bytes deleted from the buffer |  | nInserted | number of bytes inserted into the buffer |  
 
 
 
The documentation for this class was generated from the following files: