GNU Octave  3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Public Types | Public Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
HistoryScrollBuffer Class Reference

#include "History.h"

Inheritance diagram for HistoryScrollBuffer:
Inheritance graph
[legend]
Collaboration diagram for HistoryScrollBuffer:
Collaboration graph
[legend]

Public Types

typedef QVector< CharacterHistoryLine

Public Member Functions

 HistoryScrollBuffer (unsigned int maxNbLines=1000)
virtual ~HistoryScrollBuffer ()
virtual void addCells (const Character a[], int count)
virtual void addCellsVector (const QVector< Character > &cells)
virtual void addLine (bool previousWrapped=false)
Character getCell (int lineno, int colno)
virtual void getCells (int lineno, int colno, int count, Character res[])
virtual int getLineLen (int lineno)
virtual int getLines ()
const HistoryTypegetType ()
virtual bool hasScroll ()
virtual bool isWrappedLine (int lineno)
unsigned int maxNbLines ()
void setMaxNbLines (unsigned int nbLines)

Protected Attributes

HistoryTypem_histType

Private Member Functions

int bufferIndex (int lineNumber)

Private Attributes

int _head
HistoryLine_historyBuffer
int _maxLineCount
int _usedLines
QBitArray _wrappedLine

Detailed Description

Definition at line 151 of file History.h.

Member Typedef Documentation

Definition at line 154 of file History.h.

Constructor & Destructor Documentation

HistoryScrollBuffer::HistoryScrollBuffer ( unsigned int  maxNbLines = 1000)

Definition at line 279 of file History.cpp.

References setMaxNbLines().

HistoryScrollBuffer::~HistoryScrollBuffer ( )
virtual

Definition at line 289 of file History.cpp.

References _historyBuffer.

Member Function Documentation

void HistoryScrollBuffer::addCells ( const Character  a[],
int  count 
)
virtual

Implements HistoryScroll.

Definition at line 308 of file History.cpp.

References addCellsVector().

void HistoryScrollBuffer::addCellsVector ( const QVector< Character > &  cells)
virtual

Reimplemented from HistoryScroll.

Definition at line 294 of file History.cpp.

References _head, _historyBuffer, _maxLineCount, _usedLines, _wrappedLine, and bufferIndex().

Referenced by addCells().

void HistoryScrollBuffer::addLine ( bool  previousWrapped = false)
virtual

Implements HistoryScroll.

Definition at line 316 of file History.cpp.

References _usedLines, _wrappedLine, and bufferIndex().

int HistoryScrollBuffer::bufferIndex ( int  lineNumber)
private

Definition at line 396 of file History.cpp.

References _head, _maxLineCount, and _usedLines.

Referenced by addCellsVector(), addLine(), getCells(), getLineLen(), isWrappedLine(), and setMaxNbLines().

Character HistoryScroll::getCell ( int  lineno,
int  colno 
)
inlineinherited

Definition at line 94 of file History.h.

References HistoryScroll::getCells().

void HistoryScrollBuffer::getCells ( int  lineno,
int  colno,
int  count,
Character  res[] 
)
virtual

Implements HistoryScroll.

Definition at line 353 of file History.cpp.

References _historyBuffer, _maxLineCount, _usedLines, and bufferIndex().

int HistoryScrollBuffer::getLineLen ( int  lineno)
virtual

Implements HistoryScroll.

Definition at line 326 of file History.cpp.

References _historyBuffer, _maxLineCount, _usedLines, and bufferIndex().

int HistoryScrollBuffer::getLines ( )
virtual

Implements HistoryScroll.

Definition at line 321 of file History.cpp.

References _usedLines.

const HistoryType& HistoryScroll::getType ( )
inlineinherited

Definition at line 112 of file History.h.

References HistoryScroll::m_histType.

Referenced by Screen::getScroll().

bool HistoryScroll::hasScroll ( )
virtualinherited

Reimplemented in HistoryScrollNone.

Definition at line 192 of file History.cpp.

Referenced by Screen::hasScroll().

bool HistoryScrollBuffer::isWrappedLine ( int  lineno)
virtual

Implements HistoryScroll.

Definition at line 340 of file History.cpp.

References _maxLineCount, _usedLines, _wrappedLine, and bufferIndex().

unsigned int HistoryScrollBuffer::maxNbLines ( )
inline

Definition at line 169 of file History.h.

References _maxLineCount.

void HistoryScrollBuffer::setMaxNbLines ( unsigned int  nbLines)

Member Data Documentation

int HistoryScrollBuffer::_head
private

Definition at line 179 of file History.h.

Referenced by addCellsVector(), bufferIndex(), and setMaxNbLines().

HistoryLine* HistoryScrollBuffer::_historyBuffer
private

Definition at line 175 of file History.h.

Referenced by addCellsVector(), getCells(), getLineLen(), setMaxNbLines(), and ~HistoryScrollBuffer().

int HistoryScrollBuffer::_maxLineCount
private
int HistoryScrollBuffer::_usedLines
private
QBitArray HistoryScrollBuffer::_wrappedLine
private

Definition at line 176 of file History.h.

Referenced by addCellsVector(), addLine(), isWrappedLine(), and setMaxNbLines().

HistoryType* HistoryScroll::m_histType
protectedinherited

Definition at line 115 of file History.h.

Referenced by HistoryScroll::getType(), and HistoryScroll::~HistoryScroll().


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