⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 parse.h

📁 一个很有名的浏览器
💻 H
字号:
/* $Id: parse.h,v 1.9 2004/07/13 16:54:37 zas Exp $ */#ifndef EL__DOCUMENT_HTML_PARSER_PARSE_H#define EL__DOCUMENT_HTML_PARSER_PARSE_Hstruct part;struct string;/* Flags for get_attr_value(). */enum html_attr_flags {	HTML_ATTR_NONE = 0,	/* If HTML_ATTR_TEST is set then we only test for existence of	 * an attribute of that @name. In that mode it returns NULL if	 * attribute was not found, and a pointer to start of the attribute	 * if it was found. */	HTML_ATTR_TEST = 1,	/* If HTML_ATTR_EAT_NL is not set, newline and tabs chars are	 * replaced by spaces in returned value, else these chars are	 * skipped. */	HTML_ATTR_EAT_NL = 2,	/* If HTML_ATTR_NO_CONV is set, then convert_string() is not called	 * on value. Unused for now. */	/* HTML_ATTR_NO_CONV = 4, */};/* Parses html element attributes. * - e is attr pointer previously get from parse_element, * DON'T PASS HERE ANY OTHER VALUE!!! * - name is searched attribute * * Returns allocated string containing the attribute, or NULL on unsuccess. */unsigned char *get_attr_value(register unsigned char *e, unsigned char *name, enum html_attr_flags flags);/* Wrappers for get_attr_value(). */#define get_attr_val(e, name) get_attr_value(e, name, HTML_ATTR_NONE)#define get_url_val(e, name) get_attr_value(e, name, HTML_ATTR_EAT_NL)#define has_attr(e, name) (!!get_attr_value(e, name, HTML_ATTR_TEST))/* Interface for both the renderer and the table handling */void parse_html(unsigned char *html, unsigned char *eof, struct part *part, unsigned char *head);/* Interface for the table handling */int parse_element(unsigned char *, unsigned char *, unsigned char **, int *, unsigned char **, unsigned char **);int get_num(unsigned char *, unsigned char *);int get_width(unsigned char *, unsigned char *, int);unsigned char *skip_comment(unsigned char *, unsigned char *);void scan_http_equiv(unsigned char *s, unsigned char *eof, struct string *head, struct string *title);/* Lifecycle functions for the tags fastfind cache, if being in use. */void free_tags_lookup(void);void init_tags_lookup(void);#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -