How to set row height of DataTable?

Hi,

I am running Bokeh server and embedded the server doc in the html. I can’t seem to find a way to set row height (currently it defaults to 20px in slick grid) in the bokeh app when creating the DataTable. I tried to set through external css (see below) in the html, but only the cell height is updated, but not row height.
.bk-root .slick-row {
line-height: 40px !important;

}

Any help appreciated!

Jack

Hi Jack,

I know this is an old thread, but I recently did a PR to allow for overriding the default row height. Add support for setting the DataTable row height by dennisobrien · Pull Request #8412 · bokeh/bokeh · GitHub

This should make it in to the next release.

cheers,

Dennis

···

On Thursday, April 19, 2018 at 3:31:00 AM UTC+3, Jack Guo wrote:

Hi,

I am running Bokeh server and embedded the server doc in the html. I can’t seem to find a way to set row height (currently it defaults to 20px in slick grid) in the bokeh app when creating the DataTable. I tried to set through external css (see below) in the html, but only the cell height is updated, but not row height.
.bk-root .slick-row {
line-height: 40px !important;

}

Any help appreciated!

Jack

Thanks!

···

Jack

You could try to use a custom styles like in this example: https://groups.google.com/a/continuum.io/forum/#!topic/bokeh/VG94SmNMWj0
Possibly setting “height” or “min-height” attribute for the .bk-root .bk-slick-cell or .bk-root .bk-slick-row styles could work…?

···

On Thursday, April 19, 2018 at 2:31:00 AM UTC+2, Jack Guo wrote:

Hi,

I am running Bokeh server and embedded the server doc in the html. I can’t seem to find a way to set row height (currently it defaults to 20px in slick grid) in the bokeh app when creating the DataTable. I tried to set through external css (see below) in the html, but only the cell height is updated, but not row height.
.bk-root .slick-row {
line-height: 40px !important;

}

Any help appreciated!

Jack

I don’t think that works for DataTable. You can override the height of each row with CSS, but it doesn’t change the offset of each row, so the rows overlap. It looked like the offset of each row is computed using the row height which defaults to 25. I looked into this a bit, ran into too many dead ends, then figured it would be easier and cleaner to support overriding the row height from the Python code when creating the DataTable. If you find a working way to do this with CSS I’d be interested.

cheers,

Dennis

···

On Mon, Nov 19, 2018 at 2:41 PM [email protected] wrote:

You could try to use a custom styles like in this example: https://groups.google.com/a/continuum.io/forum/#!topic/bokeh/VG94SmNMWj0
Possibly setting “height” or “min-height” attribute for the .bk-root .bk-slick-cell or .bk-root .bk-slick-row styles could work…?

On Thursday, April 19, 2018 at 2:31:00 AM UTC+2, Jack Guo wrote:

Hi,

I am running Bokeh server and embedded the server doc in the html. I can’t seem to find a way to set row height (currently it defaults to 20px in slick grid) in the bokeh app when creating the DataTable. I tried to set through external css (see below) in the html, but only the cell height is updated, but not row height.
.bk-root .slick-row {
line-height: 40px !important;

}

Any help appreciated!

Jack

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/0fc3c6c0-c52a-4bcf-b1ea-fa1e4bc31a78%40continuum.io.

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