Qucs-S S-parameter Viewer & RF Synthesis Tools
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Protected Attributes | List of all members
pip._vendor.rich.table.Table Class Reference
Inheritance diagram for pip._vendor.rich.table.Table:
Inheritance graph
[legend]
Collaboration diagram for pip._vendor.rich.table.Table:
Collaboration graph
[legend]

Public Member Functions

None __init__ (self, *Union[Column, str] headers, Optional[TextType] title=None, Optional[TextType] caption=None, Optional[int] width=None, Optional[int] min_width=None, Optional[box.Box] box=box.HEAVY_HEAD, Optional[bool] safe_box=None, PaddingDimensions padding=(0, 1), bool collapse_padding=False, bool pad_edge=True, bool expand=False, bool show_header=True, bool show_footer=False, bool show_edge=True, bool show_lines=False, int leading=0, StyleType style="none", Optional[Iterable[StyleType]] row_styles=None, Optional[StyleType] header_style="table.header", Optional[StyleType] footer_style="table.footer", Optional[StyleType] border_style=None, Optional[StyleType] title_style=None, Optional[StyleType] caption_style=None, "JustifyMethod" title_justify="center", "JustifyMethod" caption_justify="center", bool highlight=False)
 
"Table" grid (cls, *Union[Column, str] headers, PaddingDimensions padding=0, bool collapse_padding=True, bool pad_edge=False, bool expand=False)
 
bool expand (self)
 
None expand (self, bool expand)
 
int row_count (self)
 
StyleType get_row_style (self, "Console" console, int index)
 
Measurement __rich_measure__ (self, "Console" console, "ConsoleOptions" options)
 
Tuple[int, int, int, int] padding (self)
 
"Table" padding (self, PaddingDimensions padding)
 
None add_column (self, "RenderableType" header="", "RenderableType" footer="", *Optional[StyleType] header_style=None, Optional[StyleType] footer_style=None, Optional[StyleType] style=None, "JustifyMethod" justify="left", "VerticalAlignMethod" vertical="top", "OverflowMethod" overflow="ellipsis", Optional[int] width=None, Optional[int] min_width=None, Optional[int] max_width=None, Optional[int] ratio=None, bool no_wrap=False)
 
None add_row (self, *Optional["RenderableType"] renderables, Optional[StyleType] style=None, bool end_section=False)
 
None add_section (self)
 
"RenderResult" __rich_console__ (self, "Console" console, "ConsoleOptions" options)
 

Public Attributes

 title
 
 caption
 
 width
 
 min_width
 
 box
 
 safe_box
 
 pad_edge
 
 show_header
 
 show_footer
 
 show_edge
 
 show_lines
 
 leading
 
 collapse_padding
 
 style
 
 header_style
 
 footer_style
 
 border_style
 
 title_style
 
 caption_style
 
 highlight
 
 rows
 
 expand
 
 columns
 

Static Public Attributes

List columns [Column]
 
List rows [Row]
 

Protected Member Functions

int _extra_width (self)
 
List[int] _calculate_column_widths (self, "Console" console, "ConsoleOptions" options)
 
List[int] _collapse_widths (cls, List[int] widths, List[bool] wrapable, int max_width)
 
Iterable[_Cell_get_cells (self, "Console" console, int column_index, Column column)
 
int _get_padding_width (self, int column_index)
 
Measurement _measure_column (self, "Console" console, "ConsoleOptions" options, Column column)
 
"RenderResult" _render (self, "Console" console, "ConsoleOptions" options, List[int] widths)
 
- Protected Member Functions inherited from pip._vendor.rich.jupyter.JupyterMixin
Dict[str, str] _repr_mimebundle_ ("ConsoleRenderable" self, Sequence[str] include, Sequence[str] exclude, **Any kwargs)
 

Protected Attributes

 _padding
 
 _expand
 

Detailed Description

A console renderable to draw a table.

Args:
    *headers (Union[Column, str]): Column headers, either as a string, or :class:`~rich.table.Column` instance.
    title (Union[str, Text], optional): The title of the table rendered at the top. Defaults to None.
    caption (Union[str, Text], optional): The table caption rendered below. Defaults to None.
    width (int, optional): The width in characters of the table, or ``None`` to automatically fit. Defaults to None.
    min_width (Optional[int], optional): The minimum width of the table, or ``None`` for no minimum. Defaults to None.
    box (box.Box, optional): One of the constants in box.py used to draw the edges (see :ref:`appendix_box`), or ``None`` for no box lines. Defaults to box.HEAVY_HEAD.
    safe_box (Optional[bool], optional): Disable box characters that don't display on windows legacy terminal with *raster* fonts. Defaults to True.
    padding (PaddingDimensions, optional): Padding for cells (top, right, bottom, left). Defaults to (0, 1).
    collapse_padding (bool, optional): Enable collapsing of padding around cells. Defaults to False.
    pad_edge (bool, optional): Enable padding of edge cells. Defaults to True.
    expand (bool, optional): Expand the table to fit the available space if ``True``, otherwise the table width will be auto-calculated. Defaults to False.
    show_header (bool, optional): Show a header row. Defaults to True.
    show_footer (bool, optional): Show a footer row. Defaults to False.
    show_edge (bool, optional): Draw a box around the outside of the table. Defaults to True.
    show_lines (bool, optional): Draw lines between every row. Defaults to False.
    leading (bool, optional): Number of blank lines between rows (precludes ``show_lines``). Defaults to 0.
    style (Union[str, Style], optional): Default style for the table. Defaults to "none".
    row_styles (List[Union, str], optional): Optional list of row styles, if more than one style is given then the styles will alternate. Defaults to None.
    header_style (Union[str, Style], optional): Style of the header. Defaults to "table.header".
    footer_style (Union[str, Style], optional): Style of the footer. Defaults to "table.footer".
    border_style (Union[str, Style], optional): Style of the border. Defaults to None.
    title_style (Union[str, Style], optional): Style of the title. Defaults to None.
    caption_style (Union[str, Style], optional): Style of the caption. Defaults to None.
    title_justify (str, optional): Justify method for title. Defaults to "center".
    caption_justify (str, optional): Justify method for caption. Defaults to "center".
    highlight (bool, optional): Highlight cell contents (if str). Defaults to False.

Member Function Documentation

◆ _calculate_column_widths()

List[int] pip._vendor.rich.table.Table._calculate_column_widths (   self,
"Console"  console,
"ConsoleOptions"   options 
)
protected
Calculate the widths of each column, including padding, not including borders.

◆ _collapse_widths()

List[int] pip._vendor.rich.table.Table._collapse_widths (   cls,
List[int]  widths,
List[bool]  wrapable,
int   max_width 
)
protected
Reduce widths so that the total is under max_width.

Args:
    widths (List[int]): List of widths.
    wrapable (List[bool]): List of booleans that indicate if a column may shrink.
    max_width (int): Maximum width to reduce to.

Returns:
    List[int]: A new list of widths.

◆ _extra_width()

int pip._vendor.rich.table.Table._extra_width (   self)
protected
Get extra width to add to cell content.

◆ _get_cells()

Iterable[_Cell] pip._vendor.rich.table.Table._get_cells (   self,
"Console"  console,
int  column_index,
Column   column 
)
protected
Get all the cells with padding and optional header.

◆ _get_padding_width()

int pip._vendor.rich.table.Table._get_padding_width (   self,
int  column_index 
)
protected
Get extra width from padding.

◆ _measure_column()

Measurement pip._vendor.rich.table.Table._measure_column (   self,
"Console"  console,
"ConsoleOptions"  options,
Column  column 
)
protected
Get the minimum and maximum width of the column.

◆ add_column()

None pip._vendor.rich.table.Table.add_column (   self,
"RenderableType"   header = "",
"RenderableType"   footer = "",
*Optional[StyleType]   header_style = None,
Optional[StyleType]   footer_style = None,
Optional[StyleType]   style = None,
"JustifyMethod"   justify = "left",
"VerticalAlignMethod"   vertical = "top",
"OverflowMethod"   overflow = "ellipsis",
Optional[int]   width = None,
Optional[int]   min_width = None,
Optional[int]   max_width = None,
Optional[int]   ratio = None,
bool   no_wrap = False 
)
Add a column to the table.

Args:
    header (RenderableType, optional): Text or renderable for the header.
        Defaults to "".
    footer (RenderableType, optional): Text or renderable for the footer.
        Defaults to "".
    header_style (Union[str, Style], optional): Style for the header, or None for default. Defaults to None.
    footer_style (Union[str, Style], optional): Style for the footer, or None for default. Defaults to None.
    style (Union[str, Style], optional): Style for the column cells, or None for default. Defaults to None.
    justify (JustifyMethod, optional): Alignment for cells. Defaults to "left".
    vertical (VerticalAlignMethod, optional): Vertical alignment, one of "top", "middle", or "bottom". Defaults to "top".
    overflow (OverflowMethod): Overflow method: "crop", "fold", "ellipsis". Defaults to "ellipsis".
    width (int, optional): Desired width of column in characters, or None to fit to contents. Defaults to None.
    min_width (Optional[int], optional): Minimum width of column, or ``None`` for no minimum. Defaults to None.
    max_width (Optional[int], optional): Maximum width of column, or ``None`` for no maximum. Defaults to None.
    ratio (int, optional): Flexible ratio for the column (requires ``Table.expand`` or ``Table.width``). Defaults to None.
    no_wrap (bool, optional): Set to ``True`` to disable wrapping of this column.

◆ add_row()

None pip._vendor.rich.table.Table.add_row (   self,
*Optional["RenderableType"]  renderables,
Optional[StyleType]   style = None,
bool   end_section = False 
)
Add a row of renderables.

Args:
    *renderables (None or renderable): Each cell in a row must be a renderable object (including str),
        or ``None`` for a blank cell.
    style (StyleType, optional): An optional style to apply to the entire row. Defaults to None.
    end_section (bool, optional): End a section and draw a line. Defaults to False.

Raises:
    errors.NotRenderableError: If you add something that can't be rendered.

◆ add_section()

None pip._vendor.rich.table.Table.add_section (   self)
Add a new section (draw a line after current row).

◆ expand() [1/2]

bool pip._vendor.rich.table.Table.expand (   self)
Setting a non-None self.width implies expand.

◆ expand() [2/2]

None pip._vendor.rich.table.Table.expand (   self,
bool  expand 
)
Set expand.

◆ get_row_style()

StyleType pip._vendor.rich.table.Table.get_row_style (   self,
"Console"  console,
int  index 
)
Get the current row style.

◆ grid()

"Table" pip._vendor.rich.table.Table.grid (   cls,
*Union[Column, str]  headers,
PaddingDimensions   padding = 0,
bool   collapse_padding = True,
bool   pad_edge = False,
bool   expand = False 
)
Get a table with no lines, headers, or footer.

Args:
    *headers (Union[Column, str]): Column headers, either as a string, or :class:`~rich.table.Column` instance.
    padding (PaddingDimensions, optional): Get padding around cells. Defaults to 0.
    collapse_padding (bool, optional): Enable collapsing of padding around cells. Defaults to True.
    pad_edge (bool, optional): Enable padding around edges of table. Defaults to False.
    expand (bool, optional): Expand the table to fit the available space if ``True``, otherwise the table width will be auto-calculated. Defaults to False.

Returns:
    Table: A table instance.

◆ padding() [1/2]

Tuple[int, int, int, int] pip._vendor.rich.table.Table.padding (   self)
Get cell padding.

◆ padding() [2/2]

"Table" pip._vendor.rich.table.Table.padding (   self,
PaddingDimensions  padding 
)
Set cell padding.

◆ row_count()

int pip._vendor.rich.table.Table.row_count (   self)
Get the current number of rows.

The documentation for this class was generated from the following file: