示例#1
0
文件: htmllex.c 项目: Chaduke/bah.mod
static htmlimg_t *mkImg(char **atts)
{
    htmlimg_t *img = NEW(htmlimg_t);

    doAttrs(img, img_items, sizeof(img_items) / ISIZE, atts, "<IMG>");

    return img;
}
示例#2
0
文件: htmllex.c 项目: Chaduke/bah.mod
static htmlfont_t *mkFont(char **atts)
{
    htmlfont_t *font = NEW(htmlfont_t);

    font->size = -1.0;		/* unassigned */
    doAttrs(font, font_items, sizeof(font_items) / ISIZE, atts, "<FONT>");

    return font;
}
示例#3
0
文件: htmllex.c 项目: Chaduke/bah.mod
static htmltbl_t *mkTbl(char **atts)
{
    htmltbl_t *tbl = NEW(htmltbl_t);

    tbl->rc = -1;		/* flag that table is a raw, parsed table */
    tbl->cb = -1;		/* unset cell border attribute */
    doAttrs(tbl, tbl_items, sizeof(tbl_items) / ISIZE, atts, "<TABLE>");

    return tbl;
}
示例#4
0
文件: htmllex.c 项目: Chaduke/bah.mod
static htmlcell_t *mkCell(char **atts)
{
    htmlcell_t *cell = NEW(htmlcell_t);

    cell->cspan = 1;
    cell->rspan = 1;
    doAttrs(cell, cell_items, sizeof(cell_items) / ISIZE, atts, "<TD>");

    return cell;
}
示例#5
0
static textfont_t *mkFont(GVC_t *gvc, char **atts, int flags, int ul)
{
    textfont_t tf = {NULL,NULL,NULL,0.0,0,0};

    tf.size = -1.0;		/* unassigned */
    tf.flags = flags;
    if (atts)
	doAttrs(&tf, font_items, sizeof(font_items) / ISIZE, atts, "<FONT>");

    return dtinsert(gvc->textfont_dt, &tf);
}
示例#6
0
文件: htmllex.c 项目: Chaduke/bah.mod
static void mkBR(char **atts)
{
    htmllval.i = UNSET_ALIGN;
    doAttrs(&htmllval.i, br_items, sizeof(br_items) / ISIZE, atts, "<BR>");
}