fplot 1.7.1
A Fortran library providing a convenient interface for plotting with Gnuplot.
Loading...
Searching...
No Matches
fplot_core::colormap Type Referenceabstract

A colormap object for a surface plot. More...

Inheritance diagram for fplot_core::colormap:
fplot_core::plot_object fplot_core::cool_colormap fplot_core::custom_colormap fplot_core::earth_colormap fplot_core::grey_colormap fplot_core::hot_colormap fplot_core::parula_colormap fplot_core::rainbow_colormap

Public Member Functions

procedure, public get_command_string cm_get_cmd
 Gets the GNUPLOT command string to represent this colormap object.
 
procedure(cm_get_string_result), deferred, public get_color_string cm_get_string_result
 Gets the GNUPLOT string defining the color distribution. For instance, this routine could return the string: '0 "dark-blue", 1 "blue", 2 "cyan", 3 "green", 4 "yellow", 5 "orange", 6 "red", 7 "dark-red"'. This string would result in a rainbow type map.
 
procedure, public get_label cm_get_label
 Gets the label to associate with the colorbar.
 
procedure, public set_label cm_set_label
 Sets the label to associate with the colorbar.
 
procedure, public get_horizontal cm_get_horizontal
 Gets a logical value determining if the colormap should be drawn horizontally and below the plot.
 
procedure, public set_horizontal cm_set_horizontal
 Sets a logical value determining if the colormap should be drawn horizontally and below the plot.
 
procedure, public get_draw_border cm_get_draw_border
 Gets a logical value determining if the border should be drawn.
 
procedure, public set_draw_border cm_set_draw_border
 Sets a logical value determining if the border should be drawn.
 
procedure, public get_show_tics cm_get_show_tics
 Gets a logical value determining if the tic marks should be drawn.
 
procedure, public set_show_tics cm_set_show_tics
 Sets a logical value determining if the tic marks should be drawn.
 

Public Attributes

logical m_horizontal = .false.
 The colormap should be drawn horizontally.
 
logical m_drawborder = .true.
 Draw the colormap border.
 
logical m_showtics = .true.
 Show the tic marks.
 

Private Attributes

character(len=:), allocatable m_label
 The label to associate with the colormap.
 

Detailed Description

A colormap object for a surface plot.

Definition at line 2377 of file fplot_core.f90.

Member Function/Subroutine Documentation

◆ get_color_string()

procedure(cm_get_string_result), deferred, public fplot_core::colormap::get_color_string
pure virtual

Gets the GNUPLOT string defining the color distribution. For instance, this routine could return the string: '0 "dark-blue", 1 "blue", 2 "cyan", 3 "green", 4 "yellow", 5 "orange", 6 "red", 7 "dark-red"'. This string would result in a rainbow type map.

Implemented in fplot_core::cool_colormap, fplot_core::custom_colormap, fplot_core::earth_colormap, fplot_core::grey_colormap, fplot_core::hot_colormap, fplot_core::parula_colormap, and fplot_core::rainbow_colormap.

Definition at line 2403 of file fplot_core.f90.

◆ get_command_string()

procedure, public fplot_core::colormap::get_command_string
virtual

Gets the GNUPLOT command string to represent this colormap object.

Syntax
character(len = :) function, allocatable :: get_command_string(class(colormap) this)
Parameters
[in]thisThe colormap object.
Returns
The command string.

Implements fplot_core::plot_object.

Definition at line 2398 of file fplot_core.f90.

◆ get_draw_border()

procedure, public fplot_core::colormap::get_draw_border

Gets a logical value determining if the border should be drawn.

Syntax
logical get_draw_border(class(colormap) this)
Parameters
[in]thisThe colormap object.
Returns
Returns true if the border should be drawn; else, false.

Definition at line 2458 of file fplot_core.f90.

◆ get_horizontal()

procedure, public fplot_core::colormap::get_horizontal

Gets a logical value determining if the colormap should be drawn horizontally and below the plot.

Syntax
logical get_horizontal(class(colormap) this)
Parameters
[in]thisThe colormap object.
Returns
Returns true if the colormap should be drawn horizontally; else, false.

Definition at line 2435 of file fplot_core.f90.

◆ get_label()

procedure, public fplot_core::colormap::get_label

Gets the label to associate with the colorbar.

Syntax
character(len = :) get_label(class(colormap) this)
Parameters
[in]thisThe colormap object.
Returns
The label.

Definition at line 2413 of file fplot_core.f90.

◆ get_show_tics()

procedure, public fplot_core::colormap::get_show_tics

Gets a logical value determining if the tic marks should be drawn.

Syntax
logical get_show_tics(class(colormap) this)
Parameters
[in]thisThe colormap object.
Returns
Returns true if the tic marks should be drawn; else, false.

Definition at line 2480 of file fplot_core.f90.

◆ set_draw_border()

procedure, public fplot_core::colormap::set_draw_border

Sets a logical value determining if the border should be drawn.

Syntax
subroutine set_draw_border(class(colormap) this, logical x)
Parameters
[in,out]thisThe colormap object.
[in]xSet to true if the border should be drawn; else, false.

Definition at line 2469 of file fplot_core.f90.

◆ set_horizontal()

procedure, public fplot_core::colormap::set_horizontal

Sets a logical value determining if the colormap should be drawn horizontally and below the plot.

Syntax
subroutine set_horizontal(class(colormap) this, logical x)
Parameters
[in,out]thisThe colormap object.
[in]xSet to true if the colormap should be drawn horizontally; else, false.

Definition at line 2447 of file fplot_core.f90.

◆ set_label()

procedure, public fplot_core::colormap::set_label

Sets the label to associate with the colorbar.

Syntax
subroutine set_label(class(colormap) this, character(len = *) x)
Parameters
[in,out]thisThe colormap object.
[in]xThe label.

Definition at line 2423 of file fplot_core.f90.

◆ set_show_tics()

procedure, public fplot_core::colormap::set_show_tics

Sets a logical value determining if the tic marks should be drawn.

Syntax
subroutine set_show_tics(class(colormap) this, logical x)
Parameters
[in,out]thisThe colormap object.
[in]xSet to true if the tic marks should be drawn; else, false.

Sets a logical value determining if the border should be drawn.

Syntax
subroutine set_draw_border(class(colormap) this, logical x)
Parameters
[in,out]thisThe colormap object.
[in]xSet to true if the border should be drawn; else, false.

Definition at line 2502 of file fplot_core.f90.

Member Data Documentation

◆ m_drawborder

logical fplot_core::colormap::m_drawborder = .true.

Draw the colormap border.

Definition at line 2384 of file fplot_core.f90.

◆ m_horizontal

logical fplot_core::colormap::m_horizontal = .false.

The colormap should be drawn horizontally.

Definition at line 2382 of file fplot_core.f90.

◆ m_label

character(len = :), allocatable fplot_core::colormap::m_label
private

The label to associate with the colormap.

Definition at line 2380 of file fplot_core.f90.

◆ m_showtics

logical fplot_core::colormap::m_showtics = .true.

Show the tic marks.

Definition at line 2386 of file fplot_core.f90.


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