1 /*
2 **
3 ** Vlist.h
4 **
5 ** Copyright (C) 1995, 1996, 1997 Johannes Plass
6 ** Copyright (C) 2004 Jose E. Marchesi
7 **
8 ** This program is free software; you can redistribute it and/or modify
9 ** it under the terms of the GNU General Public License as published by
10 ** the Free Software Foundation; either version 3 of the License, or
11 ** (at your option) any later version.
12 **
13 ** This program is distributed in the hope that it will be useful,
14 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
15 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 ** GNU General Public License for more details.
17 **
18 ** You should have received a copy of the GNU General Public License
19 ** along with GNU gv; see the file COPYING.  If not, write to
20 ** the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21 ** Boston, MA 02111-1307, USA.
22 **
23 ** Author:   Johannes Plass (plass@thep.physik.uni-mainz.de)
24 **           Department of Physics
25 **           Johannes Gutenberg-University
26 **           Mainz, Germany
27 **
28 **           Jose E. Marchesi (jemarch@gnu.org)
29 **           GNU Project
30 **
31 */
32 
33 #ifndef _Vlist_h_
34 #define _Vlist_h_
35 
36 #include "paths.h"
37 #include INC_XAW(Label.h)
38 #include INC_XAW(Reports.h)
39 
40 #define XawVlistAll     -13
41 #define XawVlistEven    -12
42 #define XawVlistOdd     -11
43 #define XawVlistCurrent -10
44 #define XawVlistInvalid  -1
45 #define XawVlistSet       1
46 #define XawVlistUnset     2
47 #define XawVlistToggle    3
48 
49 #define XtNvlist "vlist"
50 #define XtCVlist "Vlist"
51 #define XtNmarkShadowWidth "markShadowWidth"
52 #define XtNselectedShadowWidth "selectedShadowWidth"
53 #define XtNhighlightedShadowWidth "highlightedShadowWidth"
54 #define XtNmarkBackground "markBackground"
55 #define XtCMarkBackground "MarkBackground"
56 #define XtNselectedBackground "selectedBackground"
57 #define XtCSelectedBackground "SelectedBackground"
58 #define XtNhighlightedBackground "highlightedBackground"
59 #define XtCHighlightedBackground "HighlightedBackground"
60 #define XtNhighlightedGeometry "highlightedGeometry"
61 #define XtCHighlightedGeometry "HighlightedGeometry"
62 #define XtNselectedGeometry "selectedGeometry"
63 #define XtCSelectedGeometry "SelectedGeometry"
64 #define XtNallowMarks "allowMarks"
65 #define XtCAllowMarks "AllowMarks"
66 
67 extern WidgetClass vlistWidgetClass;
68 
69 typedef struct _VlistClassRec   *VlistWidgetClass;
70 typedef struct _VlistRec        *VlistWidget;
71 
72 extern int   VlistHighlighted (Widget);
73 extern int   VlistSelected (Widget);
74 extern int   VlistEntries (Widget);
75 extern char* VlistVlist (Widget);
76 extern int   VlistEntryOfPosition (Widget, int);
77 extern void  VlistPositionOfEntry (Widget, int, int*, int*);
78 extern void  VlistChangeMark (Widget, int, int);
79 extern void  VlistChangeSelected (Widget, int, int);
80 extern void  VlistChangeHighlighted (Widget, int, int);
81 extern int   VlistGetFirstVisible(Widget);
82 extern void  VlistSetFirstVisible(Widget, int);
83 extern void  VlistMoveFirstVisible(Widget, int, int);
84 extern float VlistScrollPosition(Widget);
85 extern float VlistVisibleLength(Widget, unsigned int);
86 extern int   VlistMaxEntriesVisible (Widget, int);
87 
88 #endif /* _Vlist_h_ */
89