Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Tiago Peixoto
graph-tool
Commits
6e3cce61
Commit
6e3cce61
authored
Dec 25, 2012
by
Tiago Peixoto
Browse files
Update sphinx/documentation files for python3 conformance
parent
d7876c80
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
doc/Makefile
View file @
6e3cce61
...
...
@@ -7,7 +7,7 @@ ORIGIMAGES = ${HUGEIMAGES:.pdf=.pdf-orig}
PNGCONV
=
pdftoppm
-png
-singlefile
-r
96
-freetype
yes
-aa
yes
-aaVector
yes
PDFCONV
=
gm convert
all
:
$(ORIGIMAGES) $(PNGIMAGES)
all
:
#
$(ORIGIMAGES) $(PNGIMAGES)
sphinx-build
-E
-b
html
.
build
%.pdf-orig
:
%.pdf
...
...
doc/gt_theme/static/flasky.css
View file @
6e3cce61
...
...
@@ -324,6 +324,7 @@ dl.function, dl.class, dl.exception {
border-top-style
:
solid
;
border-top-width
:
5px
;
padding-top
:
1em
;
clear
:
both
;
}
dl
.function
dt
,
dl
.class
dt
,
dl
.exception
dt
{
...
...
doc/pyenv.py
View file @
6e3cce61
...
...
@@ -2,6 +2,7 @@ from matplotlib import rc
from
matplotlib
import
rcParams
font_size
=
14
rcParams
[
"backend"
]
=
"Qt4Agg"
rcParams
[
"figure.figsize"
]
=
(
6
,
4.5
)
rcParams
[
"font.family"
]
=
"Serif"
rcParams
[
"font.serif"
]
=
[
"Palatino"
]
...
...
doc/sphinxext/linkcode.py
0 → 100644
View file @
6e3cce61
# -*- coding: utf-8 -*-
"""
linkcode
~~~~~~~~
Add external links to module code in Python object descriptions.
:copyright: Copyright 2007-2011 by the Sphinx team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
import
warnings
import
collections
warnings
.
warn
(
"This extension has been submitted to Sphinx upstream. "
"Use the version from there if it is accepted "
"https://bitbucket.org/birkenfeld/sphinx/pull-request/47/sphinxextlinkcode"
,
FutureWarning
,
stacklevel
=
1
)
from
docutils
import
nodes
from
sphinx
import
addnodes
from
sphinx.locale
import
_
from
sphinx.errors
import
SphinxError
class
LinkcodeError
(
SphinxError
):
category
=
"linkcode error"
def
doctree_read
(
app
,
doctree
):
env
=
app
.
builder
.
env
resolve_target
=
getattr
(
env
.
config
,
'linkcode_resolve'
,
None
)
if
not
isinstance
(
env
.
config
.
linkcode_resolve
,
collections
.
Callable
):
raise
LinkcodeError
(
"Function `linkcode_resolve` is not given in conf.py"
)
domain_keys
=
dict
(
py
=
[
'module'
,
'fullname'
],
c
=
[
'names'
],
cpp
=
[
'names'
],
js
=
[
'object'
,
'fullname'
],
)
for
objnode
in
doctree
.
traverse
(
addnodes
.
desc
):
domain
=
objnode
.
get
(
'domain'
)
uris
=
set
()
for
signode
in
objnode
:
if
not
isinstance
(
signode
,
addnodes
.
desc_signature
):
continue
# Convert signode to a specified format
info
=
{}
for
key
in
domain_keys
.
get
(
domain
,
[]):
value
=
signode
.
get
(
key
)
if
not
value
:
value
=
''
info
[
key
]
=
value
if
not
info
:
continue
# Call user code to resolve the link
uri
=
resolve_target
(
domain
,
info
)
if
not
uri
:
# no source
continue
if
uri
in
uris
or
not
uri
:
# only one link per name, please
continue
uris
.
add
(
uri
)
onlynode
=
addnodes
.
only
(
expr
=
'html'
)
onlynode
+=
nodes
.
reference
(
''
,
''
,
internal
=
False
,
refuri
=
uri
)
onlynode
[
0
]
+=
nodes
.
inline
(
''
,
_
(
'[source]'
),
classes
=
[
'viewcode-link'
])
signode
+=
onlynode
def
setup
(
app
):
app
.
connect
(
'doctree-read'
,
doctree_read
)
app
.
add_config_value
(
'linkcode_resolve'
,
None
,
'env'
)
doc/sphinxext/plot_directive.py
0 → 100644
View file @
6e3cce61
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment