1 /* $Id: tags.h,v 1.16 2005/02/15 01:10:16 n8gray Exp $ */
2 /*******************************************************************************
4 * tags.h -- Nirvana Editor Tags Header File *
6 * Copyright 2002 The NEdit Developers *
8 * This is free software; you can redistribute it and/or modify it under the *
9 * terms of the GNU General Public License as published by the Free Software *
10 * Foundation; either version 2 of the License, or (at your option) any later *
11 * version. In addition, you may distribute versions of this program linked to *
12 * Motif or Open Motif. See README for details. *
14 * This software is distributed in the hope that it will be useful, but WITHOUT *
15 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or *
16 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for *
19 * You should have received a copy of the GNU General Public License along with *
20 * software; if not, write to the Free Software Foundation, Inc., 59 Temple *
21 * Place, Suite 330, Boston, MA 02111-1307 USA *
23 * Nirvana Text Editor *
26 *******************************************************************************/
28 #ifndef NEDIT_TAGS_H_INCLUDED
29 #define NEDIT_TAGS_H_INCLUDED
33 #include <X11/Intrinsic.h>
37 typedef struct _tagFile
{
38 struct _tagFile
*next
;
43 short refcount
; /* Only tips files are refcounted, not tags files */
46 extern tagFile
*TagsFileList
; /* list of loaded tags files */
47 extern tagFile
*TipsFileList
; /* list of loaded calltips tag files */
49 /* file_type and search_type arguments are to select between tips and tags,
50 and should be one of TAG or TIP. TIP_FROM_TAG is for ShowTipString. */
51 enum mode
{TAG
, TIP_FROM_TAG
, TIP
};
53 int AddRelTagsFile(const char *tagSpec
, const char *windowPath
,
55 /* tagSpec is a colon-delimited list of filenames */
56 int AddTagsFile(const char *tagSpec
, int file_type
);
57 int DeleteTagsFile(const char *tagSpec
, int file_type
, Boolean force_unload
);
58 int LookupTag(const char *name
, const char **file
, int *lang
,
59 const char **searchString
, int * pos
, const char **path
,
62 /* Routines for handling tags or tips from the current selection */
63 void FindDefinition(WindowInfo
*window
, Time time
, const char *arg
);
64 void FindDefCalltip(WindowInfo
*window
, Time time
, const char *arg
);
66 /* Display (possibly finding first) a calltip. Search type can only be
67 TIP or TIP_FROM_TAG here. */
68 int ShowTipString(WindowInfo
*window
, char *text
, Boolean anchored
,
69 int pos
, Boolean lookup
, int search_type
, int hAlign
, int vAlign
,
72 #endif /* NEDIT_TAGS_H_INCLUDED */