2019-06-06 08:06:28 +02:00
|
|
|
local args = ...
|
|
|
|
|
|
|
|
|
2012-11-19 14:57:47 +01:00
|
|
|
-- Configuration file for ldoc
|
2014-05-25 14:35:44 +02:00
|
|
|
|
2012-11-19 14:57:47 +01:00
|
|
|
project='awesome'
|
|
|
|
title='awesome API documentation'
|
2015-06-14 02:35:10 +02:00
|
|
|
description='API documentation for awesome, a highly configurable X window manager (version @AWESOME_VERSION@).'
|
2014-05-19 11:48:23 +02:00
|
|
|
|
|
|
|
-- More on it: https://github.com/stevedonovan/LDoc/blob/master/doc/doc.md#markdown-support
|
2014-05-26 21:26:52 +02:00
|
|
|
format='discount'
|
|
|
|
dir='../doc'
|
2014-05-19 11:48:23 +02:00
|
|
|
|
|
|
|
-- Make the docs prettier
|
|
|
|
pretty='lua'
|
2017-10-21 20:19:00 +02:00
|
|
|
style=true
|
2019-01-04 14:19:21 +01:00
|
|
|
template=true
|
2014-05-19 11:48:23 +02:00
|
|
|
backtick_references=true
|
|
|
|
merge=true
|
2015-06-14 02:35:10 +02:00
|
|
|
use_markdown_titles=true
|
2015-02-20 15:24:26 +01:00
|
|
|
wrap=true
|
2016-12-27 14:17:39 +01:00
|
|
|
full_description = [[
|
|
|
|
Welcome to the documentation for the awesome window manager. Below you find an
|
|
|
|
overview of the individual parts which links to the full documentation.
|
|
|
|
|
|
|
|
If you are a new user, you may want to read @{07-my-first-awesome.md} to get
|
|
|
|
started. In @{05-awesomerc.md}, the default configuration is explained.
|
|
|
|
|
|
|
|
If you already used awesome in the past, @{89-NEWS.md} and @{17-porting-tips.md}
|
|
|
|
should be useful for you.
|
|
|
|
]]
|
2014-05-24 23:25:12 +02:00
|
|
|
topics={
|
2014-05-26 21:26:52 +02:00
|
|
|
'00-authors.md',
|
|
|
|
'01-readme.md',
|
|
|
|
'02-contributing.md',
|
2016-02-10 07:07:47 +01:00
|
|
|
'03-declarative-layout.md',
|
2016-02-10 07:21:29 +01:00
|
|
|
'04-new-widgets.md',
|
2016-08-12 21:18:27 +02:00
|
|
|
'05-awesomerc.md',
|
2016-08-12 08:01:45 +02:00
|
|
|
'06-appearance.md',
|
2016-12-27 13:57:56 +01:00
|
|
|
'07-my-first-awesome.md',
|
2016-06-11 05:53:17 +02:00
|
|
|
'16-using-cairo.md',
|
2016-12-21 03:59:07 +01:00
|
|
|
'17-porting-tips.md',
|
2016-04-30 11:54:16 +02:00
|
|
|
'90-FAQ.md',
|
2016-12-10 05:55:48 +01:00
|
|
|
'89-NEWS.md',
|
2014-05-24 23:25:12 +02:00
|
|
|
}
|
2015-02-15 22:33:23 +01:00
|
|
|
|
2015-07-25 00:00:07 +02:00
|
|
|
-- Setup @client to be an alias for "@tparam client.object"
|
|
|
|
tparam_alias('client', 'client.object')
|
2014-05-19 11:48:23 +02:00
|
|
|
tparam_alias('tag', 'tag')
|
2015-02-15 22:33:23 +01:00
|
|
|
-- Should be default, but is not. Sets up "@tab" => "@tparam table".
|
|
|
|
tparam_alias('tab', 'table')
|
2016-10-02 16:03:11 +02:00
|
|
|
tparam_alias('screen', 'screen')
|
|
|
|
tparam_alias('screen_or_idx', 'screen|int')
|
2016-04-03 08:59:50 +02:00
|
|
|
|
|
|
|
-- Hack to get the functions and method on top of the signals and properties
|
2019-06-06 07:19:02 +02:00
|
|
|
new_type("function", "Functions", false, "Parameters")
|
2016-04-03 08:59:50 +02:00
|
|
|
-- Documentation for objects properties
|
|
|
|
new_type("property", "Object properties", false, "Type")
|
2019-03-12 19:36:32 +01:00
|
|
|
-- Documentation for objects deprecated properties
|
|
|
|
new_type("deprecatedproperty", "Deprecated object properties", false, "Type")
|
2015-02-27 00:24:23 +01:00
|
|
|
-- New type for signals
|
|
|
|
new_type("signal", "Signals", false, "Arguments")
|
2016-04-25 04:42:32 +02:00
|
|
|
-- New type for signals connections
|
|
|
|
new_type("signalhandler", "Request handlers", false, "Arguments")
|
2016-04-03 08:59:50 +02:00
|
|
|
-- Allow objects to define a set of beautiful properties affecting them
|
|
|
|
new_type("beautiful", "Theme variables", false, "Type")
|
|
|
|
-- Put deprecated methods in their own section
|
2019-06-06 07:19:02 +02:00
|
|
|
new_type("deprecated", "Deprecated functions", false, "Parameters")
|
2016-04-03 08:59:50 +02:00
|
|
|
-- For the legacy stateless layout related functions
|
2019-06-06 07:19:02 +02:00
|
|
|
new_type("legacylayout", "Layout related functions", false, "Parameters")
|
2016-12-10 02:24:22 +01:00
|
|
|
-- Have a category for the client layouts
|
2019-06-06 07:19:02 +02:00
|
|
|
new_type("clientlayout", "Client layouts", false, "Parameters")
|
2018-08-18 22:26:59 +02:00
|
|
|
-- Source functions for the taglist/tasklist/layoutlist
|
|
|
|
new_type("sourcefunction", "List source functions", false)
|
2016-12-30 07:49:04 +01:00
|
|
|
-- Document some callback prototypes
|
|
|
|
new_type("callback", "Callback functions prototype", false, "Parameters")
|
2019-02-24 21:24:58 +01:00
|
|
|
-- gears.matcher / awful.rules sources
|
2019-06-06 07:19:02 +02:00
|
|
|
new_type("rulesources", "Rule sources", false, "Parameters")
|
2019-02-24 21:24:58 +01:00
|
|
|
-- gears.matcher / awful.rules rule components
|
|
|
|
new_type("rulecomponent", "Rule components", false, "Type")
|
2018-08-18 21:47:14 +02:00
|
|
|
-- Filter functions for the taglist/tasklist/layoutlist
|
|
|
|
new_type("filterfunction", "List filters", false)
|
2018-10-07 01:40:36 +02:00
|
|
|
-- Extra client properties available only in awful.rules/spawn constructs
|
|
|
|
new_type("clientruleproperty", "Extra properties available in awful.rules and awful.spawn", false, "Type")
|
2014-05-19 11:48:23 +02:00
|
|
|
|
2015-02-20 15:24:26 +01:00
|
|
|
-- More fitting section names
|
2017-02-25 21:41:54 +01:00
|
|
|
kind_names={topic='Documentation', module='Libraries', script='Sample files'}
|
2015-02-20 15:24:26 +01:00
|
|
|
|
|
|
|
-- Sort modules alphabetically
|
|
|
|
sort_modules=true
|
|
|
|
|
2019-06-06 08:06:28 +02:00
|
|
|
-- Add more project level (left side index) types.
|
|
|
|
new_type("widgetmod" , "Widgets" , true)
|
|
|
|
new_type("containermod", "Widget containers", true)
|
|
|
|
new_type("layoutmod" , "Widget layouts" , true)
|
2019-06-06 08:40:00 +02:00
|
|
|
new_type("coreclassmod", "Core components" , true)
|
2019-06-06 08:44:00 +02:00
|
|
|
new_type("popupmod" , "Popups and bars" , true)
|
2019-06-06 09:40:17 +02:00
|
|
|
new_type("utillib" , "Utility libraries", true)
|
2019-06-06 09:49:21 +02:00
|
|
|
new_type("themelib" , "Theme related libraries", true)
|
2019-06-06 08:06:28 +02:00
|
|
|
|
2014-05-19 11:48:23 +02:00
|
|
|
file = {
|
2015-02-27 00:24:23 +01:00
|
|
|
-- C parts of libraries
|
|
|
|
'../dbus.c',
|
|
|
|
'../luaa.c',
|
|
|
|
'../mouse.c',
|
|
|
|
'../mousegrabber.c',
|
|
|
|
'../root.c',
|
|
|
|
'../selection.c',
|
|
|
|
'../spawn.c',
|
|
|
|
'../xkb.c',
|
|
|
|
'../common/luaobject.c',
|
2017-07-02 17:12:12 +02:00
|
|
|
'../objects/button.c',
|
|
|
|
'../objects/client.c',
|
|
|
|
'../objects/drawable.c',
|
|
|
|
'../objects/key.c',
|
|
|
|
'../objects/screen.c',
|
|
|
|
'../objects/tag.c',
|
|
|
|
'../objects/window.c',
|
|
|
|
|
2014-05-24 23:25:12 +02:00
|
|
|
-- LUA libraries
|
2014-05-26 21:26:52 +02:00
|
|
|
'../lib/',
|
2017-02-25 21:41:54 +01:00
|
|
|
-- Auto generated scripts
|
|
|
|
'../script_files/',
|
2014-05-19 11:48:23 +02:00
|
|
|
exclude = {
|
|
|
|
-- exclude these modules, as they do not contain any written
|
|
|
|
-- documentation
|
2014-05-26 21:26:52 +02:00
|
|
|
'../lib/awful/autofocus.lua',
|
|
|
|
'../lib/awful/dbus.lua',
|
2015-02-26 17:48:10 +01:00
|
|
|
'../lib/awful/init.lua',
|
2014-05-26 21:26:52 +02:00
|
|
|
'../lib/awful/remote.lua',
|
|
|
|
'../lib/awful/startup_notification.lua',
|
2019-02-24 23:05:07 +01:00
|
|
|
'../lib/awful/mouse/drag_to_tag.lua',
|
2015-02-26 17:48:10 +01:00
|
|
|
'../lib/gears/init.lua',
|
|
|
|
'../lib/wibox/layout/init.lua',
|
2016-05-23 05:56:45 +02:00
|
|
|
'../lib/wibox/container/init.lua',
|
2017-07-02 04:43:26 +02:00
|
|
|
'../lib/naughty/constants.lua',
|
|
|
|
'../lib/naughty/dbus.lua',
|
2014-05-19 11:48:23 +02:00
|
|
|
|
2014-05-20 23:52:08 +02:00
|
|
|
-- Ignore some parts of the widget library
|
2015-02-26 16:05:47 +01:00
|
|
|
'../lib/awful/widget/init.lua',
|
2017-07-02 04:43:26 +02:00
|
|
|
'../lib/naughty/layout/init.lua',
|
2017-11-19 06:20:56 +01:00
|
|
|
|
|
|
|
-- Deprecated classes for one years or more don't deserve entries
|
|
|
|
-- in the index
|
|
|
|
'../lib/awful/widget/graph.lua',
|
|
|
|
'../lib/awful/widget/progressbar.lua',
|
2019-06-06 10:21:08 +02:00
|
|
|
'../lib/awful/widget/textclock.lua',
|
|
|
|
'../lib/awful/wibox.lua',
|
2017-11-19 06:20:56 +01:00
|
|
|
'../lib/wibox/layout/constraint.lua',
|
|
|
|
'../lib/wibox/layout/margin.lua',
|
|
|
|
'../lib/wibox/layout/mirror.lua',
|
|
|
|
'../lib/wibox/layout/rotate.lua',
|
|
|
|
'../lib/wibox/layout/scroll.lua',
|
|
|
|
'../lib/wibox/widget/background.lua',
|
2014-05-19 11:48:23 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-10-07 01:40:36 +02:00
|
|
|
local no_prefix = {
|
2019-03-12 19:36:32 +01:00
|
|
|
property = true, signal = true, clientruleproperty = true,
|
|
|
|
deprecatedproperty = true,
|
2018-10-07 01:40:36 +02:00
|
|
|
}
|
|
|
|
|
2019-06-06 10:21:08 +02:00
|
|
|
-- These modules merge the doc of their `awful` siblings.
|
|
|
|
local coreclassmap = {
|
|
|
|
tag = "tag<span class='listplusign'> and awful.tag</span>",
|
|
|
|
screen = "screen<span class='listplusign'> and awful.screen</span>",
|
|
|
|
client = "client<span class='listplusign'> and awful.client</span>",
|
|
|
|
mouse = "mouse<span class='listplusign'> and awful.mouse</span>",
|
|
|
|
}
|
|
|
|
|
2018-05-28 19:59:22 +02:00
|
|
|
custom_display_name_handler = function(item, default_handler)
|
|
|
|
-- Remove the "namespace" from the signals and properties
|
2018-10-07 01:40:36 +02:00
|
|
|
if no_prefix[item.type] then
|
2018-05-28 19:59:22 +02:00
|
|
|
local name = item.name:match("%.([^.]+)$")
|
|
|
|
return name ~= "" and name or item.name
|
|
|
|
end
|
|
|
|
|
2019-06-06 10:21:08 +02:00
|
|
|
-- Handle the left sidebar modules.
|
|
|
|
if item.type == "coreclassmod" and coreclassmap[item.name] then
|
|
|
|
return coreclassmap[item.name]
|
|
|
|
end
|
|
|
|
|
2019-03-12 19:36:32 +01:00
|
|
|
if item.type == "deprecated" or item.type == "deprecatedproperty" then
|
2019-06-06 07:21:35 +02:00
|
|
|
return default_handler(item) .. "<i class=\"deprecated_label\"> [deprecated]</i>"
|
2018-05-28 20:05:05 +02:00
|
|
|
end
|
|
|
|
|
2019-06-05 23:25:29 +02:00
|
|
|
local ret = default_handler(item)
|
|
|
|
|
|
|
|
-- Get rid of the "module:" in front of method names. It is either wrong or
|
|
|
|
-- just redundant.
|
|
|
|
ret = ret:gsub("([^:]*)(:[^:])","%2")
|
|
|
|
|
2019-06-06 07:02:31 +02:00
|
|
|
-- Undocumented API to get rid of `module.rounded_rect` rather than
|
|
|
|
-- `gears.shape.rounded_rect`
|
|
|
|
if ret:sub(1, 7) == "module." and module then
|
|
|
|
return ret:gsub("^module", item.module.name)
|
|
|
|
end
|
|
|
|
|
|
|
|
-- Undocumented API to make the libraries and classmod "function" section
|
|
|
|
-- more consistent. Right now some have their full awful.foo.bar while other
|
|
|
|
-- have "just" `bar`. Given we use constructors from metatables, we have no
|
|
|
|
-- choice but to use the full function name. It also makes copy/paste easier.
|
|
|
|
if item.type == "function" and (not ret:find(".", 1, true)) and (not ret:find(":", 1, true)) then
|
|
|
|
return item.module.name .. "." .. ret
|
|
|
|
end
|
|
|
|
|
2019-06-05 23:25:29 +02:00
|
|
|
return ret
|
2018-05-28 19:59:22 +02:00
|
|
|
end
|
|
|
|
|
2015-12-12 17:42:33 +01:00
|
|
|
-- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80
|