Class: Wx::GRID::GridSizesInfo

Inherits:
Object
  • Object
show all
Defined in:
lib/wx/doc/gen/grid/grid_ctrl.rb

Overview

Note:

This class is untracked and should not be derived from nor instances extended!

GridSizesInfo stores information about sizes of all Grid rows or columns.

It assumes that most of the rows or columns (which are both called elements here as the difference between them doesn’t matter at this class level) have the default size and so stores it separately. And it uses a HashMap to store the sizes of all elements which have the non-default size. This structure is particularly useful for serializing the sizes of all Grid elements at once.

Category: Grid Related Classes

Requires:

  • USE_GRID

Instance Method Summary collapse

Constructor Details

#initializeWx::GRID::GridSizesInfo #initialize(defSize, allSizes) ⇒ Wx::GRID::GridSizesInfo

Returns a new instance of GridSizesInfo.

Overloads:

  • #initializeWx::GRID::GridSizesInfo

    Default constructor.

    m_sizeDefault and m_customSizes must be initialized later.

  • #initialize(defSize, allSizes) ⇒ Wx::GRID::GridSizesInfo

    Constructor.

    This constructor is used by Wx::GRID::Grid#get_row_sizes and GetColSizes() methods. User code will usually use the default constructor instead.

    Parameters:

    • defSize (Integer)

      The default element size.

    • allSizes (Array<Integer>)

      Array containing the sizes of all elements, including those which have the default size.



2780
# File 'lib/wx/doc/gen/grid/grid_ctrl.rb', line 2780

def initialize(*args) end

Instance Method Details

#custom_sizesHash

Map with element indices as keys and their sizes as values. This map only contains the elements with non-default size.

Returns:

  • (Hash)


2760
# File 'lib/wx/doc/gen/grid/grid_ctrl.rb', line 2760

def custom_sizes; end

#custom_sizes=(val) ⇒ void

This method returns an undefined value.

Map with element indices as keys and their sizes as values. This map only contains the elements with non-default size.

Parameters:

  • val (Hash)


2766
# File 'lib/wx/doc/gen/grid/grid_ctrl.rb', line 2766

def custom_sizes=(val); end

#get_size(pos) ⇒ Integer Also known as: size

Get the element size.

The size for this element, using m_customSizes if pos is in it or m_sizeDefault otherwise.

Parameters:

  • pos (unsigned)

    The index of the element.

Returns:

  • (Integer)


2787
# File 'lib/wx/doc/gen/grid/grid_ctrl.rb', line 2787

def get_size(pos) end

#size_defaultInteger

Default size.

Returns:

  • (Integer)


2748
# File 'lib/wx/doc/gen/grid/grid_ctrl.rb', line 2748

def size_default; end

#size_default=(val) ⇒ void

This method returns an undefined value.

Default size.

Parameters:

  • val (Integer)


2754
# File 'lib/wx/doc/gen/grid/grid_ctrl.rb', line 2754

def size_default=(val); end