3 * Copyright (c) 2014 The Geany contributors
5 * This source code is released for free distribution under the terms of the
6 * GNU General Public License.
18 Types of tags. It is a bitmask so that multiple tag types can
19 be used simultaneously by 'OR'-ing them bitwise.
20 e.g. tm_tag_class_t | tm_tag_struct_t
24 tm_tag_undef_t
= 0, /**< Unknown type */
25 tm_tag_class_t
= 1, /**< Class declaration */
26 tm_tag_enum_t
= 2, /**< Enum declaration */
27 tm_tag_enumerator_t
= 4, /**< Enumerator value */
28 tm_tag_field_t
= 8, /**< Field (Java only) */
29 tm_tag_function_t
= 16, /**< Function definition */
30 tm_tag_interface_t
= 32, /**< Interface (Java only) */
31 tm_tag_member_t
= 64, /**< Member variable of class/struct */
32 tm_tag_method_t
= 128, /**< Class method (Java only) */
33 tm_tag_namespace_t
= 256, /**< Namespace declaration */
34 tm_tag_package_t
= 512, /**< Package (Java only) */
35 tm_tag_prototype_t
= 1024, /**< Function prototype */
36 tm_tag_struct_t
= 2048, /**< Struct declaration */
37 tm_tag_typedef_t
= 4096, /**< Typedef */
38 tm_tag_union_t
= 8192, /**< Union */
39 tm_tag_variable_t
= 16384, /**< Variable */
40 tm_tag_externvar_t
= 32768, /**< Extern or forward declaration */
41 tm_tag_macro_t
= 65536, /**< Macro (without arguments) */
42 tm_tag_macro_with_arg_t
= 131072, /**< Parameterized macro */
43 tm_tag_local_var_t
= 262144, /**< Local variable (inside function) */
44 tm_tag_other_t
= 524288, /**< Other (non C/C++/Java tag) */
45 tm_tag_max_t
= 1048575 /**< Maximum value of TMTagType */
50 * A integral type which can hold known parser type IDs
52 typedef gint TMParserType
;
57 /* keep in sync with tm_parsers.h and parser_map in tm_parser.c */
60 TM_PARSER_NONE
= -2, /* keep in sync with ctags LANG_IGNORE */
96 TM_PARSER_ACTIONSCRIPT
,
111 TM_PARSER_POWERSHELL
,
114 TM_PARSER_CPREPROCESSOR
,
118 TM_PARSER_TYPESCRIPT
,
122 /* keep in sync with icon names in symbols.c */
134 TM_N_ICONS
= TM_ICON_NONE
137 void tm_parser_verify_type_mappings(void);
139 TMTagType
tm_parser_get_tag_type(gchar kind
, TMParserType lang
);
141 gchar
tm_parser_get_tag_kind(TMTagType type
, TMParserType lang
);
143 gint
tm_parser_get_sidebar_group(TMParserType lang
, TMTagType type
);
145 const gchar
*tm_parser_get_sidebar_info(TMParserType lang
, gint group
, guint
*icon
);
147 TMTagType
tm_parser_get_subparser_type(TMParserType lang
, TMParserType sublang
, TMTagType type
);
149 gint
tm_parser_scope_autocomplete_suffix(TMParserType lang
, const gchar
*str
);
151 const gchar
*tm_parser_get_constructor_method(TMParserType lang
);
153 gboolean
tm_parser_is_anon_name(TMParserType lang
, gchar
*name
);
155 gchar
*tm_parser_update_scope(TMParserType lang
, gchar
*scope
);
157 gboolean
tm_parser_enable_role(TMParserType lang
, gchar kind
);
159 gboolean
tm_parser_enable_kind(TMParserType lang
, gchar kind
);
161 gchar
*tm_parser_format_variable(TMParserType lang
, const gchar
*name
, const gchar
*type
);
163 gchar
*tm_parser_format_function(TMParserType lang
, const gchar
*fname
, const gchar
*args
,
164 const gchar
*retval
, const gchar
*scope
);
166 const gchar
*tm_parser_scope_separator(TMParserType lang
);
168 const gchar
*tm_parser_scope_separator_printable(TMParserType lang
);
170 gboolean
tm_parser_has_full_scope(TMParserType lang
);
172 gboolean
tm_parser_langs_compatible(TMParserType lang
, TMParserType other
);
174 #endif /* GEANY_PRIVATE */
178 #endif /* TM_PARSER_H */