Commit Graph

116 Commits

Author SHA1 Message Date
Sergey 486fd3744f Adding ldoc readonly tag text in the extra_summary list 2021-10-26 18:31:45 -04:00
Sergey 899f9c8879 Adding readonly ldoc tag 2021-10-26 18:07:20 -04:00
Sergey 60dfa3f6bd Fixing a typo 2021-10-26 18:06:38 -04:00
Emmanuel Lepage Vallee ae71158093 doc: Add documentation for the client "window factor" related functions
It might be a good idea to deprecate them and move them to the tag
class. However, these APIs are not exactly well designed, so
moving them wont solve that. Some day the dynamic client layout will
hopefully be merged and send these functions to the heap of smelly
bad ideas trash.
2021-10-18 14:38:37 -07:00
Emmanuel Lepage Vallee 93283a9885 doc: Undocument internal client `urgent` and `shape` methods.
There is already some permissions to change the behavior. I don't
think there is valid user-facing use cases for these "methods".
2021-10-18 14:38:37 -07:00
Emmanuel Lepage Vallee 5f321df4cc doc: Fix the image link on the index page. 2021-10-04 10:38:05 -07:00
aflorea-2k 8a81745d4d
doc(index.html): fixed broken links (#3402)
Fixes #3393, where links to guides were hard-coded, and pointed to wrong
places in the git version.
2021-08-04 11:07:57 -07:00
Aire-One af3b194a31 doc(@hidden;ldoc.ltp): Add ldoc tag to hide item
Add a new ldoc tag `@hidden`. This tag allows us to keep documentation
for magic methods (e.g. `wibox.widget.base:get_visible`) but prevent
it from being part of the documentation used by final users.
2021-04-02 19:24:07 +02:00
Aire-One 4dd689f181 doc(@supermodule;ldoc.ltp): Draw hierarchy tree
This commit adds a new ldoc custom tag `@supermodule`. It has to be
used at the module level. It should refer to the module
supermodules.

This tag can be used multiple time by the same module, but we ignore
other calls (for now?) as (AFAIK) we only use one way inheritance.

This tag is used in the ldoc template to find modules hierarchy and
draw the inheritance tree. It makes it easy to find and navigate to
parents modules.
2021-04-02 19:24:07 +02:00
Lucas Schwiderski 849a8b5af4
Add docs section about building and testing
This documents various CMake variables for building and the available
test suites.

Signed-off-by: Lucas Schwiderski <lucas@lschwiderski.de>
2021-03-23 10:18:29 +01:00
Emmanuel Lepage Vallee ac0aeb65c0 doc: Modernize the landing page.
The previous index.html was scary and the most useful links were
at the bottom. This commit fixes that.

It also adds an image of the default config with some labels to name
all visible components.
2021-03-22 00:54:00 -07:00
Aire-One 8bdabb234b draft 2021-03-21 23:58:05 -07:00
Emmanuel Lepage Vallee d408ec7846 doc: Use a more compact rendering for method return types. 2020-02-29 21:17:27 -05:00
Emmanuel Lepage Vallee 79dd2d731a doc: Improve the method and function rendering.
It now adds the return type to the signature.
2020-02-29 21:17:27 -05:00
Emmanuel Lepage Vallee d755a877ff doc: Add a new manual page describing the command line options. 2020-02-08 17:59:16 -05:00
Emmanuel Lepage-Vallee 46026ccc2e doc: Fix a regression that added another space in the URL.
This will break some existing links, but oh well, it isn't the first
time and some websites cannot render URLs with spaces in them. This
means external references to some of the input doc are currently
impossible.
2020-01-19 20:30:06 -05:00
Emmanuel Lepage-Vallee 31e0a3e67b doc: Fix the item summary rendering.
* Correctly count the elements
 * Use singular and plural tense properly
2020-01-19 20:30:06 -05:00
Emmanuel Lepage-Vallee 74ba84b299 doc: Make use of the @classsignal tag.
It wasn't doing anything until now.
2020-01-19 20:30:06 -05:00
Emmanuel Lepage-Vallee 575b0f12dc doc: Remove all type aliases.
They render poorly and serve no purpose.

    #!/bin/bash
    for FILE in $(git ls-files | grep -E "\.(h|c|lua)" | grep -v tests | grep -v spec); do
        sed -i 's/^[ ]*--*[ ]*@client /-- @tparam client /g' $FILE
    done
2020-01-19 20:30:06 -05:00
Emmanuel Lepage Vallee 84e6bbb86d doc: Improve the common documentation between all rules modules.
It was missing lesser/greater and the `id` type wasn't rendered
properly.
2020-01-19 02:39:30 -05:00
Emmanuel Lepage Vallee 104eac0bec doc: Update the ldoc config to handle the new ruled module. 2020-01-19 01:55:54 -05:00
Emmanuel Lepage Vallee 2b11fcfd1c doc: Add a section for rules matching properties.
It also change the text of "clientproperties" to be more generic so it
can apply to other type of rules.
2020-01-19 01:55:54 -05:00
Emmanuel Lepage Vallee 6ee294fd5a doc: Make sure the ruled module init.lua is ignored.
This has to be in its own commit otherwise Travis will fail. This
is because it will keep the file in the build directory when
iterating all commits. Then `ldoc` will fail because the file doesn't
have documentation. If `config.ld` is updated first, then it will
fail because `ruled/init.lua` doesn't exist yet. When it is done
in a separate commit, then `config.ld` is already updated and comes
with `init.lua`.
2020-01-19 01:55:54 -05:00
Emmanuel Lepage Vallee e208b81763 doc: Add a @request tag to document the request:: contexts. 2020-01-11 15:43:31 -08:00
Emmanuel Lepage Vallee 7705ef9f1e doc: Add a @classsignal tag.
To be used to denote when a signal only exists on a class, rahter
than on instances + class.
2020-01-11 15:43:31 -08:00
Emmanuel Lepage Vallee 5818de41ce awful: Rename awful.ewmh to awful.permissions.
It has nothing to do with EWMH since a long time. It was already used
for the requests, so lets formalize this.
2020-01-11 15:43:30 -08:00
Emmanuel Lepage Vallee efc42b1be1 autofocus: Modify `awful.autofocus` to be a request::.
This also pulls in part of the permission framework to ensure
backward compatibility is kept.

`awful.autofocus` was always weird. It is a module part of `awful`,
but it was never part of `awful` `init.lua`. Rather, `rc.lua` was
the sole place it was used. It behave exactly like a request, but
predate them by years. As I cleanup the request:: API before the
permissions API gets formalized, this has to be fixed now.

It isn't deprecated in this commit because it makes too many tests
fail. Another pull request will solve that by adding the "API level"
concept to AwesomeWM so I can change the behavior without breaking
existing configs. With that, the behavior of `autofocus` will be
enabled by default with the permissions to disable it.
2020-01-11 15:43:15 -08:00
Emmanuel Lepage Vallee 067bcaca60 client: Rename the `manage` and `unmanage` signals.
They currently fit the general concept of a `request::` in the sense
that they are not property related and have "request handlers".

The commit also add deprecation for signals.

The reason for this fits within the larger standardization project.
Non-namespaced signals will eventually be renamed. This has started
a long time ago.

What is old is new again. Once upon a time, there was a `startup`
parameter to the `manage` signal. It is now back in the form of
a context.

Finally, this commit removes the `manage` section of `rc.lua`. It no
longer did anything worthy of being in the config. Each of its
important parts have been moved out over the years and the last
remaining bit is always required anyway. The code has been moved
to `client.lua`.
2020-01-11 14:43:56 -08:00
Aire-One 3a99b91334 Fix a quirk for type render in the default format. 2019-12-05 19:05:36 +01:00
Aire-One 05e92672d6 Fix `@propemits` format mistakes. 2019-12-05 18:39:51 +01:00
Emmanuel Lepage Vallee 4168462b33 doc: Add an `@interface` tag.
Unlike `@baseclass`, some methods (like :reset()) and properties
are implemented across multiple classes.
2019-11-29 01:26:25 -05:00
Emmanuel Lepage Vallee 3508b6a18b doc: Add an `@introducedin` tag.
It is optional for now, but maybe in the future we can make
it mandatory. It will allow to have some "New!", "Not released"
messages or something in the doc. That would allow us to share
most of the doc between the stable and git versions.
2019-11-29 01:26:25 -05:00
Emmanuel Lepage Vallee 6f92f60076 doc: Add more deprecation related tags.
They do nothing for now, but once we are done adding them to
everything, they will replace the old `@deprecated` family of
type-tags.

They carry more information such as when it was removed and why.
Cross-referenced with the @version, we can infer the deprecation
status based on the current release rather than a boolean
"deprecated or not deprecated".
2019-11-29 01:26:25 -05:00
Emmanuel Lepage Vallee ec7cac5dbf doc: Add a summary next to the property/method title. 2019-11-29 01:26:25 -05:00
Aire-One 46c86351a0 Add ldoc tags for inherited members.
* Add `@inheritedproperty`, `@inheritedmethod` and `@inheritedsignal` ldoc tags to specify inherited members in the documentation,
* These new tags create their own section in the rendered documentation,
* Implemente these tags for `docs/common/object.ldoc` and `docs/common/widget.ldoc`.
2019-11-29 01:26:25 -05:00
Emmanuel Lepage Vallée c34d2577ea
Update docs/config.ld
Co-Authored-By: Yauhen Kirylau <actionless.loveless@gmail.com>
2019-11-27 13:11:20 -05:00
Emmanuel Lepage Vallee 9c63b20b62 doc: Generate a summary of some noteworty tags. 2019-11-27 01:44:23 -05:00
Emmanuel Lepage Vallee a3a2fc1344 doc: Hide the newly auto-generated content by default.
First of all, yes, JavaScript in the doc. I don't like this either.

The reason is that the new sections are super useful *when you need
them*. However, in practice, that's rare. So better not make the
signal to noise ratio worst. Future commit will introduce an
auto-generated summary of what's hidden.
2019-11-27 01:44:23 -05:00
Emmanuel Lepage Vallee ee912671eb doc: Add a standard `@propbeautiful` tag.
This allows to state that this variable has a equivalent beautiful
variable named using the usual conventions. It will generate all
the boilerplate magically and also takes optional fallback variable
names.
2019-11-27 01:44:23 -05:00
Emmanuel Lepage Vallee deca2880c5 doc: Add a new `@propemits` for common property signals.
This adds a lot more boilerplate than `@emits`. In turn, it avoids
copy/pasting some code for *all* properties.
2019-11-27 01:44:23 -05:00
Emmanuel Lepage Vallee a6add4dab6 doc: Add explicit inheritance support.
Adding a `@baseclass` tag will help detect inherited methods and
properties without hacks.
2019-11-27 01:43:07 -05:00
Emmanuel Lepage Vallee e1ddde7703 doc: Add a new custom tag to list the theme variables used by a method. 2019-11-27 01:43:07 -05:00
Emmanuel Lepage Vallee ee89e7c686 doc: Add a new custom tag for signals emitted by a method. 2019-11-27 01:43:00 -05:00
Emmanuel Lepage Vallee 7831a3f58d doc: Re-implement tag parsing in the config.
So, now ldoc is implemented within ldoc, great!

This is done to allow new custom tags to have the same power and
expressivness as built in ones. This way we can express signals
and theme variables correctly.
2019-11-27 01:41:04 -05:00
Emmanuel Lepage Vallee 4dbc83fa7d doc: Modify the template to allow merging sections.
It might not be the most pretty of change, but it works. With this
change, it is possible to have multiple "things" in the "same"
section having the "same" name.

This allows for C/C++ style functions with the same name but different
signatures. Lua doesn't handle this well, so it should usually be
avoided. However, constructors might be a valid exception. Most older
widget (and object) constructors have multiple random argument while
newer one use `args`. Deprecating the old ones for the sake of
standardization might be a bit too much for users upgrading from v3.5.

Given the only reason all of those deprecation would happen is because
"its pretty that way", then lets allow 2 constructors and avoid outrage.
2019-11-03 01:28:29 -05:00
Emmanuel Lepage Vallee 0cb22fd203 awful: Move the backward compatibility code into its own file.
The reason for this is that as more of CAPI is brought in line with the
current API guidelines, it is more and more likely the tests will hit
APIs shims (either to test them or because the prototype remains the
same and only the implementation moved to Lua).
2019-10-05 18:06:50 -04:00
Emmanuel Lepage Vallee 96c4d001f1 doc: Remove capi.button/capi.key from the official doc.
`awful.button` is always the one used and it's confusing.
2019-10-05 18:06:50 -04:00
Emmanuel Lepage Vallee 585e321578 doc: Fix a regression from a recent commit.
There was an off-by-one in the substring for the parameter names.
2019-10-05 17:20:29 -04:00
Emmanuel Lepage Vallee 5de1e36007 doc: Use braces for names function arguments.
Use {} for all functions with take `args` as sole parameters instead
of (). Also color them differently to highlight this isn't a typo.
2019-10-01 02:03:12 -04:00
Emmanuel Lepage Vallee 8704b8d89a doc: Move the core components to the top of the doc index.
They are the most important, they should be the most visible.
2019-10-01 01:18:15 -04:00