Closed sdc50 closed 5 years ago
I don't know anything about paramnb
but to omit the name in parambokeh
you'd do something like this:
class Pobj(param.Parameterized):
x = param.Integer(default=2)
parambokeh.Widgets(Pobj(name=''))
Your approach Pobj.params()['name'].precedence = -1
appears to be affecting the base class, and not the instance. I'm no expert, but I guess paramnb and parambokeh handle that differently. I'm reminded of a conversation from a couple days ago https://github.com/ioam/parambokeh/issues/73
@kcpevey paramnb
actually lists the name twice. Once as the tile of the widget block (in the same way that parambokeh
does), but then it lists it again as one of the widgets. Setting the name of an instance to be blank, as you suggest, prevents the block title from showing up, but the parameter name
is still listed in the list of widgets.
I don't remember what we did in parambokeh to make the name not show up by default in the widgets list, but whatever we did we need to do that in paramnb as well.
This and several other recent @sdc50 tie back to what @ceball was mentioning in our last discussion, i.e. wondering whether to spend time now normalizing the underlying implementation or to focus on adding clearly needed features, and then clean up the code. We decided to focus on the visible features, but clearly the behind-the-scenes stuff is also causing issues...
Panel now removes the integer id from the name for display purposes and it can be disabled by setting show_name=False
in the Param pane constructor.
It would be convenient if parambokeh and paramnb handled the name parameter in the same way so that switching between the two libraries would produce the same results.
When a parameterized object is rendered with paramnb then the name parameter is displayed:
Whereas when then same object is rendered with parambokeh then the name object is omitted:
This causes an issue when I try to manually omit the name object for paramnb and then switch to using param bokeh.