forcolormap_info Module

The Colormaps_info class offers information about each colormap.


Uses

  • module~~forcolormap_info~~UsesGraph module~forcolormap_info forcolormap_info module~colormap_parameters colormap_parameters module~forcolormap_info->module~colormap_parameters iso_fortran_env iso_fortran_env module~colormap_parameters->iso_fortran_env

Used by

  • module~~forcolormap_info~~UsedByGraph module~forcolormap_info forcolormap_info proc~check Colormap%check proc~check->module~forcolormap_info program~colormaps_list colormaps_list program~colormaps_list->module~forcolormap_info program~write_info write_info program~write_info->module~forcolormap_info

Derived Types

type, public ::  Colormaps_info

Define a derived type named 'Colormaps_info' to store an array of 'table' type

Components

Type Visibility Attributes Name Initial
type(table), private :: colormaps(232)

Array of 'table' type to store multiple colormaps

Type-Bound Procedures

procedure, public :: finalize => deallocate_Colormaps_info ../../

Procedure to finalize the derived type

procedure, public :: get_levels ../../

Procedure to get the number of levels in a colormap

procedure, public :: get_name ../../

Procedure to get the name of a colormap

procedure, public :: get_ncolormaps ../../

Procedure to get the number of colormaps

procedure, public :: set_all ../../

Procedure to set information for all colormaps in the array

procedure, public :: write ../../

Procedure to filter and write information about the colormaps

type, private ::  table

Define a derived type named 'table' to store information about a colormap

Components

Type Visibility Attributes Name Initial
character(len=:), private, allocatable :: author

Author of the colormap

character(len=:), private, allocatable :: colorbar

Colorbar style associated with the colormap

character(len=:), private, allocatable :: family

Family or category of the colormap

character(len=:), private, allocatable :: gradient

Type of gradient used in the colormap

integer, private :: levels

Number of discrete levels in the colormap

character(len=:), private, allocatable :: license

License information for the colormap

character(len=:), private, allocatable :: name

Name of the colormap

character(len=:), private, allocatable :: package

Package or library associated with the colormap

character(len=:), private, allocatable :: palette

Palette used in the colormap

character(len=:), private, allocatable :: url

URL or web link to the colormap information

Type-Bound Procedures

procedure, public :: finalize => deallocate_table ../../

Procedure to finalize the derived type

procedure, public :: set_info ../../

Procedure to set information for the colormap

procedure, public :: write_info ../../

Procedure to print information about the colormap


Functions

private pure function findColumnIntersections(array) result(intersections)

Finds intersections between elements of the first column and other columns in the input array.

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: array(:,:)

Return Value integer, allocatable, (:)

private pure function get_levels(this, index) result(levels)

Arguments

Type IntentOptional Attributes Name
class(Colormaps_info), intent(in) :: this
integer, intent(in) :: index

Return Value integer

private pure elemental function get_name(this, index) result(name)

Arguments

Type IntentOptional Attributes Name
class(Colormaps_info), intent(in) :: this
integer, intent(in) :: index

Return Value character(len=colormap_name_length)

private pure elemental function get_ncolormaps(this) result(ncolormaps)

Arguments

Type IntentOptional Attributes Name
class(Colormaps_info), intent(in) :: this

Return Value integer


Subroutines

private pure elemental subroutine deallocate_Colormaps_info(this)

Arguments

Type IntentOptional Attributes Name
class(Colormaps_info), intent(inout) :: this

private pure elemental subroutine deallocate_table(this)

Arguments

Type IntentOptional Attributes Name
class(table), intent(inout) :: this

private pure elemental subroutine set_all(this)

Set information for all colormaps.

Arguments

Type IntentOptional Attributes Name
class(Colormaps_info), intent(inout) :: this

private pure elemental subroutine set_info(this, package, family, name, gradient, palette, author, license, url, colorbar, levels)

Set information about the colormap

Arguments

Type IntentOptional Attributes Name
class(table), intent(inout) :: this
character(len=*), intent(in) :: package
character(len=*), intent(in) :: family
character(len=*), intent(in) :: name
character(len=*), intent(in) :: gradient
character(len=*), intent(in) :: palette
character(len=*), intent(in) :: author
character(len=*), intent(in) :: license
character(len=*), intent(in) :: url
character(len=*), intent(in) :: colorbar
integer, intent(in) :: levels

private impure subroutine write(this, verbose, name, family, gradient, palette, author, license, levels, file_name)

Filter the array of colormaps based on the given criteria and write information about the filtered colormaps

Arguments

Type IntentOptional Attributes Name
class(Colormaps_info), intent(inout) :: this
integer, intent(in), optional :: verbose
character(len=*), intent(in), optional :: name
character(len=*), intent(in), optional :: family
character(len=*), intent(in), optional :: gradient
character(len=*), intent(in), optional :: palette
character(len=*), intent(in), optional :: author
character(len=*), intent(in), optional :: license
integer, intent(in), optional :: levels
character(len=*), intent(in), optional :: file_name

private impure subroutine write_info(this, verbose, file_name)

Print information about the colormap

Arguments

Type IntentOptional Attributes Name
class(table), intent(inout) :: this
integer, intent(in), optional :: verbose
character(len=*), intent(in), optional :: file_name