Blender V5.0
blender::ed::spreadsheet::DataSource Class Reference

#include <spreadsheet_data_source.hh>

Inherited by blender::ed::spreadsheet::BundleDataSource, blender::ed::spreadsheet::ClosureSignatureDataSource, blender::ed::spreadsheet::GeometryDataSource, blender::ed::spreadsheet::ListDataSource, blender::ed::spreadsheet::SingleValueDataSource, and blender::ed::spreadsheet::VolumeDataSource.

Public Member Functions

virtual ~DataSource ()
virtual void foreach_default_column_ids (FunctionRef< void(const SpreadsheetColumnID &, bool is_extra)>) const
virtual std::unique_ptr< ColumnValuesget_column_values (const SpreadsheetColumnID &) const
virtual bool has_selection_filter () const
virtual int tot_rows () const

Detailed Description

This class is subclassed to implement different data sources for the spreadsheet. A data source provides the information that should be displayed. It is not concerned with how data is laid out in the spreadsheet editor exactly.

Definition at line 18 of file spreadsheet_data_source.hh.

Constructor & Destructor Documentation

◆ ~DataSource()

blender::ed::spreadsheet::DataSource::~DataSource ( )
virtualdefault

Member Function Documentation

◆ foreach_default_column_ids()

virtual void blender::ed::spreadsheet::DataSource::foreach_default_column_ids ( FunctionRef< void(const SpreadsheetColumnID &, bool is_extra)> ) const
inlinevirtual

Calls the callback with all the column ids that should be displayed as long as the user does not manually add or remove columns. The column id can be stack allocated. Therefore, the callback should not keep a reference to it (and copy it instead).

The is_extra argument indicates that this column is special and should be drawn as the first column. (This can be made a bit more generic in the future when necessary.)

Reimplemented in blender::ed::spreadsheet::BundleDataSource, blender::ed::spreadsheet::ClosureSignatureDataSource, blender::ed::spreadsheet::GeometryDataSource, blender::ed::spreadsheet::ListDataSource, blender::ed::spreadsheet::SingleValueDataSource, and blender::ed::spreadsheet::VolumeDataSource.

Definition at line 30 of file spreadsheet_data_source.hh.

Referenced by blender::ed::spreadsheet::update_visible_columns().

◆ get_column_values()

virtual std::unique_ptr< ColumnValues > blender::ed::spreadsheet::DataSource::get_column_values ( const SpreadsheetColumnID & ) const
inlinevirtual

◆ has_selection_filter()

virtual bool blender::ed::spreadsheet::DataSource::has_selection_filter ( ) const
inlinevirtual

Returns true if the data source has the ability to limit visible rows by user interface selection status.

Reimplemented in blender::ed::spreadsheet::GeometryDataSource.

Definition at line 49 of file spreadsheet_data_source.hh.

Referenced by blender::ed::spreadsheet::use_selection_filter().

◆ tot_rows()


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