Commit graph

170 commits

Author SHA1 Message Date
elkowar
c0d9b53004
Add regex replace and function call docs 2021-05-14 11:55:08 +02:00
elkowar
54f6713ffe
fix function call parsing 2021-05-14 11:40:41 +02:00
elkowar
457da0aaf5
Add proper floating point digit parser 2021-05-13 21:07:20 +02:00
elkowar
7d525cbaa6
add function call syntax 2021-05-13 20:47:39 +02:00
legendofmiracles
df5793b204
Predefined variables/Magic vars (#117)
* basic idea

* generates docs

* hardcoded the gen script

* trying to hide magic vars

* eww-state is good now

* structure for cpu var is now there

* renamed cpu to diskstat, bc lib supports it after all

* not going to implement disk IO. go back to this commit, to see a rough idea

* removed it

* formatting

* stopped data race

* Update src/config/system_stats/ram.rs

Co-authored-by: ElKowar <5300871+elkowar@users.noreply.github.com>

* Update src/config/system_stats/disk.rs

Co-authored-by: ElKowar <5300871+elkowar@users.noreply.github.com>

* Explains macos better

* Update battery.rs

* Function for each OS when getting battery, a bit cleaner

* reworked battery a little

* all in one big file

* facepalm

* cleaner gen script and one huge file for the system stat stuff

* merge conflicts

* github interface for resolving merge conflicts sucks, this fixes it

* Apply suggestions from code review

Co-authored-by: ElKowar <5300871+elkowar@users.noreply.github.com>

* Update src/config/inbuilt.rs

Co-authored-by: ElKowar <5300871+elkowar@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: ElKowar <5300871+elkowar@users.noreply.github.com>

* code suggestions

* component temperature is a json struct

* newlines in magic vars descriptions

* disks is now json, numbers are not wrapped in strings, and more idiomatic code

* Update gen-docs.ts

Co-authored-by: mlvzk <mlvzk@protonmail.com>

* removes a unneeded heading

* more doc updates and EWW_CPU_USAGE is now json

* calculates battery total avg and it's a json struct

Co-authored-by: ElKowar <5300871+elkowar@users.noreply.github.com>
Co-authored-by: mlvzk <mlvzk@protonmail.com>
2021-05-11 18:45:29 +02:00
elkowar
6eea3e039d
Add cursor property to widgets (fixes #66) 2021-05-09 17:04:29 +02:00
ElKowar
fa70a71a1a
Readjust window position when size changes (fixes #113) (#163) 2021-05-09 15:58:00 +02:00
elkowar
fa99408d35
Remove unused imports 2021-05-09 14:53:44 +02:00
elkowar
29c741466e
Add regex test to expression language (fixes #162) 2021-05-09 14:52:51 +02:00
elkowar
b1cb74d386
Add onmiddleclick and onrightclick to button 2021-05-09 13:57:24 +02:00
contribuewwt
3b60b64c34
Modifications to hot reload (#141)
* Hot reload

* Add wayland and no-x11-wayland build to CI

* Fix no-x11-wayland build (#160)

* test-commit

* Update workflow

* add cache to rust build

* Fix wayland build

* Fix no-x11-wayland build

* Use new version of pkg and do big think about how make async

* forgot to autofmt

* updates

* Hot reload

* Use new version of pkg and do big think about how make async

* forgot to autofmt

* updates

* requested changes + autoformat again

Co-authored-by: elkowar <5300871+elkowar@users.noreply.github.com>
2021-05-06 19:43:50 +02:00
ElKowar
907f39cf86
Fix no-x11-wayland build (#160)
* test-commit

* Update workflow

* add cache to rust build

* Fix wayland build

* Fix no-x11-wayland build
2021-05-04 10:09:41 +02:00
snakedye
661c29f1d2
correcting docs and removing unused Sides (#159)
Co-authored-by: Bryan Ndjeutcha <ndjeutcha@gmail.com>
2021-05-03 23:33:13 +02:00
elkowar
a1a313be70
Fix clippy lints 2021-05-03 23:29:58 +02:00
snakedye
9ea20cd753
Proper wayland support (#125)
* Initial commit for wayland support

* Improvements to Wayland backend, structs and enums

* gtk-layer-shell-rs imported

* Eww compiles with wayland backend

* Full layershell support

* Compatibility with x11 backend

* updated docs and better compatibily with X config

* error in example

* "screen" in config works

* Updated documentation

* bar example for wayland

* eww follow focus when screen is undefined

* NumWithUnit

* Removed SurfaceDefinition for StrutDefinition
again...

* cargo fmt

* fix match statement for screen number

* fix focusable / kb interactivity

* revision #2

* fix: compile error and example

* feat: I fixed the deps
X11 doesn't compile because of some x11 fuckery

* fix: x11 fuckery
PR NOW REEEEEEEEEEEEEEEEEEEEEEEEE

* fix conflics and cargo fmt

* i can't read

* conflicts: a never ending loop...

* dammit ptr

* conflicts: Cargo.lock

* Expression language (#124)

* Add AST

* add make-shift testing parser, and make stuff ocmpile

* add proper expression parser

* make string format use '

* Add empty doc page for expressions

* add tests

* Clean up file structure and add unary operators

* Write documentation

* make multiple daemons possible and make commands time out

* Add EwwPaths struct and refactor path handling in general

* Update docs to include <reserve>

* Improve handling of paths and daemon-ids

* Add elvis operator

* Allow literal-tag content to use user-defined widgets

* Add support for overriding monitor in CLI

* change formatting config

* Improve error messages for non-existant config dir

* Added tooltips (#127)

* update dependencies

* Explicetely states where to look for installing eww (#131)

I think this should be added, because we already had a couple of people opening issues because they didn't read the docs on how to install eww.

* (Very) Rudimentry gif support (#143)

* rudimentry gif support

* revert main.rs

* Fix variable reference detection, should fix #144

* cleanup TextPos in eww debug

* Manually resolve escaped symbols in xml.

This shouldn't be necesary.
Fixes #154 and fixes #147

* Add JSON support for exprs (fixes #146)

* Add docs for json values and make value related names shorter

* Add animated icon

* Initial commit for wayland support

* Improvements to Wayland backend, structs and enums

* gtk-layer-shell-rs imported

* Eww compiles with wayland backend

* Full layershell support

* Compatibility with x11 backend

* updated docs and better compatibily with X config

* "screen" in config works

* Updated documentation

* eww follow focus when screen is undefined

* Removed SurfaceDefinition for StrutDefinition
again...

* cargo fmt

* fix match statement for screen number

* fix focusable / kb interactivity

* revision #2

* fix: compile error and example

* feat: I fixed the deps
X11 doesn't compile because of some x11 fuckery

* fix conflics and cargo fmt

* i can't read

* conflicts: a never ending loop...

* dammit ptr

* conflicts: Cargo.lock

* yeeting git syntax

* trying to resolve conflicts

* yeeting Cargo.lock...

* i try

* revision: removing duplicates

* fix geometry, example and improving docs

* clearing up the documentation

* I forgot the scss file.
I also edited the bar to take advantage of eww expressions.

* more yeeting and moved exclusive to window

Co-authored-by: Bryan Ndjeutcha <ndjeutcha@gmail.com>
Co-authored-by: ElKowar <5300871+elkowar@users.noreply.github.com>
Co-authored-by: undefinedDarkness <38278035+undefinedDarkness@users.noreply.github.com>
Co-authored-by: legendofmiracles <30902201+legendofmiracles@users.noreply.github.com>
2021-05-03 21:14:34 +02:00
elkowar
aaac4c3b43 Add docs for json values and make value related names shorter 2021-04-14 14:28:22 +02:00
elkowar
ce4c22e2a6 Add JSON support for exprs (fixes #146) 2021-04-14 14:18:08 +02:00
elkowar
72457aaa11 Manually resolve escaped symbols in xml.
This shouldn't be necesary.
Fixes #154 and fixes #147
2021-04-14 12:47:20 +02:00
elkowar
b9c9e67c2e cleanup TextPos in eww debug 2021-04-14 12:20:33 +02:00
elkowar
11f595be2c Fix variable reference detection, should fix #144 2021-04-04 00:06:34 +02:00
contribuewwt
8436b666c2
(Very) Rudimentry gif support (#143)
* rudimentry gif support

* revert main.rs
2021-03-28 23:16:47 +02:00
elkowar
eb804ae346 update dependencies 2021-03-23 11:14:06 +01:00
undefinedDarkness
c4cbdedec5
Added tooltips (#127) 2021-03-08 22:32:33 +01:00
elkowar
30305cd506 Improve error messages for non-existant config dir 2021-03-08 22:31:53 +01:00
elkowar
f544d0e19a change formatting config 2021-03-08 22:28:29 +01:00
elkowar
5cf18bfc43 Add support for overriding monitor in CLI 2021-03-02 17:55:48 +01:00
elkowar
0c762de864 Allow literal-tag content to use user-defined widgets 2021-03-02 17:24:14 +01:00
elkowar
c37c5b3cf3 Add elvis operator 2021-03-02 14:52:51 +01:00
elkowar
f2c0e06997 Improve handling of paths and daemon-ids 2021-03-02 13:50:50 +01:00
elkowar
8dba5aca83 Add EwwPaths struct and refactor path handling in general 2021-03-02 13:12:52 +01:00
elkowar
5b3344fc5b make multiple daemons possible and make commands time out 2021-03-02 12:23:18 +01:00
ElKowar
9a8bbf4114
Expression language (#124)
* Add AST

* add make-shift testing parser, and make stuff ocmpile

* add proper expression parser

* make string format use '

* Add empty doc page for expressions

* add tests

* Clean up file structure and add unary operators

* Write documentation
2021-03-02 10:27:52 +01:00
ElKowar
a18901f187
State refactor (#121)
* Add widget_node trait and generic impl

* Use WidgetNode stuff in some places

* Use WidgetNode stuff in rendering code

* Refactor
2021-02-26 21:03:53 +01:00
undefinedDarkness
6251a2bc1d
Checkboxes (#119)
* Add -c / --config argument to eww daemon

* Fix for requested changes

* removed comment

* Added checkbox

* cargo fmt
2021-02-26 20:58:10 +01:00
elkowar
2120e76a5c Add box to logs 2021-02-17 17:01:07 +01:00
elkowar
ce2ce250e4 Fix compilation on non-x11 2021-02-17 16:50:48 +01:00
elkowar
e9af869a0a Not use inotify on non-linux compile targets 2021-02-17 16:45:57 +01:00
elkowar
9238688774 Implement struts 2021-02-17 16:42:54 +01:00
elkowar
ab26c1ea81 Add progressbar widget 2021-02-12 20:30:55 +01:00
undefinedDarkness
4da676e38b
SCSS relative path support, set cwd of server to eww config directory (#110) 2021-02-08 10:46:33 +01:00
elkowar
d2fa79f050 Make --debug a global flag 2021-02-07 20:31:39 +01:00
Axarva
827d47b26e
Provide an example configuration (with space for more!) (#99) 2021-02-05 21:51:06 +01:00
undefinedDarkness
66bfe25d87
Add -c / --config argument to eww daemon (#104) 2021-02-02 19:59:30 +01:00
elkowar
ebb8fc065d Run poll-vars immediately when starting (fixes #98) 2021-01-31 16:20:19 +01:00
legendofmiracles
7648a400c3
Shows warnings when defining variables that are already defined, and other general improvements (#105)
* refactored everything into a function, and checks the larger/smaller one

* general improvements

* Simplify code

Co-authored-by: elkowar <5300871+elkowar@users.noreply.github.com>
2021-01-31 16:11:52 +01:00
elkowar
090165eb8c Cleanup config include code and error handling 2021-01-31 15:09:45 +01:00
elkowar
47863a3e77 Add eww reload command 2021-01-21 21:47:40 +01:00
elkowar
8530f90a7c Add eww windows command and restructure daemon response.
Daemon response is now a dedicated type that contains information
about failure / success, and used in more commands, such as `open` and
`close`. Thus, this fixes #90 and also fixes #89.

For #90, the decision has been made to not make this independent of the
daemon, as that makes it possible to provide more information, and
because in most cases, users will have the daemon running when checking
windows anyways.
2021-01-16 18:09:35 +01:00
elkowar
ff756da2c5 Exit 1 on daemon connection failure 2021-01-16 16:39:17 +01:00
elkowar
6c2e0dbbc1 Fix script-vars being ran without window using them, and add debug flag. fixes #94. 2021-01-16 16:14:03 +01:00