Skip to content
This repository has been archived by the owner on Nov 29, 2019. It is now read-only.

Replace show_labels with a label formatter #10

Open
ceball opened this issue Oct 21, 2017 · 11 comments
Open

Replace show_labels with a label formatter #10

ceball opened this issue Oct 21, 2017 · 11 comments
Assignees

Comments

@ceball
Copy link
Member

ceball commented Oct 21, 2017

Currently not doing anything?
screen shot 2017-10-21 at 10 10 18 am

Default to capitalizing, and replacing underscore with space.

@ceball
Copy link
Member Author

ceball commented May 24, 2018

@jlstevens, I assume this issue can be closed now thanks to your recent work?

@jlstevens
Copy link
Member

Formatting labels was addressed in #48 but the code above regarding the show_labels parameter was left unchanged. I'll rename this issue to reflect what I think is still a problem...

@jlstevens
Copy link
Member

jlstevens commented May 24, 2018

Ah the title is 'replace show_labels with a label formatter'. I'm not sure why you would want to do that. Even more fundamentally, why would you ever want to disable the labels entirely? How would you know what parameter each widget affects?

In other words, what was show_labels supposed to do? It doesn't make sense to me as a concept and I'm happy to make a PR to remove this parameter entirely (or issue a warning for backwards compatibility).

@ceball
Copy link
Member Author

ceball commented May 24, 2018

I don't know what show_labels was supposed to do as I didn't add it, but it appeared to me that it did nothing; this issue was about removing show_labels and adding a label formatter. So I think we're agreeing.

@jbednar
Copy link
Member

jbednar commented May 24, 2018

I think this issue can be closed with no further changes. If someone instantiates Widgets with only one Parameter or with only widgets that need no name (e.g. dates or action buttons), they may or may not want space reserved for any form of label at all. So I think show_labels is useful completely independently of label formatting.

@jbednar
Copy link
Member

jbednar commented May 24, 2018

Oh, except that show_labels appears to be a no-op above? That code does look bogus, and I think show_labels=False should be entirely disabling all labels not inside the widget itself, in which case this issue still remains open.

@jlstevens
Copy link
Member

I think show_labels=False should be entirely disabling all labels not inside the widget itself

Right though why would this be useful?

@jbednar
Copy link
Member

jbednar commented May 25, 2018

As said above; if you just have one widget controlling a plot, you might want to put whatever label you like in the page template, not be forced to use ParamBokeh's labelling.

@jlstevens
Copy link
Member

I see what you mean now but it still strikes me as a sufficiently rare enough use case that I'm not convinced it warrants a separate parameter.

You could just set a label formatter that returns an empty string which seems to have been the original intent of this issue. Have we ever needed to use this parameter ourselves? Probably not as it doesn't work!

@ceball
Copy link
Member Author

ceball commented May 25, 2018

I'm sure I've used no labels before (not with parambokeh, though - probably paramtk). Whether to have a separate parameter for it, or to do it via the label formatter (as I meant with this issue originally), or to do it with some other parameter we might also want like a label position parameter (probably not), I'm not sure. My opinion seems to vary depending what other system I've been using most recently. And I haven't been able to look at the label formatter yet.

@jlstevens
Copy link
Member

Given the parameter already exists, I might as well make a PR to get it working even if I don't see much value in it (at least not yet!).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants