Commit Graph

9879 Commits

Author SHA1 Message Date
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
mergify[bot] e3b15b4405
Merge pull request #2922 from Aire-One/doc_screen_images
Documentation `screen` - Improvement on generated images.
2019-11-26 15:22:55 +00:00
mergify[bot] 42ec9c4ecf
Merge pull request #2925 from SethBarberee/gears-iterate_value
More gears.table tests
2019-11-26 15:16:00 +00:00
Jordan Christiansen c09e5b16b7 Correct the name of get_children's return value (#2927)
get_children's return value should not be called "The". That was a
mistake because ldoc requires a name for return values and parameters.
If a name isn't provided, it thinks the first word of the description
is the name.
2019-11-25 17:04:01 -05:00
Jordan Christiansen f8a9c59d50 Improve textclock property docs (#2926)
* Add format docs to the constructor.
* Add timezone docs to the property.
* Give the argument to set_refresh a name other than "How".
* Fix bug in constructor argument "format" rendering.
2019-11-25 16:35:41 -05:00
Seth Barberee 5d499db3d0 add tests for find_keys and hasitem 2019-11-25 14:09:29 -06:00
Aire-One 3791daaeaf Add wibar drawing to screen properties images. 2019-11-22 14:40:21 +01:00
Aire-One 92f698bbae Add an option to draw the wibar on screen images.
Add a new option to the screen image template: `draw_wibar`.
This option draw the wibar on the generated image.
2019-11-22 14:40:21 +01:00
Aire-One 3830e9de35 Invert rulers insertion order.
Rulers insertion order impact the result of the bubble sort algorithm.
By inverting the order, we can make the output image looking more natural.

Awesome's screen properties can be seen like this:
* The screen has a geometry (its size) ;
* Inside there is the workarea ;
* Inside there is the tiling_area.

It seems better to draw rulers in this order.
2019-11-22 14:39:52 +01:00
mergify[bot] 76f8c11776
Merge pull request #2920 from jcrd/taglist-update
Update taglist more aggressively
2019-11-21 10:29:32 +00:00
James Reed 1e71d9afbd
Update taglist more aggressively 2019-11-20 10:52:55 -07:00
Emmanuel Lepage Vallée 9bc6d4aa40
Merge pull request #2894 from Elv13/xmas_2k18_2_merge_p3
API standardization part 2
2019-11-09 17:13:19 -05:00
Emmanuel Lepage Vallee ee331a4eff keygrabber: Remove the hardcoded way to add keybindings.
There is now a real API for this.
2019-11-09 16:43:53 -05:00
Emmanuel Lepage Vallee 944ef213e6 tests: Try both the `args` and parameters based `awful.{key,button}`. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 4723c3218a tests: Make sure the legacy buttons/keys method are converted back. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 12a7d026c2 tests: Test the new key/button binding API 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 10fd4e8883 object: Try harder to auto-undeprecate the keys and buttons.
Having the new object layout will be important soon when the
append/remove methods start to get added to the client and the
reborn `awful.keyboard` module.
2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee e3959b45d5 awful.button: Keep track of the `awful.button` in the `capi.button`. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 42a906f300 capi.button: Enable the miss handlers. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee fe603f7dc5 capi.key: Enable the miss handlers. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee afbb3b7faf shims: Add the legacy _keys and _buttons to the client shims. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee f4cfb99cde shims: Update the `button` and `key` shims to be objects.
Now that something actually tries to set the index handlers, it
cannot be a dumb function anymore.
2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 35a4b4edbf object: Allow old `gears.table.join` accessors to be set to `false`.
This worked before, so it has to work again.

Fixes #2915
2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 45823f230a capi: Move from `.data` to `._private` for the property data.
This will bring the CAPI classes closer to the gears.object ones.

Fixes #2897
2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 50eb7d5599 Revert "legacy: Temporary workaround for #2897. (#2898)"
This reverts commit e888d983ef.
2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 025262fd95 doc: Use the new doc convention.
The previous few commits are very old, bring them to the new
standards without all the merging conflicts (which are error prone).
2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 02486b3479 awful.key: Add a has_root_binding property and :trigger() method 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 4f7388dd17 awful.button: Add a has_root_binding property and :trigger() method 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 93b90026e9 root: Add a `has_key` and `has_button` functions. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 86d8ef3142 awful.button: Turn into an object. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 21ae9c1edb awful.key: Turn into an object. 2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 3b5db8a9be rc.lua: Add root keys and buttons instead of setting the list.
As visible in various modules and even built-in components like
`awful.keygrabber`, it was previously necessary to work around the
fact that keybindings could not be added later without using some
low level API hacks.

From now on, `rc.lua` will be a good citizen and use the same APIs as
the module to manage keybindings.
2019-11-09 16:43:12 -05:00
Emmanuel Lepage Vallee 4501f0e768 Allow to add and remove keys and buttons.
Another step in moving these APIs toward the common object oriented and
declarative paradigms used by other APIs.

This commit introduces the `awful.keyboard` module. It currenly only
exists as a placeholder for the first few append/remove function, but
will grow in scope in another pull request to expose the currently
private modifier APIs and to provide keybindings collision detection
and replace some of `awful.hotkey_popup` business logic.

The `keygrabber` tests which uses root keybindings are disabled for
now to keep the commit size small. This is necessary since the shims
will need many iterations of changes before this work again with the
new syntax.
2019-11-09 16:42:06 -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 Vallée 0297bfff9a
Merge pull request #2913 from actionless/add-vim-test-dep
doc(readme): add vim to test deps
2019-10-18 18:28:34 -04:00
actionless 68651477fb refactor(test: awesomerc: hotkeys): imitate fake vim client instead of depending on vim as test dep 2019-10-18 19:02:47 +02:00
actionless e048c4200c style(readme): remove dots at the end of the list items 2019-10-18 18:52:44 +02:00
actionless 0333cddfa2 doc(readme): add xterm to test deps 2019-10-18 18:50:43 +02:00
actionless e78d711846 doc(readme): add vim to test deps 2019-10-18 18:45:18 +02:00
mergify[bot] f6f5b461e3
Merge pull request #2910 from xinhaoyuan/pr-ewmh-merge_maximization
fix ewmh.merge_maximization
2019-10-18 16:41:18 +00:00
Xinhao Yuan 0e8dd4c1c9 Added more tests to check partial maximization handling, which require wmctrl as an optional dependency. 2019-10-17 18:54:29 -04:00
Xinhao Yuan 33570e45d7 Added a test to check if window state is restored after a client unmaximizing itself. 2019-10-16 18:23:21 -04:00
Xinhao Yuan 8beb0286ea Fix: toggling the `maximized` state properly when a client requests to unmaximize.
The fix focuses on ewmh.merge_maximization function, which handles client intentions to change maximization states.
The fix includes:

  1. Fixing the `get_value` helper function to return the proper resulting state that client wanted to change.
     For example, when `c.maximized and not c.maximized_horizontal and not c.maximized_vertical` holds,
     the client would observe the `MAXIMIZED_VERT` and `MAXIMIZED_HORZ` atoms in X11, but get_value would compute
     the result values based on `c.maximized_{horizontal,vertical}`, which are all false. The fix makes the computation
     consistent to clients' view.

  2. Interpret a client's maximization intentions based on the client's view of how the X11 atoms changes.
2019-10-16 18:23:18 -04:00
mergify[bot] 344964a44a
Merge pull request #2529 from actionless/hotkeys-popup-dont-show-empty-groups
fix(awful: hotkeys_popup): don't show group label if group itself is empty
2019-10-12 22:14:48 +00:00
mergify[bot] bafe028a05
Merge pull request #2905 from psychon/imagebox_raw_pointers
imagebox:set_widget(): Handle userdata again
2019-10-11 16:50:57 +00:00
Uli Schlachter 08e230b1b3 imagebox:set_widget(): Handle userdata again
This function is not documented to handle userdata, but historically it
would just pass all arguments to gears.surface.load(), which interpreted
userdata as cairo surfaces. After 3295e9f33d, userdata
objects are restricted.

Accept userdata objects again by explicitly passing them to
gears.surface.load().

Fixes: https://github.com/awesomeWM/awesome/issues/2903
Signed-off-by: Uli Schlachter <psychon@znc.in>
2019-10-11 16:14:57 +02:00
actionless 0374bf1b1b test(awful: hotkeys_popup): test pagination and app-specific hotkeys (on vim example) 2019-10-11 15:33:43 +02:00