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

gp interface help should use extended help text (from "??") #1062

Open
sagetrac-cwitty mannequin opened this issue Nov 2, 2007 · 5 comments
Open

gp interface help should use extended help text (from "??") #1062

sagetrac-cwitty mannequin opened this issue Nov 2, 2007 · 5 comments

Comments

@sagetrac-cwitty
Copy link
Mannequin

sagetrac-cwitty mannequin commented Nov 2, 2007

<wstein> 
 The new ?? help looks quite nice. It would
 be good for gp.foo? to use it.

The idea is that

sage: foo = gp(x)
sage: foo.polroots?

should use the help text from the gp command ??polroots.

The obvious approach is to change '?%s' to '??%s' in gp.py's help() method. This doesn't quite work, for two reasons:

  1. gphelp carefully formats the text to fit in the current line width, and then Sage displays this text indented; so almost every line wraps.

  2. gphelp uses control characters to make words bold, underlined, etc.; when the help is viewed from the notebook, these control codes are visible in the output, and look very ugly.

CC: @videlec @jdemeyer @slel

Component: interfaces

Keywords: pari/gp, help

Reviewer: Michael Orlitzky

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

@mezzarobba
Copy link
Member

comment:1

See #17860 for a possible strategy.

@slel
Copy link
Member

slel commented Nov 23, 2018

Changed keywords from none to pari/gp, help

@videlec
Copy link
Contributor

videlec commented Feb 17, 2020

comment:3

This works in cypari2 which is de facto the way to use PARI in Sage

sage: x.polroots?
Signature:      x.polroots(precision)
Docstring:     
   Complex roots of the given polynomial using Schonhage's method, as
   modified by Gourdon.

@orlitzky
Copy link
Contributor

orlitzky commented Apr 4, 2020

Reviewer: Michael Orlitzky

@fchapoton
Copy link
Contributor

comment:5

I do not agree that this works. We currently display only the short documentation, for pari() objects as well as for gp() objects.

The complete doc is much longer.

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

6 participants