You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One use case I have run into several times now is the need to customize cell and boundary region colormaps for the gridplot call.
Since I didn't see any way to make this happen so far, I would propose adding new default keyword arguments and alter the gridplot routines so they don't use the hard-coded colormap from GridVisualizeTools.jl.
I also altered the 2d gridplot example in the docs to showcase this capability to the user.
Are you sure that this works for all backends ? GridVisualizeTools.bregion_cmap returns a Vector{Colortypey.RGB}. I think backends should be able to assume that this is the case. See GridVisualizeTools.rgbcolor for the way Symbols are transformed to RGB. OTOH we could pass the vector through GridVisualizeTools.rgbcolor in those backends which need this, as we do e.g. with linecolor ... indeed, I think this would be better....
May be passing a vector of colors instead of a function would be the more intutive API. We could have an internal wrapper function like this:
function bregioncmap(ctxcmap, ncolors)
if ctxcmap==nothing
return bregion_cmap(ncolors)
else
return GridvisualizeTools.rgbcolor.(ctxcmap)
end
end
Any news on this? I would love it as a functionality, see #134 because plotting the grid and some sensor locations becomes way too overloaded with the region color.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
One use case I have run into several times now is the need to customize cell and boundary region colormaps for the
gridplotcall.Since I didn't see any way to make this happen so far, I would propose adding new default keyword arguments and alter the
gridplotroutines so they don't use the hard-coded colormap fromGridVisualizeTools.jl.I also altered the 2d
gridplotexample in the docs to showcase this capability to the user.