gtkIOStream  1.7.0
GTK+ << C++ IOStream operators for GTK+. Now with ORBing, numerical computation, audio client and more ...
TextView Class Reference

#include <TextView.H>

Inheritance diagram for TextView:
[legend]
Collaboration diagram for TextView:
[legend]

Public Member Functions

 TextView (void)
 
void setFont (PangoFontDescription *pangoFontDescription)
 
void connectBufferChangedSignal (GCallback callBack, void *data)
 
void setText (string &text)
 
void setText (const char *text)
 
string getText (void)
 
TextViewoperator<< (string &text)
 
TextViewoperator<< (const char *text)
 
TextViewoperator>> (string &text)
 
TextViewoperator>> (int &num)
 
TextViewoperator>> (long &num)
 
template<typename TYPE >
TextViewoperator>> (TYPE &var)
 
- Public Member Functions inherited from Container
void setBorder (unsigned int size)
 
unsigned int getBorder (void)
 
Containeroperator<< (Container &c)
 
Containeroperator<< (Container *c)
 
Containeroperator<< (Widget &w)
 
Containeroperator<< (Widget *w)
 
virtual Containeroperator<< (GtkWidget *w)
 
Containeroperator<< (LinkList< GtkWidget *> &ll)
 
Containeroperator>> (GtkWidget *w)
 
Containeroperator>> (Container *c)
 
Containeroperator>> (Container &c)
 
Containeroperator>> (LinkList< GtkWidget *> &ll)
 
void setChildrensSensitivity (bool sens)
 
bool areAnyChildrensSensitive (void)
 
unsigned int size ()
 
- Public Member Functions inherited from Widget
 Widget ()
 Construcotr. More...
 
 Widget (GtkWidget *w)
 
virtual ~Widget ()
 Destructor. More...
 
GtkWidget * ref (void)
 
void unref (void)
 
GtkWidget * show (void)
 
GtkWidget * hide (void)
 
bool getVisible (void)
 
GtkWidget * getWidget (void)
 
bool getSensitive (void)
 
void setSensitive (bool sens)
 
void getSize (int &width, int &height)
 
virtual void setSize (int width, int height)
 
void getLocationSize (int &x, int &y, int &width, int &height)
 
void queueDraw ()
 
GdkWindow * getWindow ()
 
void connect (const char *event, GCallback callback, gpointer data)
 
void connectAfter (const char *event, GCallback callback, gpointer data)
 
void connectExposeEventCallback (GCallback callback, void *data)
 
void connectExposeEventCallback (GtkWidget *w, GCallback callback, void *data)
 
void connectConfigureEventCallback (GCallback callback, void *data)
 
void connectConfigureEventCallback (GtkWidget *w, GCallback callback, void *data)
 
Widgetoperator<< (DragNDrop &dnd)
 
Widgetoperator>> (DragNDrop &dnd)
 

Additional Inherited Members

- Protected Member Functions inherited from Container
virtual void pack (GtkWidget *obj)
 
- Protected Member Functions inherited from Widget
virtual bool checkDropValidity (GtkWidget *w, GtkWidget *sourceWidget, int info, const unsigned char *selectionStoredData)
 
virtual bool dragDataReceived (GtkWidget *w, GtkWidget *sourceWidget, int info, const unsigned char *selectionStoredData, int length)
 
virtual void dragLeave (GtkWidget *w, GtkWidget *sourceWidget)
 
virtual bool dragMotion (GtkWidget *w, GtkWidget *sourceWidget, int x, int y)
 
virtual int chooseTheTargetToUse (GtkWidget *w, GtkWidget *sourceWidget, DragNDrop &dnd)
 
virtual void dragDataGet (GtkWidget *w, GtkSelectionData *selectionData, guint info)
 
virtual void dragDataDelete (GtkWidget *w)
 
virtual void dragBegin (GtkWidget *w)
 
virtual void dragEnd (GtkWidget *w)
 
- Protected Attributes inherited from Widget
GtkWidget * widget
 The container based widget. More...
 

Detailed Description

TextView

Simple TextView widget.

Examples:
DragNDropNowindowTest.C, DragNDropSimpleTest.C, and TextViewTest.C.

Definition at line 29 of file TextView.H.

Constructor & Destructor Documentation

◆ TextView()

TextView::TextView ( void  )
inline

Constructor

Definition at line 33 of file TextView.H.

Member Function Documentation

◆ connectBufferChangedSignal()

void TextView::connectBufferChangedSignal ( GCallback  callBack,
void *  data 
)
inline

Connect a callback to capture when the text has changed in the text view buffer

Examples:
TextViewTest.C.

Definition at line 55 of file TextView.H.

◆ getText()

string TextView::getText ( void  )
inline

Get the buffer's text.

Returns
text The text to insert. It must be null terminated.
Examples:
TextViewTest.C.

Definition at line 80 of file TextView.H.

Here is the caller graph for this function:

◆ operator<<() [1/2]

TextView& TextView::operator<< ( string &  text)
inline

Operator to insert text

Parameters
textthe text to insert
Returns
a reference to this class

Definition at line 97 of file TextView.H.

Here is the call graph for this function:

◆ operator<<() [2/2]

TextView& TextView::operator<< ( const char *  text)
inline

Operator to insert text

Parameters
textthe text to insert. Must be null terminated.
Returns
a reference to this class

Definition at line 106 of file TextView.H.

Here is the call graph for this function:

◆ operator>>() [1/4]

TextView& TextView::operator>> ( string &  text)
inline

Operator to get text.

Parameters
textthe text to fill with the content of the TextView buffer.
Returns
a reference to this class

Definition at line 115 of file TextView.H.

Here is the call graph for this function:

◆ operator>>() [2/4]

TextView& TextView::operator>> ( int &  num)
inline

Operator to get an integer.

Parameters
numthe int to fill with the content of the TextView buffer.
Returns
a reference to this class

Definition at line 124 of file TextView.H.

Here is the call graph for this function:

◆ operator>>() [3/4]

TextView& TextView::operator>> ( long &  num)
inline

Operator to get an integer.

Parameters
numthe long to fill with the content of the TextView buffer.
Returns
a reference to this class

Definition at line 143 of file TextView.H.

Here is the call graph for this function:

◆ operator>>() [4/4]

template<typename TYPE >
TextView& TextView::operator>> ( TYPE &  var)
inline

Operator to get an arbitrary type.

Parameters
varthe var to fill with the content of the TextView buffer.
Returns
a reference to this class
Template Parameters
Thetype to format the TextView buffer contents to.

Definition at line 164 of file TextView.H.

Here is the call graph for this function:

◆ setFont()

void TextView::setFont ( PangoFontDescription *  pangoFontDescription)
inline

Set the font For example :

#include "Pango.H"
Font font("bold"); // could be something else, like "Sans 12"
TextView textView;
textView.setLabelsFont(font.getPangoFontDescription());

Definition at line 48 of file TextView.H.

◆ setText() [1/2]

void TextView::setText ( string &  text)
inline

Set the buffer text, deleting any text which is present.

Parameters
textThe string to insert.

Definition at line 64 of file TextView.H.

Here is the caller graph for this function:

◆ setText() [2/2]

void TextView::setText ( const char *  text)
inline

Set the buffer text, deleting any text which is present.

Parameters
textThe text to insert. It must be null terminated.

Definition at line 71 of file TextView.H.


The documentation for this class was generated from the following file:
gtkIOStream: TextView Class Reference
GTK+ IOStream  Beta