fix symbol cache
This commit is contained in:
parent
eb9766775c
commit
9a500d6be1
@ -564,9 +564,6 @@ function reset_axis_defaults_byletter!()
|
|||||||
end
|
end
|
||||||
reset_axis_defaults_byletter!()
|
reset_axis_defaults_byletter!()
|
||||||
|
|
||||||
const _all_defaults = KW[_series_defaults, _plot_defaults, _subplot_defaults]
|
|
||||||
|
|
||||||
|
|
||||||
is_subplot_attr(k) = k in _all_subplot_args
|
is_subplot_attr(k) = k in _all_subplot_args
|
||||||
is_series_attr(k) = k in _all_series_args
|
is_series_attr(k) = k in _all_series_args
|
||||||
is_axis_attr(k) = Symbol(chop(string(k); head = 1, tail = 0)) in _all_axis_args
|
is_axis_attr(k) = Symbol(chop(string(k); head = 1, tail = 0)) in _all_axis_args
|
||||||
@ -910,6 +907,7 @@ function parse_axis_kw(s::Symbol)
|
|||||||
return nothing
|
return nothing
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
# update the defaults globally
|
# update the defaults globally
|
||||||
|
|
||||||
"""
|
"""
|
||||||
|
|||||||
@ -49,3 +49,18 @@ for arg in _all_args
|
|||||||
end
|
end
|
||||||
# add all non_underscored forms to the _keyAliases
|
# add all non_underscored forms to the _keyAliases
|
||||||
add_non_underscore_aliases!(_keyAliases)
|
add_non_underscore_aliases!(_keyAliases)
|
||||||
|
|
||||||
|
# fill symbol cache
|
||||||
|
for letter in (:x, :y, :z)
|
||||||
|
_attrsymbolcache[letter] = Dict{Symbol, Symbol}()
|
||||||
|
for k in keys(_axis_defaults)
|
||||||
|
# populate attribute cache
|
||||||
|
lk = Symbol(letter, k)
|
||||||
|
_attrsymbolcache[letter][k] = lk
|
||||||
|
# allow the underscore version too: xguide or x_guide
|
||||||
|
add_aliases(lk, Symbol(letter, "_", k))
|
||||||
|
end
|
||||||
|
for k in (_magic_axis_args..., :(_discrete_indices))
|
||||||
|
_attrsymbolcache[letter][k] = Symbol(letter, k)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user