widgets: add documentation support
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
3f9c7aee54
commit
4bf6d2df62
|
@ -61,7 +61,7 @@ end
|
||||||
capture = false
|
capture = false
|
||||||
for i, line in ipairs(ilines) do
|
for i, line in ipairs(ilines) do
|
||||||
if not libname then
|
if not libname then
|
||||||
_, _, libname, libtype = line:find("const struct luaL_reg awesome_(%a+)_(%a+)%[%] =")
|
_, _, libname, libtype = line:find("const struct luaL_reg awesome_(%a+)_(%a+)%[%] ")
|
||||||
-- Special case
|
-- Special case
|
||||||
if not libname then _, _, libname, libtype = line:find("const struct luaL_reg (awesome)_(lib)%[%] =") end
|
if not libname then _, _, libname, libtype = line:find("const struct luaL_reg (awesome)_(lib)%[%] =") end
|
||||||
else
|
else
|
||||||
|
|
|
@ -285,7 +285,12 @@ graph_draw(draw_context_t *ctx,
|
||||||
return w->area.width;
|
return w->area.width;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Set various graph general properties.
|
/** Set various graph general properties:
|
||||||
|
* width, the widget width;
|
||||||
|
* height, the widget height;
|
||||||
|
* bg, the bacground color;
|
||||||
|
* bordercolor, the border color;
|
||||||
|
* grow, left or right where to add plot data.
|
||||||
* \param L The Lua VM state.
|
* \param L The Lua VM state.
|
||||||
* \return The number of elements pushed on stack.
|
* \return The number of elements pushed on stack.
|
||||||
* \luastack
|
* \luastack
|
||||||
|
@ -556,4 +561,12 @@ graph_new(alignment_t align)
|
||||||
return w;
|
return w;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* This is used for building documentation. */
|
||||||
|
static const struct luaL_reg awesome_graph_meta[] __attribute__ ((unused)) =
|
||||||
|
{
|
||||||
|
{ "properties_set", luaA_graph_properties_set },
|
||||||
|
{ "plot_properties_set", luaA_graph_plot_properties_set },
|
||||||
|
{ "plot_data_add", luaA_graph_plot_data_add },
|
||||||
|
};
|
||||||
|
|
||||||
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
||||||
|
|
|
@ -606,4 +606,13 @@ progressbar_new(alignment_t align)
|
||||||
|
|
||||||
return w;
|
return w;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* This is used for building documentation. */
|
||||||
|
static const struct luaL_reg awesome_progressbar_meta[] __attribute__ ((unused)) =
|
||||||
|
{
|
||||||
|
{ "properties_set", luaA_progressbar_properties_set },
|
||||||
|
{ "bar_properties_set", luaA_progressbar_bar_properties_set },
|
||||||
|
{ "bar_data_add", luaA_progressbar_bar_data_add },
|
||||||
|
};
|
||||||
|
|
||||||
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
||||||
|
|
|
@ -417,4 +417,11 @@ taglist_new(alignment_t align)
|
||||||
return w;
|
return w;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* This is used for building documentation. */
|
||||||
|
static const struct luaL_reg awesome_taglist_meta[] __attribute__ ((unused)) =
|
||||||
|
{
|
||||||
|
{ "text_set", luaA_taglist_text_set },
|
||||||
|
{ "showempty_set", luaA_taglist_showempty_set }
|
||||||
|
};
|
||||||
|
|
||||||
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
||||||
|
|
|
@ -436,4 +436,12 @@ tasklist_new(alignment_t align __attribute__ ((unused)))
|
||||||
return w;
|
return w;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* This is used for building documentation. */
|
||||||
|
static const struct luaL_reg awesome_tasklist_meta[] __attribute__ ((unused)) =
|
||||||
|
{
|
||||||
|
{ "text_set", luaA_tasklist_text_set },
|
||||||
|
{ "showicons_set", luaA_tasklist_showicons_set },
|
||||||
|
{ "show_set", luaA_tasklist_show_set }
|
||||||
|
};
|
||||||
|
|
||||||
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
||||||
|
|
|
@ -180,4 +180,12 @@ textbox_new(alignment_t align)
|
||||||
|
|
||||||
return w;
|
return w;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* This is used for building documentation. */
|
||||||
|
static const struct luaL_reg awesome_textbox_meta[] __attribute__ ((unused)) =
|
||||||
|
{
|
||||||
|
{ "text_set", luaA_textbox_text_set },
|
||||||
|
{ "width_set", luaA_textbox_width_set }
|
||||||
|
};
|
||||||
|
|
||||||
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
||||||
|
|
Loading…
Reference in New Issue