Disable plotting in the iPython notebook.

        After disabling, lightning plots will be produced in your lightning server,
        but will not appear in the notebook.
325365
def disable_ipython(self):
        
        from IPython.core.getipython import get_ipython

        self.ipython_enabled = False
        ip = get_ipython()
        formatter = ip.display_formatter.formatters['text/html']
        formatter.type_printers.pop(Visualization, None)
        formatter.type_printers.pop(VisualizationLocal, None)
1112503
def do_disable():
    
    from vext import vext_pth

    try:
        _lines = []
        with open(vext_pth, mode='r') as f:
            for line in f.readlines():
                if not line.startswith('#') and line.startswith('import '):
                    _lines.append('# %s' % line)
                else:
                    _lines.append(line)

        try:
            os.unlink('%s.tmp' % vext_pth)
        except:
            pass

        with open('%s.tmp' % vext_pth, mode='w+') as f:
            f.writelines(_lines)

        try:
            os.unlink('%s~' % vext_pth)
        except:
            pass

        os.rename(vext_pth, '%s~' % vext_pth)
        os.rename('%s.tmp' % vext_pth, vext_pth)
    except IOError as e:
        if e.errno == 2:  # file didn't exist == disabled
            return
772358
def do_undisplay(self, arg):
        
        try:
            del self._get_display_list()[arg]
        except KeyError:
            print('** %s not in the display list **' % arg, file=self.stdout)
627832
def disableIndexing(self):
        '''
            
        '''
        self.indexIDs = self.indexNames = self.indexClassNames = self.indexTagNames = False
        self._resetIndexInternal()
1265783
def multiplot(terminal, options)
      terminal.set(options)
      @plots.each { |graph| graph.plot(terminal, multiplot_part: true) }
      terminal.unset(options.keys)
    end
1145501
def _render_table(data, fields=None):
  
  return IPython.core.display.HTML(datalab.utils.commands.HtmlBuilder.render_table(data, fields))
60303
def load_nb(cls, inline=True):
        
        from IPython.display import publish_display_data
        cls._loaded = True
        init_notebook_mode(connected=not inline)
        publish_display_data(data={MIME_TYPES['jlab-hv-load']:
                                   get_plotlyjs()})
126770
def hide(cls):
        
        cls.el.style.display = "none"
        cls.overlay.hide()
        cls.bind()
1027891
def clear_matplotlib_ticks(self, axis="both"):
        """"""
        ax = self.get_axes()
        plotting.clear_matplotlib_ticks(ax=ax, axis=axis)
399196
def activate_matplotlib(enable_gui_function):
    
    matplotlib = sys.modules['matplotlib']
    gui, backend = find_gui_and_backend()
    is_interactive = is_interactive_backend(backend)
    if is_interactive:
        enable_gui_function(gui)
        if not matplotlib.is_interactive():
            sys.stdout.write("Backend %s is interactive backend. Turning interactive mode on.\n" % backend)
        matplotlib.interactive(True)
    else:
        if matplotlib.is_interactive():
            sys.stdout.write("Backend %s is non-interactive backend. Turning interactive mode off.\n" % backend)
        matplotlib.interactive(False)
    patch_use(enable_gui_function)
    patch_is_interactive()
1330801
def disable(self):
        

        self.ticker_text_label.hide()
        if self.current_observed_sm_m:
            self.stop_sm_m_observation(self.current_observed_sm_m)
60811
def _repr_html_(self):
        
        # qtconsole doesn't report its line width, and also
        # behaves badly when outputting an HTML table
        # that doesn't fit the window, so disable it.
        # XXX: In IPython 3.x and above, the Qt console will not attempt to
        # display HTML, so this check can be removed when support for IPython 2.x
        # is no longer needed.

        if self._pandas and options.display.notebook_repr_widget:
            from .. import DataFrame
            from ..ui import show_df_widget
            show_df_widget(DataFrame(self._values, schema=self.schema))

        if self._pandas:
            return self._values._repr_html_()

        if in_qtconsole():
            # 'HTML output is disabled in QtConsole'
            return None

        if options.display.notebook_repr_html:
            max_rows = options.display.max_rows
            max_cols = options.display.max_columns
            show_dimensions = options.display.show_dimensions

            return self.to_html(max_rows=max_rows, max_cols=max_cols,
                                show_dimensions=show_dimensions,
                                notebook=True)
        else:
            return None
367849
def enable_ipython(self, **kwargs):
        

        # inspired by code powering similar functionality in mpld3
        # https://github.com/jakevdp/mpld3/blob/master/mpld3/_display.py#L357

        from IPython.core.getipython import get_ipython
        from IPython.display import display, Javascript, HTML

        self.ipython_enabled = True
        self.set_size('medium')

        ip = get_ipython()
        formatter = ip.display_formatter.formatters['text/html']

        if self.local_enabled:
            from lightning.visualization import VisualizationLocal
            js = VisualizationLocal.load_embed()
            display(HTML("<script>" + js + "</script>"))
            if not self.quiet:
                print('Running local mode, some functionality limited.\n')
            formatter.for_type(VisualizationLocal, lambda viz, kwds=kwargs: viz.get_html())
        else:
            formatter.for_type(Visualization, lambda viz, kwds=kwargs: viz.get_html())
            r = requests.get(self.get_ipython_markup_link(), auth=self.auth)
            display(Javascript(r.text))
563214
def p_disable(self, p):
        ''
        p[0] = Disable(p[2], lineno=p.lineno(1))
        p.set_lineno(0, p.lineno(1))
167967
def disable(name, **kwargs):
    '''
    
    '''
    cmd = '/usr/sbin/svcadm disable {0}'.format(name)
    return not __salt__['cmd.retcode'](cmd, python_shell=False)
699478
def _on_remove_library(self, *event):
        
        self.view['library_tree_view'].grab_focus()
        if react_to_event(self.view, self.view['library_tree_view'], event):
            path = self.view["library_tree_view"].get_cursor()[0]
            if path is not None:
                library_name = self.library_list_store[int(path[0])][0]
                library_config = self.core_config_model.get_current_config_value("LIBRARY_PATHS", use_preliminary=True,
                                                                                 default={})
                del library_config[library_name]
                self.core_config_model.set_preliminary_config_value("LIBRARY_PATHS", library_config)
                if len(self.library_list_store) > 0:
                    self.view['library_tree_view'].set_cursor(min(path[0], len(self.library_list_store) - 1))
            return True
130273
function disableScript( elem ) {
	elem.type = (jQuery.find.attr( elem, "type" ) !== null) + "/" + elem.type;
	return elem;
}