Dillo v3.1.1-119-g140d9ebd
|
Table parsing functions. More...
#include "table.hh"
#include "html_common.hh"
#include "dw/style.hh"
#include "dw/textblock.hh"
#include "dw/table.hh"
#include "dw/simpletablecell.hh"
#include "prefs.h"
#include "msg.h"
#include "css.hh"
Go to the source code of this file.
Functions | |
static void | Html_tag_open_table_cell (DilloHtml *html, const char *tag, int tagsize, dw::core::style::TextAlignType text_align) |
static void | Html_tag_content_table_cell (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_open_table (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_content_table (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_open_tr (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_content_tr (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_open_td (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_content_td (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_open_tbody (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_content_tbody (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_open_tfoot (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_open_thead (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_open_th (DilloHtml *html, const char *tag, int tagsize) |
void | Html_tag_content_th (DilloHtml *html, const char *tag, int tagsize) |
static int | Html_table_get_border_model (DilloHtml *html) |
The table border model is stored in the table's stack item. | |
static void | Html_table_set_border_model (DilloHtml *html, DilloHtmlTableBorderMode mode) |
Set current table's border model. | |
static void | Html_set_collapsing_border_model (DilloHtml *html, Widget *col_tb) |
static void | Html_set_separate_border_model (DilloHtml *html, Widget *col_tb) |
Adjust style for separate border model. | |
Table parsing functions.
Definition in file table.cc.
Definition at line 330 of file table.cc.
References dw::core::style::StyleAttrs::borderColor, dw::core::style::StyleAttrs::borderStyle, dw::core::style::StyleAttrs::borderWidth, dw::core::style::Box::bottom, dw::core::style::Style::create(), DILLO_HTML_TABLE_BORDER_COLLAPSE, dw::core::style::StyleAttrs::hBorderSpacing, Html_table_get_border_model(), Html_table_set_border_model(), dw::core::style::Box::left, dw::core::style::StyleAttrs::margin, dw::core::style::StyleAttrs::padding, dw::core::style::Box::right, S_TOP, dw::core::Widget::setStyle(), dw::core::style::Box::setVal(), DilloHtml::style(), dw::core::style::Box::top, and dw::core::style::StyleAttrs::vBorderSpacing.
Referenced by Html_tag_content_table_cell().
Adjust style for separate border model.
(Dw uses this model internally).
Definition at line 374 of file table.cc.
References dw::core::style::Style::create(), dw::core::style::StyleAttrs::margin, dw::core::Widget::setStyle(), dw::core::style::Box::setVal(), and DilloHtml::style().
Referenced by Html_tag_content_table_cell().
|
static |
The table border model is stored in the table's stack item.
Definition at line 299 of file table.cc.
References a_Html_tag_index(), lout::misc::SimpleVector< T >::getRef(), lout::misc::SimpleVector< T >::size(), DilloHtml::stack, DilloHtmlState::table_border_mode, and DilloHtmlState::tag_idx.
Referenced by Html_set_collapsing_border_model().
|
static |
Set current table's border model.
Definition at line 314 of file table.cc.
References a_Html_tag_index(), lout::misc::SimpleVector< T >::getRef(), lout::misc::SimpleVector< T >::size(), DilloHtml::stack, DilloHtmlState::table_border_mode, and DilloHtmlState::tag_idx.
Referenced by Html_set_collapsing_border_model().
void Html_tag_content_table | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 161 of file table.cc.
References DILLO_HTML_TABLE_BORDER_SEPARATE, DILLO_HTML_TABLE_MODE_TOP, FALSE, HT2TB, DilloPrefs::limit_text_width, prefs, S_TOP, DilloHtml::style(), and DilloHtml::wordStyle().
|
static |
Definition at line 449 of file table.cc.
References a_Html_get_attr(), dw::core::style::BORDER_MODEL_COLLAPSE, dw::core::style::StyleAttrs::borderCollapse, BUG_MSG, D_ASCII_TOLOWER, DILLO_HTML_TABLE_MODE_NONE, DILLO_HTML_TABLE_MODE_TD, DILLO_HTML_TABLE_MODE_TOP, DILLO_HTML_TABLE_MODE_TR, DilloHtml::dw, Html_set_collapsing_border_model(), Html_set_separate_border_model(), DilloPrefs::limit_text_width, MAX, prefs, S_TOP, DilloHtml::style(), dw::core::style::TEXT_ALIGN_STRING, and dw::core::style::StyleAttrs::textAlign.
Referenced by Html_tag_content_td(), and Html_tag_content_th().
void Html_tag_content_tbody | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
void Html_tag_content_td | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 248 of file table.cc.
References Html_tag_content_table_cell().
void Html_tag_content_th | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 287 of file table.cc.
References Html_tag_content_table_cell().
void Html_tag_content_tr | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 223 of file table.cc.
References DILLO_HTML_TABLE_MODE_NONE, DILLO_HTML_TABLE_MODE_TD, DILLO_HTML_TABLE_MODE_TOP, DILLO_HTML_TABLE_MODE_TR, S_TOP, and DilloHtml::style().
void Html_tag_open_table | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 47 of file table.cc.
References a_Html_color_parse(), a_Html_get_attr(), a_Html_parse_length(), dw::core::style::BORDER_INSET, dw::core::style::BORDER_OUTSET, BUG_MSG, StyleEngine::clearNonCssHints(), CSS_CREATE_LENGTH(), CSS_LENGTH_TYPE_PX, CSS_PROPERTY_BACKGROUND_COLOR, CSS_PROPERTY_BORDER_BOTTOM_STYLE, CSS_PROPERTY_BORDER_BOTTOM_WIDTH, CSS_PROPERTY_BORDER_LEFT_STYLE, CSS_PROPERTY_BORDER_LEFT_WIDTH, CSS_PROPERTY_BORDER_RIGHT_STYLE, CSS_PROPERTY_BORDER_RIGHT_WIDTH, CSS_PROPERTY_BORDER_SPACING, CSS_PROPERTY_BORDER_TOP_STYLE, CSS_PROPERTY_BORDER_TOP_WIDTH, CSS_PROPERTY_PADDING_BOTTOM, CSS_PROPERTY_PADDING_LEFT, CSS_PROPERTY_PADDING_RIGHT, CSS_PROPERTY_PADDING_TOP, CSS_PROPERTY_TEXT_ALIGN, CSS_PROPERTY_WIDTH, CSS_TYPE_COLOR, CSS_TYPE_ENUM, CSS_TYPE_LENGTH_PERCENTAGE, DilloHtml::DocType, DilloHtml::DocTypeVersion, dStrAsciiCasecmp(), DT_HTML, StyleEngine::setNonCssHint(), DilloHtml::style(), DilloHtml::styleEngine, dw::core::style::TEXT_ALIGN_CENTER, dw::core::style::TEXT_ALIGN_LEFT, and dw::core::style::TEXT_ALIGN_RIGHT.
|
static |
Definition at line 389 of file table.cc.
References a_Html_color_parse(), a_Html_get_attr(), a_Html_parse_length(), a_Html_tag_set_align_attr(), a_Html_tag_set_valign_attr(), BUG_MSG, CSS_PROPERTY_BACKGROUND_COLOR, CSS_PROPERTY_TEXT_ALIGN, CSS_PROPERTY_WHITE_SPACE, CSS_PROPERTY_WIDTH, CSS_TYPE_COLOR, CSS_TYPE_ENUM, CSS_TYPE_LENGTH_PERCENTAGE, D_ASCII_TOLOWER, DILLO_HTML_TABLE_MODE_NONE, DILLO_HTML_TABLE_MODE_TD, DILLO_HTML_TABLE_MODE_TOP, DILLO_HTML_TABLE_MODE_TR, DilloHtml::DocType, DilloHtml::DocTypeVersion, DT_HTML, StyleEngine::inheritNonCssHints(), S_TOP, StyleEngine::setNonCssHint(), DilloHtml::styleEngine, and dw::core::style::WHITE_SPACE_NOWRAP.
Referenced by Html_tag_open_td(), and Html_tag_open_th().
void Html_tag_open_tbody | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
void Html_tag_open_td | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 242 of file table.cc.
References Html_tag_open_table_cell(), and dw::core::style::TEXT_ALIGN_LEFT.
void Html_tag_open_tfoot | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
void Html_tag_open_th | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 281 of file table.cc.
References Html_tag_open_table_cell(), and dw::core::style::TEXT_ALIGN_CENTER.
void Html_tag_open_thead | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
void Html_tag_open_tr | ( | DilloHtml * | html, |
const char * | tag, | ||
int | tagsize | ||
) |
Definition at line 180 of file table.cc.
References _MSG, a_Html_color_parse(), a_Html_get_attr(), a_Html_tag_set_align_attr(), a_Html_tag_set_valign_attr(), BUG_MSG, CSS_PROPERTY_BACKGROUND_COLOR, CSS_TYPE_COLOR, DILLO_HTML_TABLE_MODE_NONE, DILLO_HTML_TABLE_MODE_TD, DILLO_HTML_TABLE_MODE_TOP, DILLO_HTML_TABLE_MODE_TR, DilloHtml::DocType, DilloHtml::DocTypeVersion, DT_HTML, StyleEngine::inheritBackgroundColor(), StyleEngine::inheritNonCssHints(), S_TOP, StyleEngine::setNonCssHint(), DilloHtml::styleEngine, and TRUE.