working prototype
This commit is contained in:
parent
0ba32ade50
commit
412fc43c61
12
src/args.jl
12
src/args.jl
@ -383,6 +383,7 @@ const _subplot_defaults = KW(
|
||||
:legendtitle => nothing,
|
||||
:colorbar => :legend,
|
||||
:clims => :auto,
|
||||
:colorbar_fontfamily => :match,
|
||||
:colorbar_ticks => :auto,
|
||||
:colorbar_tickfontfamily => :match,
|
||||
:colorbar_tickfontsize => 8,
|
||||
@ -418,7 +419,6 @@ const _subplot_defaults = KW(
|
||||
:colorbar_title => "",
|
||||
:colorbar_titlefontsize => 10,
|
||||
:colorbar_title_location => :center, # also :left or :right
|
||||
:colorbar_fontfamily => :match,
|
||||
:colorbar_titlefontfamily => :match,
|
||||
:colorbar_titlefonthalign => :hcenter,
|
||||
:colorbar_titlefontvalign => :vcenter,
|
||||
@ -1340,10 +1340,10 @@ const _match_map = KW(
|
||||
:background_color_inside => :background_color_subplot,
|
||||
:foreground_color_legend => :foreground_color_subplot,
|
||||
:foreground_color_title => :foreground_color_subplot,
|
||||
:left_margin => :margin,
|
||||
:top_margin => :margin,
|
||||
:right_margin => :margin,
|
||||
:bottom_margin => :margin,
|
||||
:left_margin => :margin,
|
||||
:top_margin => :margin,
|
||||
:right_margin => :margin,
|
||||
:bottom_margin => :margin,
|
||||
:titlefontfamily => :fontfamily_subplot,
|
||||
:titlefontcolor => :foreground_color_subplot,
|
||||
:legendfontfamily => :fontfamily_subplot,
|
||||
@ -1353,6 +1353,8 @@ const _match_map = KW(
|
||||
:colorbar_fontfamily => :fontfamily_subplot,
|
||||
:colorbar_titlefontfamily => :fontfamily_subplot,
|
||||
:colorbar_titlefontcolor => :foreground_color_subplot,
|
||||
:colorbar_tickfontfamily => :fontfamily_subplot,
|
||||
:colorbar_tickfontcolor => :foreground_color_subplot,
|
||||
:plot_titlefontfamily => :fontfamily,
|
||||
:plot_titlefontcolor => :foreground_color,
|
||||
:tickfontcolor => :foreground_color_text,
|
||||
|
||||
@ -978,7 +978,7 @@ function _before_layout_calcs(plt::Plot{PyPlotBackend})
|
||||
|
||||
end
|
||||
|
||||
cb."set_label"(sp[:colorbar_title],size=py_thickness_scale(plt, sp[:yaxis][:guidefontsize]),family=sp[:yaxis][:guidefontfamily], color = py_color(sp[:yaxis][:guidefontcolor]))
|
||||
cb."set_label"(sp[:colorbar_title],size=py_thickness_scale(plt, sp[:colorbar_titlefontsize]),family=sp[:colorbar_titlefontfamily], color = py_color(sp[:colorbar_titlefontcolor]))
|
||||
|
||||
# cb."formatter".set_useOffset(false) # This for some reason does not work, must be a pyplot bug, instead this is a workaround:
|
||||
cb."formatter".set_powerlimits((-Inf, Inf))
|
||||
@ -1000,9 +1000,9 @@ function _before_layout_calcs(plt::Plot{PyPlotBackend})
|
||||
sp[:colorbar_ticks] == :native ? nothing : py_set_ticks(cb.ax, ticks, ticks_letter, env)
|
||||
|
||||
for lab in cbar_axis."get_ticklabels"()
|
||||
lab."set_fontsize"(py_thickness_scale(plt, axis[:colorbar_tickfontsize]))
|
||||
lab."set_family"(axis[:colorbar_tickfontfamily])
|
||||
lab."set_color"(py_color(axis[:colorbar_tickfontcolor]))
|
||||
lab."set_fontsize"(py_thickness_scale(plt, sp[:colorbar_tickfontsize]))
|
||||
lab."set_family"(sp[:colorbar_tickfontfamily])
|
||||
lab."set_color"(py_color(sp[:colorbar_tickfontcolor]))
|
||||
end
|
||||
|
||||
# Adjust thickness of the cbar ticks
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user