2005-06-22 11:20:32 -07:00
|
|
|
/*
|
2005-10-13 07:08:18 -07:00
|
|
|
* mootermline.h
|
2005-06-22 11:20:32 -07:00
|
|
|
*
|
2006-02-23 06:03:17 -08:00
|
|
|
* Copyright (C) 2004-2006 by Yevgen Muntyan <muntyan@math.tamu.edu>
|
2005-06-22 11:20:32 -07:00
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* See COPYING file that comes with this distribution.
|
|
|
|
*/
|
|
|
|
|
2005-10-13 07:08:18 -07:00
|
|
|
#ifndef __MOO_TERM_LINE_H__
|
|
|
|
#define __MOO_TERM_LINE_H__
|
|
|
|
|
2005-10-15 22:07:02 -07:00
|
|
|
#include "mooterm/mootermtag.h"
|
2005-06-22 11:20:32 -07:00
|
|
|
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
|
|
|
|
|
2005-10-15 22:07:02 -07:00
|
|
|
typedef struct _MooTermCell MooTermCell;
|
|
|
|
typedef struct _MooTermLine MooTermLine;
|
2005-06-22 11:20:32 -07:00
|
|
|
|
2005-12-04 08:23:10 -08:00
|
|
|
#define MOO_TYPE_TERM_LINE (moo_term_line_get_type ())
|
|
|
|
|
2005-06-22 11:20:32 -07:00
|
|
|
|
2005-10-15 22:07:02 -07:00
|
|
|
#define MOO_TERM_EMPTY_CHAR ' '
|
|
|
|
#define MOO_TERM_ZERO_ATTR {0, 0, 0}
|
2005-07-06 16:41:14 -07:00
|
|
|
|
|
|
|
/* FALSE if equal */
|
2005-10-15 22:07:02 -07:00
|
|
|
#define MOO_TERM_TEXT_ATTR_EQUAL(a1__,a2__) \
|
|
|
|
((a1__).mask == (a2__).mask && \
|
|
|
|
(!((a1__).mask & MOO_TERM_TEXT_FOREGROUND) || \
|
|
|
|
(a1__).foreground == (a2__).foreground) && \
|
|
|
|
(!((a1__).mask & MOO_TERM_TEXT_BACKGROUND) || \
|
|
|
|
(a1__).background == (a2__).background))
|
2005-07-06 16:41:14 -07:00
|
|
|
|
|
|
|
|
2005-12-04 08:23:10 -08:00
|
|
|
GType moo_term_line_get_type (void) G_GNUC_CONST;
|
|
|
|
|
2005-10-15 22:07:02 -07:00
|
|
|
guint moo_term_line_len (MooTermLine *line);
|
|
|
|
gunichar moo_term_line_get_char (MooTermLine *line,
|
|
|
|
guint index_);
|
2005-06-22 11:20:32 -07:00
|
|
|
|
2005-11-30 07:03:26 -08:00
|
|
|
char *moo_term_line_get_text (MooTermLine *line,
|
|
|
|
guint index_,
|
|
|
|
guint len);
|
|
|
|
|
2005-06-22 11:20:32 -07:00
|
|
|
|
|
|
|
G_END_DECLS
|
|
|
|
|
2005-10-13 07:08:18 -07:00
|
|
|
#endif /* __MOO_TERM_LINE_H__ */
|