Ticket #6001: trac_6001_tearout_docstring_v1.patch

File trac_6001_tearout_docstring_v1.patch, 1.8 KB (added by mpatel, 12 years ago)

Needs accompanying introspect.js

  • doc/introspect/templates/layout.html

    # HG changeset patch
    # User Mitesh Patel <qed777@gmail.com>
    # Date 1241648734 25200
    # Node ID cb50733a1d7c2b669a5efbb7d4750c3dad48a0fc
    # Parent  3d7fce9264e936d6978bc1bc3f199b55fea431cd
    Tear out notebook docstrings into new window.  Separate file: introspect.js
    
    diff --git a/doc/introspect/templates/layout.html b/doc/introspect/templates/layout.html
    a b  
    11<div class="docstring">
     2  <div class="docstring_header">
     3    <table style="width: 100%;">
     4      <tbody>
     5        <tr>
     6          <td class="docstring_name" align="left" style="color: black;">
     7          </td>
     8          <td class="docstring_toolbar" align="right" style="color: black;">
     9            <a href="#" onclick="introspect.open($(this));">ooo</a>
     10            | <a href="#" onclick="introspect.close($(this));">xxx</a>
     11            | <a href="#" onclick="introspect.font_smaller($(this));">aaa</a>
     12            | <a href="#" onclick="introspect.font_reset($(this));">---</a>
     13            | <a href="#" onclick="introspect.font_larger($(this));">AAA</a>
     14            | <a href="#" onclick="introspect.toggle($(this));">tog</a>
     15          </td>
     16        </tr>
     17      </tbody>
     18    </table>
     19  </div>
     20  <div class="docstring_proper">
    221    {% block body %} {% endblock %}
     22  </div>
    323</div>
  • sage/server/notebook/notebook.py

    diff --git a/sage/server/notebook/notebook.py b/sage/server/notebook/notebook.py
    a b  
    17871787# <script type="text/javascript" src="/javascript_local/jqueryui/ui.resizable.min.js"></script>
    17881788# <script type="text/javascript" src="/javascript_local/jqueryui/ui.dialog.min.js"></script>
    17891789
     1790        head += '<script type="text/javascript" src="/javascript_local/introspect.js"></script>\n'
    17901791
    17911792        # This was for syntax hilighting 
    17921793#        head +=' <script type="text/javascript" src="/javascript/highlight/prettify.js"></script>\n'