Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Datetime improvements #2267

merged 4 commits into from Jan 26, 2018
Diff settings


Just for now


Small fixes for bokeh table formatting

  • Loading branch information...
Philipp Rudiger Philipp Rudiger
Philipp Rudiger authored and Philipp Rudiger committed Jan 23, 2018
commit 23b50de0f702cdfe60e489a41bd5ab7a7c5eff68
@@ -2,7 +2,7 @@

from bokeh.models.widgets import (
DataTable, TableColumn, NumberEditor, NumberFormatter, DateFormatter,
TimeEditor, StringFormatter, IntEditor
TimeEditor, StringFormatter, StringEditor, IntEditor

from ...core import Dataset, Dimension
@@ -79,12 +79,12 @@ def initialize_plot(self, ranges=None, plot=None, plots=None, source=None):
formatter = NumberFormatter()
editor = IntEditor()
elif kind == 'f':
formatter = NumberFormatter(format='0,0[.]000000')
formatter = NumberFormatter(format='0,0.0[00000]')
editor = NumberEditor()
elif kind == 'M' or (kind == 'O' and type(data[col][0]) in datetime_types):
dimtype = element.get_dimension_type(0)
Dimension.type_formatters.get(dimtype, '%Y-%m-%d %H:%M:%S')
formatter = DateFormatter()
dformat = Dimension.type_formatters.get(dimtype, '%Y-%m-%d %H:%M:%S')
formatter = DateFormatter(format=dformat)
editor = TimeEditor()
formatter = StringFormatter()
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.