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
b93b5010
Commit
b93b5010
authored
May 18, 2009
by
Tiago Peixoto
Browse files
Change Graph.stash_filter() semantics
Now the parameter "all" is ignored, if any of the other parameters is True.
parent
f5d54203
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/graph_tool/core.py
View file @
b93b5010
...
...
@@ -737,6 +737,8 @@ class Graph(object):
directed
=
False
,
reversed
=
False
,
all
=
True
):
"""Stash current filter state and recover unfiltered graph. The optional
keyword arguments specify which type of filter should be stashed."""
if
edge
or
vertex
or
directed
or
reversed
:
all
=
False
self
.
__stashed_filter_state
.
append
(
self
.
__filter_state
)
if
libcore
.
graph_filtering_enabled
():
if
vertex
or
all
:
...
...
@@ -753,6 +755,8 @@ class Graph(object):
directed
=
False
,
reversed
=
False
,
all
=
False
):
"""Pop last stashed filter state. The optional keyword arguments specify
which type of filter should be recovered."""
if
edge
or
vertex
or
directed
or
reversed
:
all
=
False
state
=
self
.
__stashed_filter_state
.
pop
()
if
libcore
.
graph_filtering_enabled
():
if
vertex
or
all
:
...
...
Write
Preview
Supports
Markdown
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