mirror of
https://github.com/rkd77/elinks.git
synced 2024-12-04 14:46:47 -05:00
[tables] some static functions now are in global scope
This commit is contained in:
parent
74b84d688f
commit
94a5288336
@ -49,7 +49,7 @@ get_table_frames(struct table *table, struct table_frames *result)
|
||||
}
|
||||
|
||||
/* Distance of the table from the left margin. */
|
||||
static int
|
||||
int
|
||||
get_table_indent(struct html_context *html_context, struct table *table)
|
||||
{
|
||||
int width = par_elformat.width - table->real_width;
|
||||
@ -533,7 +533,7 @@ free_widths:
|
||||
}
|
||||
|
||||
|
||||
static int
|
||||
int
|
||||
get_table_cellpadding(struct html_context *html_context, struct table *table)
|
||||
{
|
||||
struct part *part = table->part;
|
||||
@ -575,7 +575,7 @@ again:
|
||||
|
||||
|
||||
#ifdef HTML_TABLE_2ND_PASS /* This is by default ON! (<setup.h>) */
|
||||
static void
|
||||
void
|
||||
check_table_widths(struct html_context *html_context, struct table *table)
|
||||
{
|
||||
int col, row;
|
||||
@ -757,7 +757,7 @@ get_table_real_height(struct table *table)
|
||||
return height;
|
||||
}
|
||||
|
||||
static void
|
||||
void
|
||||
get_table_heights(struct html_context *html_context, struct table *table)
|
||||
{
|
||||
int rowspan;
|
||||
@ -829,7 +829,7 @@ get_table_heights(struct html_context *html_context, struct table *table)
|
||||
table->real_height = get_table_real_height(table);
|
||||
}
|
||||
|
||||
static void
|
||||
void
|
||||
draw_table_cell(struct table *table, int col, int row, int x, int y,
|
||||
struct html_context *html_context)
|
||||
{
|
||||
@ -902,7 +902,7 @@ draw_table_cell(struct table *table, int col, int row, int x, int y,
|
||||
mem_free_if(part);
|
||||
}
|
||||
|
||||
static void
|
||||
void
|
||||
draw_table_cells(struct table *table, int x, int y,
|
||||
struct html_context *html_context)
|
||||
{
|
||||
@ -1123,7 +1123,7 @@ init_table_rules(struct table *table, signed char *frame[2])
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
void
|
||||
draw_table_frames(struct table *table, int indent, int y,
|
||||
struct html_context *html_context)
|
||||
{
|
||||
@ -1202,7 +1202,7 @@ draw_table_frames(struct table *table, int indent, int y,
|
||||
fmem_free(frame[0]);
|
||||
}
|
||||
|
||||
static void
|
||||
void
|
||||
draw_table_caption(struct html_context *html_context, struct table *table,
|
||||
int x, int y)
|
||||
{
|
||||
@ -1264,7 +1264,7 @@ draw_table_bad_html(struct html_context *html_context, struct table *table)
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
void
|
||||
distribute_table_widths(struct table *table)
|
||||
{
|
||||
int width = table->width;
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
#ifndef EL__DOCUMENT_HTML_TABLES_H
|
||||
#define EL__DOCUMENT_HTML_TABLES_H
|
||||
|
||||
@ -7,8 +6,21 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
struct html_context;
|
||||
struct table;
|
||||
|
||||
void distribute_table_widths(struct table *table);
|
||||
void draw_table_caption(struct html_context *html_context, struct table *table, int x, int y);
|
||||
void draw_table_cell(struct table *table, int col, int row, int x, int y, struct html_context *html_context);
|
||||
void draw_table_cells(struct table *table, int x, int y, struct html_context *html_context);
|
||||
void draw_table_frames(struct table *table, int indent, int y, struct html_context *html_context);
|
||||
void format_table(char *, char *, char *, char **, struct html_context *);
|
||||
int get_table_cellpadding(struct html_context *html_context, struct table *table);
|
||||
void get_table_heights(struct html_context *html_context, struct table *table);
|
||||
int get_table_indent(struct html_context *html_context, struct table *table);
|
||||
|
||||
#ifdef HTML_TABLE_2ND_PASS /* This is by default ON! (<setup.h>) */
|
||||
void check_table_widths(struct html_context *html_context, struct table *table);
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
@ -22,6 +22,7 @@
|
||||
#include "document/html/frames.h"
|
||||
#include "document/html/parser/link.h"
|
||||
#include "document/html/parser/stack.h"
|
||||
#include "document/html/parser/table.h"
|
||||
#include "document/html/parser.h"
|
||||
#include "document/html/renderer.h"
|
||||
#include "document/html/tables.h"
|
||||
@ -48,6 +49,20 @@
|
||||
|
||||
#include <libxml++/libxml++.h>
|
||||
|
||||
static struct table *
|
||||
tags_parse_table(struct source_renderer *renderer, int t, void *no)
|
||||
{
|
||||
struct html_context *html_context = renderer->html_context;
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void
|
||||
tags_draw_table_bad_html(struct source_renderer *renderer, struct table *table)
|
||||
{
|
||||
struct html_context *html_context = renderer->html_context;
|
||||
}
|
||||
|
||||
void
|
||||
tags_format_table(struct source_renderer *renderer, void *no)
|
||||
{
|
||||
@ -60,7 +75,7 @@ tags_format_table(struct source_renderer *renderer, void *no)
|
||||
|
||||
html_context->table_level++;
|
||||
|
||||
table = tags_parse_table(no, (part->document || part->box.x), html_context);
|
||||
table = tags_parse_table(renderer, (part->document || part->box.x), no);
|
||||
if (!table) goto ret0;
|
||||
|
||||
table->part = part;
|
||||
@ -69,7 +84,7 @@ tags_format_table(struct source_renderer *renderer, void *no)
|
||||
* parser state. Something to do with link numbering. */
|
||||
/* It needs to be done _before_ processing the actual table, too.
|
||||
* Otherwise i.e. <form> tags between <table> and <tr> are broken. */
|
||||
tags_draw_table_bad_html(html_context, table);
|
||||
tags_draw_table_bad_html(renderer, table);
|
||||
|
||||
state = init_html_parser_state(html_context, ELEMENT_DONT_KILL,
|
||||
ALIGN_LEFT, 0, 0);
|
||||
|
Loading…
Reference in New Issue
Block a user