]> git.lyx.org Git - features.git/blob - src/pathstack.h
fix for para 3
[features.git] / src / pathstack.h
1 // -*- C++ -*-
2 // lyx-stack.H : definition of PathStack class
3 //   this file is part of LyX, the High Level Word Processor
4 //   copyright (C) 1995-1996, Matthias Ettrich and the LyX Team
5
6 #ifndef __LYX_STACK_H__
7 #define __LYX_STACK_H__
8
9 #ifdef __GNUG__
10 #pragma interface
11 #endif
12
13 #include "LString.h"
14
15 /// Path stack class definition
16 class PathStack {
17 public:
18         ///
19         PathStack() {
20                 Next = 0;
21         }
22         ///
23         PathStack(string const & Path);
24         ///
25         ~PathStack();
26         ///
27         int PathPush(string const & Path);
28         ///
29         int PathPop();
30 private:
31         ///
32         string Path;
33         ///
34         PathStack *Next;
35 };
36
37 // global path stack
38 extern PathStack lyxPathStack;
39
40 /// some global wrapper functions
41 inline int PathPush(string const & szPath) {
42         return lyxPathStack.PathPush(szPath);
43 }
44
45 ///
46 inline int PathPop() { 
47         return lyxPathStack.PathPop(); 
48 }
49
50 #endif