TGText A TGText is a multi line text buffer. It allows the text to be loaded from file, saved to file and edited. It is used in the TGTextEdit widget. Single line text is handled by TGTextBuffer and the TGTextEntry widget.
void | Init() |
void | LongestLine() |
TGText& | operator=(const TGText&) |
Bool_t | SetCurrentRow(Long_t row) |
TGText(const TGText&) |
Long_t | fColCount | number of columns in current line |
TGTextLine* | fCurrent | current line |
Long_t | fCurrentRow | current row number |
TString | fFilename | name of opened file ("" if open buffer) |
TGTextLine* | fFirst | first line of text |
Bool_t | fIsSaved | false if text needs to be saved |
Long_t | fLongestLine | length of longest line |
Long_t | fRowCount | number of rows |
Load text from file fn. Startpos is the begin from where to load the file and length is the number of characters to read from the file.
Delete text between start and end positions. Returns false in case of failure (start and end not being within bounds).
Insert src text from start_src to end_src into text at position ins_pos. Returns false in case of failure (start_src, end_src out of range for src, and ins_pos out of range for this).
Insert single line at specified position. Return false in case position is out of bounds.
Insert string before specified position. Returns false if insertion failed.
Return string at position pos. Returns 0 in case pos is not valid. The returned string must be deleted by the user.
Make specified row the current row. Returns false if row does not exist. In which case fCurrent is not changed or set to the last valid line.
Search for string searchString starting at the specified position going in forward (direction = true) or backward direction. Returns true if found and foundPos is set accordingly.
Replace oldText by newText. Returns false if nothing replaced.