Belle II Software
release-08-01-10
|
Widget which contains the dynamic amount of TGLabel objects. More...
#include <MultilineWidget.h>
Public Member Functions | |
MultilineWidget (const TGWindow *p=0, const char *title=0, int line_count=0) | |
Create multiline widget with parent window p. | |
int | getLineCount () |
Return number of lines in widget. | |
void | setLineCount (int count) |
Add or remove lines depending on current line count. More... | |
void | removeLine (int line_id) |
Remove line with specified id. | |
void | removeLastLine () |
Removes last line from multiline widget and reduces line count. | |
void | setLine (int line_id, const char *text) |
Set content of the specified line to 'text'. | |
void | addLine (const char *text=0) |
Append line to multiline widget. | |
Private Attributes | |
std::vector< TGLabel * > | lines |
Content of multiline widget. | |
Widget which contains the dynamic amount of TGLabel objects.
Compared to TGTextView, this class allows to update lines frequently without without redrawing the entire text. There is no internal checks for the correctness of remove operations.
Definition at line 30 of file MultilineWidget.h.
void setLineCount | ( | int | count | ) |
Add or remove lines depending on current line count.
If the specified count is less than previous, lines are removed from the bottom of the widget.
Definition at line 39 of file MultilineWidget.cc.