Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
GLViewer_AspectLine Class Reference

Class for manage of presentations in GLViewer. More...

#include <GLViewer_AspectLine.h>

Public Member Functions

 GLViewer_AspectLine ()
 A default constructor. More...
 
 GLViewer_AspectLine (int theType, float theWidth)
 A conctructor by type and width of line. More...
 
 ~GLViewer_AspectLine ()
 A destructor. More...
 
void setLineColors (QColor nc=Qt::black, QColor hc=Qt::cyan, QColor sc=Qt::red)
 A function for installing the line colors. More...
 
int setLineWidth (const float theWidth)
 A function for installing the line width. More...
 
int setLineType (const int theType)
 A function for installing the line type. More...
 
void getLineColors (QColor &theNC, QColor &theHC, QColor &theSC) const
 A function for getting line colors information. More...
 
float getLineWidth () const
 A function for getting information about line width. More...
 
int getLineType () const
 A function for getting information about line type. More...
 
QByteArray getByteCopy () const
 A function for coding object to the byte copy. More...
 

Static Public Member Functions

static GLViewer_AspectLinefromByteCopy (QByteArray)
 A function for decoding object from the byte copy. More...
 

Protected Attributes

QColor myNColor
 A normal color. More...
 
QColor myHColor
 A highlight color. More...
 
QColor mySColor
 A select color. More...
 
float myLineWidth
 A line width. More...
 
int myLineType
 A line type. More...
 

Detailed Description

GLViewer_AspectLine Substitution of Prs2d_AspectLine for OpenGL

Constructor & Destructor Documentation

GLViewer_AspectLine::GLViewer_AspectLine ( )

Default constructor

References myHColor, myLineType, myLineWidth, myNColor, and mySColor.

GLViewer_AspectLine::GLViewer_AspectLine ( int  type,
float  width 
)
Parameters
theTypeequals 0 for normal line and 1 for strip line
theWidthis a width of new line

Constructor

Parameters
type,:0 for normal line and 1 for strip line
width- width of line

References myHColor, myLineType, myLineWidth, myNColor, and mySColor.

GLViewer_AspectLine::~GLViewer_AspectLine ( )

Destructor

Member Function Documentation

GLViewer_AspectLine * GLViewer_AspectLine::fromByteCopy ( QByteArray  theBytes)
static

A function is used for copy-past technollogy in past method

Sets line aspect from binary representation

References GLViewer_AspectLine(), and setLineColors().

QByteArray GLViewer_AspectLine::getByteCopy ( ) const

A function is used for copy-past technollogy in copy method

Returns
binary representation of line aspect

References myHColor, myLineType, myLineWidth, myNColor, and mySColor.

void GLViewer_AspectLine::getLineColors ( QColor &  nc,
QColor &  hc,
QColor &  sc 
) const
Parameters
theNCis normal color
theHCis highlight color
theSCis select color
Returns
colors of line
Parameters
nc- variable for normal color
hc- variable for hilighting color
sc- variable for selection color

References myHColor, myNColor, and mySColor.

int GLViewer_AspectLine::getLineType ( ) const
inline
float GLViewer_AspectLine::getLineWidth ( ) const
inline
void GLViewer_AspectLine::setLineColors ( QColor  nc = Qt::black,
QColor  hc = Qt::cyan,
QColor  sc = Qt::red 
)
Parameters
ncis normal color
hcis highlight color
scis select color

Sets line color

Parameters
nc- normal color
hc- hilighting color
sc- selection color

References myHColor, myNColor, and mySColor.

int GLViewer_AspectLine::setLineType ( const int  type)
Parameters
theTypeequals 0 for normal line and 1 for strip line

Sets type of line

Parameters
type,:0 for normal line and 1 for strip line

References myLineType.

int GLViewer_AspectLine::setLineWidth ( const float  width)

Sets width of line

Parameters
width- new width of line

References myLineWidth.

Member Data Documentation

QColor GLViewer_AspectLine::myHColor
protected
int GLViewer_AspectLine::myLineType
protected

equals 0 for normal line and 1 for strip line

float GLViewer_AspectLine::myLineWidth
protected
QColor GLViewer_AspectLine::myNColor
protected
QColor GLViewer_AspectLine::mySColor
protected

The documentation for this class was generated from the following files: