On Jan 6, 2017, at 2:22 PM, Siddhant Patel <sidpatel1991@gmail.com> wrote:
Thanks for the reply Bryan. Running that code gives me this error-
AttributeError: unexpected attribute 'css_classes' to Div, possible attributes are disabled, height, name, render_as_text, sizing_mode, tags, text or width
Is there a new method to assign css classes?
Thanks, Sid
On Saturday, January 7, 2017 at 12:44:05 AM UTC+5:30, Bryan Van de ven wrote:
Hi,
You will probably want to use file_html directly, instead of show:
http://bokeh.pydata.org/en/latest/docs/reference/embed.html#bokeh.embed.file_html
Here is an example that uses it:
https://github.com/bokeh/bokeh/blob/master/examples/plotting/file/css_classes.py
Thanks,
Bryan
> On Jan 6, 2017, at 11:24 AM, Siddhant Patel <sidpat...@gmail.com> wrote:
>
> How can I change the style tags in the html files for plots?
>
> For example this plot:
> from bokeh.plotting import figure, output_file, show
>
>
>
> output_file("line.html")
>
>
>
> p = figure(plot_width=400, plot_height=400)
>
>
>
> # add a line renderer
> p.line([1, 2, 3, 4, 5], [6, 7, 2, 4, 5], line_width=2)
>
>
>
> show(p)
>
> Has this style tag:-
> <style>
> html {
> width: 100%;
> height: 100%;
> }
> body {
> width: 90%;
> height: 100%;
> margin: auto;
> }
> </style>
>
> So how can I change the margin from auto to 0 or anything else?
>
> Thanks.
>
> --
> 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 bokeh+un...@continuum.io.
> To post to this group, send email to bo...@continuum.io.
> To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/504d06ba-8309-4c8a-85c9-6a5049c9099b%40continuum.io\.
> For more options, visit https://groups.google.com/a/continuum.io/d/optout\.
--
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 bokeh+unsubscribe@continuum.io.
To post to this group, send email to bokeh@continuum.io.
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/f0e3d498-7968-416d-b876-b908e40fd399%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.