Beispiel #1
0
class StyleGrid(DataGrid):
    """A styled grid

    ``[0.1.6]/datagrid.ts#L64``
    """

    # pylint: disable=no-member

    _model_name = T.Unicode("StyleGridModel").tag(sync=True)
    _view_name = T.Unicode("StyleGridView").tag(sync=True)

    row_size = T.Int().tag(sync=True)
    column_size = T.Int().tag(sync=True)
    row_header_size = T.Int().tag(sync=True)
    column_header_size = T.Int().tag(sync=True)

    header_visibility = T.Enum(
        ["all", "row", "column", "none"], default_value="all"
    ).tag(sync=True)

    grid_style = W.trait_types.InstanceDict(GridStyle).tag(
        sync=True, **W.widget_serialization
    )

    cell_renderers = T.List(T.Instance(CellRenderer)).tag(
        sync=True, **W.widget_serialization
    )
Beispiel #2
0
class FixedFunc(FormatFunc):
    """``[0.1.6]/textrenderer.ts#L365``"""

    _model_name = T.Unicode("FixedFuncModel").tag(sync=True)

    digits = T.Int().tag(sync=True)
    missing = T.Unicode().tag(sync=True)
Beispiel #3
0
class StyleGrid(DataGrid):
    """ A styled grid
        [0.1.6]/datagrid.ts#L64
    """

    _model_name = T.Unicode("StyleGridModel").tag(sync=True)
    _view_name = T.Unicode("StyleGridView").tag(sync=True)

    row_size = T.Int().tag(sync=True)
    column_size = T.Int().tag(sync=True)
    row_header_size = T.Int().tag(sync=True)
    column_header_size = T.Int().tag(sync=True)

    void_color = AlphaColor("#F3F3F3").tag(sync=True)
    background_color = AlphaColor("#FFFFFF").tag(sync=True)
    grid_line_color = AlphaColor("rgba(20, 20, 20, 0.15)").tag(sync=True)
    header_background_color = AlphaColor("#F3F3F3").tag(sync=True)
    header_grid_line_color = AlphaColor("rgba(20, 20, 20, 0.25)").tag(sync=True)

    cell_renderers = T.List(T.Instance(CellRenderer)).tag(
        sync=True, **W.widget_serialization
    )