Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torch/gnuplot.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvo Danihelka <danihelka@google.com>2015-10-12 17:03:23 +0300
committerIvo Danihelka <danihelka@google.com>2015-10-12 17:03:23 +0300
commitd9832a2644dcf936b6c1da89778931291133cc30 (patch)
tree71e5db5355972ac9d12877b4473e43e1c466be6f
parentf74e8c1dad1326d72878692fd8a25d2a5bb2740d (diff)
Allow to get a figure without raising it.
-rw-r--r--gnuplot.lua7
1 files changed, 5 insertions, 2 deletions
diff --git a/gnuplot.lua b/gnuplot.lua
index 0532f55..22f82e6 100644
--- a/gnuplot.lua
+++ b/gnuplot.lua
@@ -803,10 +803,13 @@ function gnuplot.figprint(fname)
writeToCurrent('set term ' .. _gptable[_gptable.current].term .. ' ' .. _gptable.current .. '\n')
end
-function gnuplot.figure(n)
+function gnuplot.figure(n, config)
+ config = config or {}
local gp = getfigure(n)
writeToCurrent('set term ' .. _gptable[_gptable.current].term .. ' ' .. _gptable.current .. '\n')
- writeToCurrent('raise')
+ if not config.noraise then
+ writeToCurrent('raise')
+ end
return _gptable.current
end