@@ -693,7 +693,12 @@ Example:
693693 fill_between([theta y1], [theta y2], white=true, legend="Sinc1,Sinc2", show=1)
694694"""
695695fill_between (fname:: String ; first:: Bool = true , kw... ) = fill_between (gmtread (fname); first= first, kw... )
696- function fill_between (arg1, arg2= nothing ; first= true , kwargs... )
696+ fill_between! (arg1, arg2= nothing ; kw... ) = fill_between (arg1, arg2; first= false , kw... )
697+ function fill_between (arg1, arg2= nothing ; first= true , kw... )
698+ d = init_module (false , kw... )[1 ]
699+ fill_between (arg1, arg2, first, d)
700+ end
701+ function fill_between (arg1, arg2, first:: Bool , d:: Dict{Symbol, Any} )
697702
698703 function find_the_pos (x, x_int)
699704 len_x = length (x)
@@ -714,7 +719,6 @@ function fill_between(arg1, arg2=nothing; first=true, kwargs...)
714719 return legs
715720 end
716721
717- d = init_module (false , kwargs... )[1 ] # Also checks if the user wants ONLY the HELP mode
718722 fc = helper_ds_fill (d) # Got fill colors?
719723 if (! isempty (fc))
720724 ! any (contains .(fc, " @" )) && (fc .*= " @60" ) # If no transparency provided default to 60%
@@ -863,8 +867,6 @@ function fill_between(arg1, arg2=nothing; first=true, kwargs...)
863867 =#
864868end
865869
866- fill_between! (arg1, arg2= nothing ; kw... ) = fill_between (arg1, arg2; first= false , kw... )
867-
868870# ------------------------------------------------------------------------------------------------------
869871"""
870872 stairs(cmd0::String="", arg1=nothing; step=:post, kwargs...)
@@ -1532,9 +1534,12 @@ const vspan! = vband!
15321534const hspan = hband
15331535const hspan! = hband!
15341536
1535- function helper_hvband (mat:: Matrix{<:Real} , tipo= " v" ; width= false , height= false , percent= false , first= true , kwargs... )
1537+ function helper_hvband (mat:: Matrix{<:Real} , tipo= " v" ; width= false , height= false , percent= false , first= true , kw... )
1538+ d, _, O = init_module (first, kw... )
1539+ helper_hvband (mat, tipo, width, height, percent, O, d)
1540+ end
1541+ function helper_hvband (mat:: Matrix{<:Real} , tipo, width, height, percent, O:: Bool , d:: Dict{Symbol, Any} )
15361542 # This is the main function for the hband and vband functions.
1537- d, _, O = init_module (first, kwargs... )
15381543 cmd, = parse_R (d, " " , O= O, del= false )
15391544 all (CTRL. limits .== 0. ) && error (" Need to know the axes limits in a numeric form." )
15401545 cmd, = parse_J (d, cmd, default= " " , map= true , O= O, del= false )
@@ -1576,7 +1581,7 @@ function helper_hvband(mat::Matrix{<:Real}, tipo="v"; width=false, height=false,
15761581
15771582 d[:S ] = bB # Add -Sb|B, otherwise headers are not scanned.
15781583 got_pattern && (d[:G ] = " p1" ) # Patterns fck the session. Use this to inform gmt() that session must be recreated
1579- common_plot_xyz (" " , D, " " , first , false , d)
1584+ common_plot_xyz (" " , D, " " , ! O , false , d)
15801585end
15811586
15821587# ------------------------------------------------------------------------------------------------------
@@ -1668,11 +1673,17 @@ Other than the above options, the `kwargs` input accepts still the following opt
16681673- `clockwise`: - Set it to `true` to indicate that positive axes directions be clock-wise
16691674 [Default lets the a, b, c axes be positive in a counter-clockwise direction].
16701675"""
1671- function ternary (cmd0:: String = " " , arg1= nothing ; first:: Bool = true , image:: Bool = false , kwargs... )
1672- # A wrapper for psternary
1676+ ternary! (cmd0:: String = " " , arg1= nothing ; kw... ) = ternary (cmd0, arg1; first= false , kw... )
1677+ ternary (arg1; kw... ) = ternary (" " , arg1; first= true , kw... )
1678+ ternary! (arg1; kw... ) = ternary (" " , arg1; first= false , kw... )
1679+ function ternary (cmd0:: String = " " , arg1= nothing ; first:: Bool = true , image:: Bool = false , kw... )
16731680 (cmd0 == " " && arg1 === nothing ) && (arg1 = [0.0 0.0 0.0 ]) # No data in, just a kind of ternary basemap
16741681 (cmd0 != " " ) && (arg1 = gmtread (cmd0))
1675- d = init_module (first, kwargs... )[1 ]
1682+ d = init_module (first, kw... )[1 ]
1683+ ternary (arg1, first, image, d)
1684+ end
1685+ function ternary (arg1, first:: Bool , image:: Bool , d:: Dict{Symbol, Any} )
1686+ # A wrapper for psternary
16761687 opt_J:: String = parse_J (d, " " , default= " -JX" * split (DEF_FIG_SIZE, ' /' )[1 ] * " /0" , map= true , O= false , del= false )[2 ]
16771688 opt_R:: String = parse_R (d, " " )[1 ]
16781689 d[:R ] = (opt_R == " " ) ? " 0/100/0/100/0/100" : opt_R[4 : end ]
@@ -1768,10 +1779,6 @@ function dict_auto_add!(d::Dict)
17681779 end
17691780end
17701781
1771- ternary! (cmd0:: String = " " , arg1= nothing ; kw... ) = ternary (cmd0, arg1; first= false , kw... )
1772- ternary (arg1; kw... ) = ternary (" " , arg1; first= true , kw... )
1773- ternary! (arg1; kw... ) = ternary (" " , arg1; first= false , kw... )
1774- ternary (kw... ) = ternary (" " , nothing ; first= true , kw... )
17751782const psternary = ternary # Aliases
17761783const psternary! = ternary! # Aliases
17771784
0 commit comments