Lines Matching refs:tag

37 #include "tag.h"
54 * The tag code can be entered from main, e.g., "vi -t tag".
63 /* Build an argument for the ex :tag command. */
70 * to find the tag. We match historic practice, but don't distinguish
71 * between real error and failure to find the tag.
85 * :tag[!] [string]
117 msgq(sp, M_ERR, "158|No previous tag entered");
125 /* Get the tag information. */
157 msgq(sp, M_ERR, "282|Already at the last tag of this group");
167 (void)ctag_search(sp, tp->search, tp->slen, tqp->tag);
197 msgq(sp, M_ERR, "255|Already at the first tag of this group");
207 (void)ctag_search(sp, tp->search, tp->slen, tqp->tag);
329 case 0: /* Pop one tag. */
385 * Clear the tag stack.
449 * If only a single tag left, we've returned to the first tag point,
492 #define L_SPACE 5 /* Spaces after name, before tag. */
501 * is numbered, and the current tag entry has an asterisk appended.
521 if (tp == TAILQ_FIRST(tqp->tagq) && tqp->tag != NULL &&
523 len = strlen(tqp->tag);
528 (int)len, tqp->tag);
537 * Copy a screen's tag structures.
552 /* Copy tag queue and tags stack. */
567 /* Copy list of tag files. */
574 /* Copy the last tag. */
615 if (otqp->tag != NULL)
622 if (otqp->tag != NULL)
623 tqp->tag = tqp->buf;
729 /* Initialize the `local context' tag queue structure. */
733 /* Initialize and link in its tag structure. */
750 /* Try to switch to the preset tag. */
763 * If this is the first tag, put a `current location' queue entry
776 tqp->current->search, tqp->current->slen, tqp->tag);
820 tag_msg(SCR *sp, tagmsg_t msg, char *tag)
824 msgq_str(sp, M_ERR, tag,
825 "164|%s: the tag's line number is past the end of the file");
831 msgq_str(sp, M_ERR, tag, "166|%s: search pattern not found");
882 * Free the ex tag information.
893 /* Free up tag information. */
906 * Search a file for a tag.
909 ctag_search(SCR *sp, CHAR_T *search, size_t slen, char *tag)
926 tag_msg(sp, TAG_BADLNO, tag);
931 * Search for the tag; cheap fallback for C functions
945 notfound: tag_msg(sp, TAG_SEARCH, tag);
970 * Search the list of tags files for a tag, and return tag queue.
973 ctag_slist(SCR *sp, CHAR_T *tag)
985 /* Allocate and initialize the tag queue structure. */
986 INT2CHAR(sp, tag, STRLEN(tag) + 1, np, nlen);
990 tqp->tag = tqp->buf;
991 memcpy(tqp->tag, np, (tqp->tlen = len) + 1);
994 * Find the tag, only display missing file messages once, and
995 * then only if we didn't find the tag.
998 if (ctag_sfile(sp, tfp, tqp, tqp->tag)) {
1006 msgq_str(sp, M_ERR, tqp->tag, "162|%s: tag not found");
1027 * Search a tags file for a tag, adding any found to the tag queue.
1064 * Initialize and link in the tag structure(s). The historic ctags
1065 * file format only permitted a single tag location per tag. The
1066 * obvious extension to permit multiple tags locations per tag is to
1070 * per tag, and so will use a random tag entry if there si more than
1075 * <tag> <filename> <line number> | <pattern>
1113 msgq(sp, M_ERR, "163|%s: corrupted tag in %s", p, t);
1146 /* Try to preset the tag within the current file. */
1175 * If the tag file path is a relative path, see if it exists. If it
1176 * doesn't, look relative to the tags file path. It's okay for a tag
1178 * file. However, if the path exists relative to the tag file, it's