feat(animation): add animation on geometry change

This commit is contained in:
doryan 2024-11-03 18:13:37 +04:00
parent 304cb8ef5f
commit 4b56e3c494

View File

@ -120,7 +120,7 @@ fade-delta = 10
# Sets the radius of rounded window corners. When > 0, the compositor will
# round the corners of windows. Does not interact well with
# `transparent-clipping`.
corner-radius = 5;
corner-radius = 0;
# Exclude conditions for rounded corners.
#rounded-corners-exclude = [
@ -142,16 +142,17 @@ corner-radius = 5;
# Specify the backend to use: `xrender`, `glx`, `egl` or `xr_glx_hybrid`.
# `xrender` is the default one.
#
# Available backends "xrender" "glx" "egl"
backend = "glx"
dithered-present = false;
dithered-present = true;
vsync = true;
detect-rounded-corners = true;
detect-client-opacity = true;
detect-transient = true;
detect-client-leader = true
glx-no-stencil = true
glx-no-rebind-pixmap = false
use-damage = true;
xrender-sync-fence = false
log-level = "warn";
rules = ({
match = "WM_TRANSIENT_FOR@";
@ -192,7 +193,7 @@ rules = ({
blur-opacity = 0;
shadow-opacity = "opacity";
scale-y = {
curve = "cubic-bezier(0.21, 0.02, 0.76, 0.36)";
curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
duration = 0.15;
start = 1;
end = 0.7;
@ -240,7 +241,7 @@ rules = ({
blur-opacity = 0;
shadow-opacity = "opacity";
scale-y = {
curve = "cubic-bezier(0.21, 0.02, 0.76, 0.36)";
curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
duration = 0.15;
start = 1;
end = 0.7;
@ -305,7 +306,7 @@ animations = ({
offset-x = "(1 - scale-x) / 2 * window-width";
offset-y = "(1 - scale-y) / 2 * window-height";
scale-x = {
curve = "cubic-bezier(0.21, 0.02, 0.76, 0.36)";
curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
duration = 0.15;
start = 1;
end = 0.9;
@ -350,13 +351,13 @@ animations = ({
{
triggers = ["workspace-out"];
offset-y = {
curve = "cubic-bezier(0.21, 0.02, 0.76, 0.36)";
curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
duration = 0.15;
start = "0";
end = "- window-height / 2";
};
scale-x = {
curve = "cubic-bezier(0.21, 0.02, 0.76, 0.36)";
curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
duration = 0.10;
start = "0";
end = "- window-height / 2";
@ -374,7 +375,7 @@ animations = ({
}, {
triggers = ["workspace-out-inverse"];
offset-y = {
curve = "cubic-bezier(0.21, 0.02, 0.76, 0.36)";
curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
duration = 0.15;
start = "0";
end = "window-height / 2";
@ -434,13 +435,72 @@ animations = ({
end = "window-raw-opacity";
};
shadow-opacity = "opacity";
},{
triggers = ["geometry"]
scale-x = {
curve = "cubic-bezier(0.16, 1, 0.3, 1)";
duration = 0.2;
start = "window-width-before / window-width";
end = 1;
}
scale-y = {
curve = "cubic-bezier(0.16, 1, 0.3, 1)";
duration = 0.2;
start = "window-height-before / window-height";
end = 1;
}
offset-x = {
curve = "cubic-bezier(0.16, 1, 0.3, 1)";
duration = 0.2;
start = "window-x-before - window-x";
end = 0;
}
offset-y = {
curve = "cubic-bezier(0.16, 1, 0.3, 1)";
duration = 0.2;
start = "window-y-before - window-y";
end = 0;
}
saved-image-blend = 0;
shadow-scale-x = "scale-x";
shadow-scale-y = "scale-y";
shadow-offset-x = "offset-x";
shadow-offset-y = "offset-y";
}
# {
# triggers = [ "geometry" ];
# scale-x = {
# curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
# duration = 0.25;
# start = "window-width-before / window-width";
# end = 1;
# }
# scale-y = {
# curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
# duration = 0.25;
# start = "window-height-before / window-height";
# end = 1;
# }
# offset-x = {
# curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
# duration = 0.25;
# start = "window-x-before - window-x";
# end = "0";
# }
# offset-y = {
# curve = "cubic-bezier(0.25, 0.05, 0.28, 1)";
# duration = 0.25;
# start = "window-y-before - window-y";
# end = "0";
# }
# }
# Full Opaque Desktop Switch
#{
# triggers = ["workspace-out"];
# offset-y = {
# timing = "0.15s cubic-bezier(0.21, 0.02, 0.76, 0.36)";
# timing = "0.15s cubic-bezier(0.25, 0.05, 0.28, 1)";
# start = "0";
# end = "-window-monitor-height";
# };
@ -455,7 +515,7 @@ animations = ({
#}, {
# triggers = ["workspace-out-inverse"];
# offset-y = {
# timing = "0.15s cubic-bezier(0.21, 0.02, 0.76, 0.36)";
# timing = "0.15s cubic-bezier(0.25, 0.05, 0.28, 1)";
# start = "0";
# end = "window-monitor-height";
# };