fplot 1.7.1
A Fortran library providing a convenient interface for plotting with Gnuplot.
Loading...
Searching...
No Matches
fplot_plot_data_colored.f90
1! fplot_plot_data_colored.f90
2
3submodule(fplot_core) fplot_plot_data_colored
4contains
5! ------------------------------------------------------------------------------
6 pure module function pdc_get_line_color(this) result(x)
7 class(plot_data_colored), intent(in) :: this
8 type(color) :: x
9 if (this%m_useAutoColor) then
10 x = color_list(this%get_color_index())
11 else
12 x = this%m_color
13 end if
14 end function
15
16! --------------------
17 module subroutine pdc_set_line_color(this, x)
18 class(plot_data_colored), intent(inout) :: this
19 type(color), intent(in) :: x
20 this%m_color = x
21 this%m_useAutoColor = .false.
22 end subroutine
23
24! ------------------------------------------------------------------------------
25 pure module function pdc_get_color_index(this) result(x)
26 class(plot_data_colored), intent(in) :: this
27 integer(int32) :: x
28 x = this%m_colorIndex
29 end function
30
31! --------------------
32 module subroutine pdc_set_color_index(this, x)
33 class(plot_data_colored), intent(inout) :: this
34 integer(int32), intent(in) :: x
35 this%m_colorIndex = x
36 end subroutine
37
38! ------------------------------------------------------------------------------
39end submodule
fplot_core