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

strip 'nodetex' from docstrings #6122

Closed
jhpalmieri opened this issue May 23, 2009 · 6 comments
Closed

strip 'nodetex' from docstrings #6122

jhpalmieri opened this issue May 23, 2009 · 6 comments

Comments

@jhpalmieri
Copy link
Member

It bothers me that when you ask for a docstring with a 'nodetex' directive, that directive is printed as part of the docstring. This patch strips it out.

Before (note the line after "Docstring:"):

sage: view?
Base Class:       <type 'function'>
String Form:   <function view at 0x102a230>
Namespace:        Interactive
File:             /Applications/sage/local/lib/python2.5/site-packages/sage/misc/latex.py
Definition:       view(objects, title='SAGE', debug=False, sep='', tiny=False, **kwds)
Docstring:
    nodetex
        Compute a latex representation of each object in objects, compile,
        and display typeset. If used from the command line, this requires
        that latex be installed.

After:

sage: view?
Base Class:       <type 'function'>
String Form:   <function view at 0x102b770>
Namespace:        Interactive
File:             /Applications/sage/local/lib/python2.5/site-packages/sage/misc/latex.py
Definition:       view(objects, title='SAGE', debug=False, sep='', tiny=False, pdflatex=None, **kwds)
Docstring:
    
        Compute a latex representation of each object in objects, compile,
        and display typeset. If used from the command line, this requires
        that latex be installed.

Component: misc

Author: John Palmieri

Reviewer: Rob Beezer

Merged: 4.0.1.alpha0

Issue created by migration from https://trac.sagemath.org/ticket/6122

@rbeezer
Copy link
Mannequin

rbeezer mannequin commented May 31, 2009

comment:1

Attachment: no-nodetex.patch.gz

Applies cleanly to 4.0, works as advertised at command-line and in the notebook.

Passes sage -t -rand sage/misc/sagedoc.py

It would be nice if these directives were cleaned out prior to building the PDF and HTML versions of the documentation. This patch seems to only apply to the "interactive" documentation. I'm still seeing nodetex directives in the PDF anyway, and in a sense they are worse, as they lead off a line and then the real beginning follows with no line break (as it used to look in the ASCII versions).

Positive review.

@rbeezer rbeezer mannequin added the s: positive review label May 31, 2009
@jhpalmieri
Copy link
Member Author

comment:2

It would be nice if these directives were cleaned out prior to building the PDF and HTML versions of the documentation.

See #6166.

@mwhansen
Copy link
Contributor

mwhansen commented Jun 1, 2009

comment:3

Merged in 4.0.1.alpha0.

@sagetrac-mvngu
Copy link
Mannequin

sagetrac-mvngu mannequin commented Jun 6, 2009

Merged: 4.0.1.alpha0

@sagetrac-mvngu
Copy link
Mannequin

sagetrac-mvngu mannequin commented Jun 6, 2009

Reviewer: Rob Beezer

@sagetrac-mvngu
Copy link
Mannequin

sagetrac-mvngu mannequin commented Jun 6, 2009

Author: John Palmieri

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants