diff --git a/lib/wibox/widget/graph.lua b/lib/wibox/widget/graph.lua index ddc32b002..ac3672e3e 100644 --- a/lib/wibox/widget/graph.lua +++ b/lib/wibox/widget/graph.lua @@ -1,6 +1,7 @@ --------------------------------------------------------------------------- --- A graph widget. -- +--@DOC_wibox_widget_defaults_graph_EXAMPLE@ -- @author Julien Danjou <julien@danjou.info> -- @copyright 2009 Julien Danjou -- @release @AWESOME_VERSION@ diff --git a/tests/examples/wibox/widget/defaults/graph.lua b/tests/examples/wibox/widget/defaults/graph.lua new file mode 100644 index 000000000..6ccd93b5a --- /dev/null +++ b/tests/examples/wibox/widget/defaults/graph.lua @@ -0,0 +1,22 @@ +local parent = ... --DOC_HIDE +local wibox = require("wibox") --DOC_HIDE + +local data = { --DOC_HIDE + 3, 5, 6,4, 11,15,19,29,17,17,14,0,0,3,1,0,0, 22, 17,7, 1,0,0,5, --DOC_HIDE + 3, 5, 6,4, 11,15,19,29,17,17,14,0,0,3,1,0,0, 22, 17,7, 1,0,0,5, --DOC_HIDE + 3, 5, 6,4, 11,15,19,29,17,17,14,0,0,3,1,0,0, 22, 17,7, 1,0,0,5, --DOC_HIDE + 3, 5, 6,4, 11,15,19,29,17,17,14,0,0,3,1,0,0, 22, 17,7, 1,0,0,5, --DOC_HIDE + 3, 5, 6,4, 11,15,19,29,17,17,14,0,0,3,1,0,0, 22, 17,7, 1,0,0,5, --DOC_HIDE +} --DOC_HIDE + +local w = --DOC_HIDE +wibox.widget { + max_value = 29, + widget = wibox.widget.graph +} + +parent:add( w ) --DOC_HIDE + +for _, v in ipairs(data) do --DOC_HIDE + w:add_value(v) --DOC_HIDE +end --DOC_HIDE