Logo Search packages:      
Sourcecode: yzis version File versions  Download package

YView::YView ( YBuffer _b,
YSession sess,
int  cols,
int  lines 
)

Each view is bound to a buffer,

  • lines is the initial number of columns and
  • lines the initial number of lines that this view can display

Definition at line 69 of file view.cpp.

References abortPaintEvent(), YBuffer::addView(), YViewCursor::bufferY(), drawMode, endl(), getId(), getLocalBooleanOption(), getLocalIntegerOption(), getLocalMapOption(), mBuffer, mColumnsVis, mLineSearch, mLinesVis, mPreviousChars, mSession, opt_schema, qp, rCurLineLength, reverseSearch, sCurLineLength, tabstop, YBuffer::textline(), YBuffer::toString(), and YASSERT.

        :
          m_drawBuffer(),
          mPreviousChars(""),mLastPreviousChars(""),
          mainCursor(this), scrollCursor(this), workCursor(this), mVisualCursor(this), keepCursor(this),
          id(nextId++)
{
    dbg().SPrintf("YView( %s, cols=%d, lines=%d )", qp(_b->toString()), cols, lines );
    dbg() << "New View created with UID: " << getId() << endl;
    YASSERT( _b ); YASSERT( sess );
    mSession = sess;
    mBuffer = _b;
    _b->addView( this );
    mLineSearch = new YLineSearch( this );
    mLinesVis = lines;
    mColumnsVis = cols;

    mModePool = new YModePool( this );

    /* start of visual mode */

    mFoldPool = new YZFoldPool( this );

    m_drawBuffer.setCallback( this );

    stickyCol = 0;

    QString line = mBuffer->textline(scrollCursor.bufferY());

    reverseSearch = false;
    mPreviousChars.clear();

    mPaintSelection = new YSelection("PAINT");
    selectionPool = new YSelectionPool();

    drawMode = false;
    rHLnoAttribs = false;
    rHLAttributesLen = 0;

    sCurLineLength = 0;
    rCurLineLength = 0;

    rHLnoAttribs = false;
    rHLAttributesLen = 0;
    listChar = false;
    mFillChar = ' ';

    lineDY = 0;
    tabstop = getLocalIntegerOption("tabstop");
    wrap = getLocalBooleanOption( "wrap" );
    rightleft = getLocalBooleanOption( "rightleft" );
    opt_schema = getLocalIntegerOption( "schema" );
    opt_list = getLocalBooleanOption( "list" );
    opt_listchars = getLocalMapOption( "listchars" );

    abortPaintEvent();
}


Generated by  Doxygen 1.6.0   Back to index