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

int VTScreenBuffer_add_char ( VTScreenBuffer buf,
int  col,
int  row,
Char mbchar,
int  bold,
int  blink,
int  inverse,
int  underline,
int  foreground,
int  background,
char  charset 
)

adding Char object into specified col/row of the buffer object.

Parameters:
*buf reference to Buffer object to destruct
col column of Cell to add character. must be 0<=, <buf->num_cols
row row of Cell to add character. must be 0<= , <buf->num_rows
mbchar Char object to add
bold attribute of the Cell
inverse attribute of the Cell
underline attribute of the Cell
Returns:
0 if successfully added else 1

Definition at line 94 of file screen_buffer.c.

References IS_COMBINED, _VTScreenBuf::num_cols, and _VTScreenBuf::rows.

{
  if(col < 0 || buf->num_cols <= col ||
     row < 0 || buf->num_rows <= row)
      return 1;

  if(IS_COMBINED(mbchar))
  {
    if(col == 0)
    {
      if(row == 0)
          return 1;
      else
          return Row_add_char(buf->rows[row-1],buf->num_cols-1,
                              mbchar,bold,blink,inverse,underline,
                              foreground,background,charset);
    }
  }

  return Row_add_char(buf->rows[row],col,mbchar,
                      bold,blink,inverse,underline,foreground,background,
                      charset);
}


Generated by  Doxygen 1.6.0   Back to index