resolve_color_string_or_rgb Subroutine

public subroutine resolve_color_string_or_rgb(color_str, color_rgb, context, rgb_out, has_color)

Merge string/RGB color inputs into a single RGB triple.

Precedence: - RGB triple wins if supplied (explicit numeric value from the user). - Otherwise the string is parsed via fortplot_colors::parse_color. - If parsing fails, emit a single warning tagged with context and report has_color = .false. so the caller can fall back.

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in), optional :: color_str
real(kind=wp), intent(in), optional :: color_rgb(3)
character(len=*), intent(in) :: context
real(kind=wp), intent(out) :: rgb_out(3)
logical, intent(out) :: has_color