GCC Middle and Back End API Reference
|
#include <table.h>
Public Member Functions | |
table_cell_sizes (table_dimension_sizes &col_widths, table_dimension_sizes &row_heights) | |
void | pass_1 (const table &table) |
void | pass_2 (const table &table) |
canvas::size_t | get_canvas_size (const table::rect_t &rect) const |
Data Fields | |
table_dimension_sizes & | m_col_widths |
table_dimension_sizes & | m_row_heights |
A workspace for computing the row heights and column widths of a table (in canvas units). The col_widths and row_heights could be shared between multiple instances, for aligning multiple tables vertically or horizontally.
|
inline |
References m_col_widths, and m_row_heights.
canvas::size_t table_cell_sizes::get_canvas_size | ( | const table::rect_t & | rect | ) | const |
References text_art::rect< CoordinateSystem >::get_min_x(), text_art::rect< CoordinateSystem >::get_min_y(), text_art::rect< CoordinateSystem >::get_next_x(), text_art::rect< CoordinateSystem >::get_next_y(), text_art::size< CoordinateSystem >::h, m_col_widths, m_row_heights, text_art::rect< CoordinateSystem >::m_size, and text_art::size< CoordinateSystem >::w.
Referenced by pass_2().
void table_cell_sizes::pass_1 | ( | const table & | table | ) |
class table_cell_sizes.
Consider 1x1 cells.
References text_art::size< CoordinateSystem >::h, m_col_widths, text_art::table::m_placements, m_row_heights, text_art::size< CoordinateSystem >::w, text_art::coord< CoordinateSystem >::x, and text_art::coord< CoordinateSystem >::y.
Referenced by text_art::table::to_canvas().
void table_cell_sizes::pass_2 | ( | const table & | table | ) |
Consider cells that span more than one row or column.
References get_canvas_size(), text_art::size< CoordinateSystem >::h, m_col_widths, text_art::table::m_placements, m_row_heights, and text_art::size< CoordinateSystem >::w.
Referenced by text_art::table::to_canvas().
table_dimension_sizes& text_art::table_cell_sizes::m_col_widths |
Referenced by get_canvas_size(), pass_1(), pass_2(), and table_cell_sizes().
table_dimension_sizes& text_art::table_cell_sizes::m_row_heights |
Referenced by get_canvas_size(), pass_1(), pass_2(), and table_cell_sizes().