Box select does not appear to work with VBar

Hi,

Apologies for accidentally posting this as a reply to previous post initially.

I am trying to use box select with the VBar glyph but the interaction appears to be broken.

Using bokeh serve with the following code illustrates the problem.

from bokeh.models import ColumnDataSource
from bokeh.plotting import curdoc, figure
import logging
logger = logging.getLogger(‘test’)
def on_selection_change(attr, new, old):
logger.info(‘selection change’)

source = ColumnDataSource(data=dict(bins=[0, 1, 2], counts=[1, 10, 20]))
doc = curdoc()

p = figure(tools=“box_select,tap”)

source.on_change(‘selected’, on_selection_change)

b = p.vbar(x = ‘bins’, bottom=0, width=1, top=‘counts’ , source=source)

c = p.circle(x=‘bins’, y=‘counts’, source=source)

doc.add_root§

Using vbar tap tool fires the selection change but box select does not.

Using circle both tools fire the selection change.

I assume this is a bug. I’ll file a problem report.

Geoff.

Agreed. That’s a bug. There must be a p roblem with the hit testing
code.

Thanks for the report.

Sarah Bird

···

On 10/5/16 6:14 AM, baldrik wrote:

Hi,

      Apologies for accidentally posting this as a reply to

previous post initially.

      I am trying to use box select with the VBar glyph but the

interaction appears to be broken.

      Using bokeh serve with the following code illustrates the

problem.

from bokeh.models
import ColumnDataSource
from bokeh.plotting
import curdoc, figure

        **import** logging
        logger = logging.getLogger('test')


        **def** **on_selection_change**(attr, new, old):
            logger.info(              'selection

change’)

        source = ColumnDataSource(data=dict(bins=[0, 1, 2], counts=[1, 10, 20]))
        doc = curdoc()

        p = figure(tools="box_select,tap")

        source.on_change('selected', on_selection_change)

        b = p.vbar(x = 'bins', bottom=0, width=1, top='counts' , source=source)
                      # c = p.circle(x='bins',

y=‘counts’, source=source)

        doc.add_root(p)
      Using vbar tap tool fires the selection change but box select

does not.

Using circle both tools fire the selection change.

I assume this is a bug. I’ll file a problem report.

Geoff.

  You received this message because you are subscribed to the Google

Groups “Bokeh Discussion - Public” group.

  To unsubscribe from this group and stop receiving emails from it,

send an email to [email protected].

  To post to this group, send email to [email protected]

  To view this discussion on the web visit [https://groups.google.com/a/continuum.io/d/msgid/bokeh/fbc7129f-2c33-4b4e-9eb9-bdadf008907f%40continuum.io](https://groups.google.com/a/continuum.io/d/msgid/bokeh/fbc7129f-2c33-4b4e-9eb9-bdadf008907f%40continuum.io?utm_medium=email&utm_source=footer).

  For more options, visit [https://groups.google.com/a/continuum.io/d/optout](https://groups.google.com/a/continuum.io/d/optout).


Sarah Bird
Developer, Bokeh

    [
      ![Continuum Analytics](http://docs.continuum.io/_static/img/ContinuumWordmark.png)
    ](http://continuum.io)

It's not implemented, only point hit testing is implemented.

Bryan

···

On Oct 5, 2016, at 12:28 PM, Sarah Bird - Continuum <[email protected]> wrote:

Agreed. That's a bug. There must be a problem with the hit testing code.

Thanks for the report.

Sarah Bird

On 10/5/16 6:14 AM, baldrik wrote:

Hi,

Apologies for accidentally posting this as a reply to previous post initially.

I am trying to use box select with the VBar glyph but the interaction appears to be broken.
Using bokeh serve with the following code illustrates the problem.

from bokeh.models import ColumnDataSource
from bokeh.plotting import curdoc, figure

import logging
logger = logging.getLogger('test')

def on_selection_change(attr, new, old):
    logger.info('selection change')

source = ColumnDataSource(data=dict(bins=[0, 1, 2], counts=[1, 10, 20]))
doc = curdoc()

p = figure(tools="box_select,tap")

source.on_change('selected', on_selection_change)

b = p.vbar(x = 'bins', bottom=0, width=1, top='counts' , source=source)
# c = p.circle(x='bins', y='counts', source=source)

doc.add_root(p)

Using vbar tap tool fires the selection change but box select does not.
Using circle both tools fire the selection change.

I assume this is a bug. I'll file a problem report.

Geoff.

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/fbc7129f-2c33-4b4e-9eb9-bdadf008907f%40continuum.io.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.

--
Sarah Bird
Developer, Bokeh

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/e5c7f90e-9e5c-569e-bbc2-fc2ba0a6c1a1%40continuum.io.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.