]> git.lyx.org Git - lyx.git/blob - src/errorlist.h
Simplify the mechanics of generating the 'inactive' pixmap.
[lyx.git] / src / errorlist.h
1 // -*- C++ -*-
2 /**
3  * \file errorlist.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Alfredo Braunstein
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef ERRORLIST_H
13 #define ERRORLIST_H
14
15 #include "support/types.h"
16
17 #include <vector>
18 #include <string>
19
20 class Buffer;
21
22 /// A class to hold an error item
23 struct ErrorItem {
24         std::string error;
25         std::string description;
26         int par_id;
27         lyx::pos_type pos_start;
28         lyx::pos_type pos_end;
29         ErrorItem(std::string const & error, std::string const & description,
30                   int parid, lyx::pos_type posstart, lyx::pos_type posend);
31         ErrorItem();
32 };
33
34
35 class ErrorList : private std::vector<ErrorItem>
36 {
37 public:
38         ErrorList() : std::vector<ErrorItem> () {};
39
40         using std::vector<ErrorItem>::push_back;
41         using std::vector<ErrorItem>::end;
42         using std::vector<ErrorItem>::begin;
43         using std::vector<ErrorItem>::operator[];
44         using std::vector<ErrorItem>::size;
45         using std::vector<ErrorItem>::clear;
46         using std::vector<ErrorItem>::empty;
47         using std::vector<ErrorItem>::const_iterator;
48 };
49
50 #endif