2014-04-29 06:25:19 +00:00
|
|
|
# KI18N Translation Domain for this library
|
2015-01-28 08:46:31 +00:00
|
|
|
add_definitions(-DTRANSLATION_DOMAIN=\"kwin_effects\" -DEFFECT_BUILTINS)
|
2014-04-29 06:25:19 +00:00
|
|
|
|
2014-04-16 12:27:48 +00:00
|
|
|
include_directories(${KWIN_SOURCE_DIR}) # for xcbutils.h
|
|
|
|
|
2013-02-25 11:05:36 +00:00
|
|
|
set(kwin_effect_OWN_LIBS
|
|
|
|
kwineffects
|
|
|
|
)
|
|
|
|
|
2014-03-16 14:31:23 +00:00
|
|
|
if( KWIN_HAVE_XRENDER_COMPOSITING )
|
|
|
|
set(kwin_effect_OWN_LIBS ${kwin_effect_OWN_LIBS} kwinxrenderutils)
|
|
|
|
endif()
|
|
|
|
|
2013-02-25 11:05:36 +00:00
|
|
|
set(kwin_effect_KDE_LIBS
|
2014-03-24 12:02:48 +00:00
|
|
|
KF5::ConfigGui
|
2013-12-11 20:41:47 +00:00
|
|
|
KF5::ConfigWidgets
|
2013-12-09 08:33:58 +00:00
|
|
|
KF5::GlobalAccel
|
2013-12-11 20:41:47 +00:00
|
|
|
KF5::I18n
|
|
|
|
KF5::WindowSystem
|
2013-10-15 23:36:24 +00:00
|
|
|
KF5::Plasma # screenedge effect
|
2013-12-11 20:41:47 +00:00
|
|
|
KF5::IconThemes
|
|
|
|
KF5::Service
|
2016-11-16 08:50:18 +00:00
|
|
|
KF5::Notifications # screenshot effect
|
2013-03-11 08:33:38 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
set(kwin_effect_QT_LIBS
|
2013-10-02 13:23:56 +00:00
|
|
|
Qt5::Concurrent
|
2013-08-20 07:10:18 +00:00
|
|
|
Qt5::DBus
|
|
|
|
Qt5::Quick
|
|
|
|
Qt5::X11Extras
|
2013-02-25 11:05:36 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
set(kwin_effect_XLIB_LIBS
|
2013-03-04 07:50:23 +00:00
|
|
|
${X11_X11_LIB}
|
2013-02-25 11:05:36 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
set(kwin_effect_XCB_LIBS
|
2014-02-25 14:48:39 +00:00
|
|
|
XCB::XCB
|
|
|
|
XCB::IMAGE
|
|
|
|
XCB::XFIXES
|
2013-02-25 11:05:36 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
if( KWIN_HAVE_XRENDER_COMPOSITING )
|
2014-02-25 14:48:39 +00:00
|
|
|
set(kwin_effect_XCB_LIBS ${kwin_effect_XCB_LIBS} XCB::RENDER)
|
2013-02-25 11:05:36 +00:00
|
|
|
endif()
|
|
|
|
|
2015-10-30 12:47:37 +00:00
|
|
|
set(kwin_effect_OWN_LIBS ${kwin_effect_OWN_LIBS} kwinglutils)
|
2013-02-25 11:05:36 +00:00
|
|
|
|
2011-07-17 15:27:14 +00:00
|
|
|
macro( KWIN4_ADD_EFFECT_BACKEND name )
|
2014-01-17 12:46:04 +00:00
|
|
|
add_library( ${name} SHARED ${ARGN} )
|
2014-03-16 14:49:44 +00:00
|
|
|
target_link_libraries( ${name} PRIVATE ${kwin_effect_OWN_LIBS} ${kwin_effect_KDE_LIBS} ${kwin_effect_QT_LIBS} ${kwin_effect_XLIB_LIBS} ${kwin_effect_XCB_LIBS})
|
2013-02-25 10:44:26 +00:00
|
|
|
endmacro()
|
2007-11-02 17:28:21 +00:00
|
|
|
|
2007-04-29 17:35:43 +00:00
|
|
|
# Adds effect plugin with given name. Sources are given after the name
|
2009-02-05 15:35:38 +00:00
|
|
|
macro( KWIN4_ADD_EFFECT name )
|
2013-11-15 12:37:47 +00:00
|
|
|
kwin4_add_effect_backend(kwin4_effect_${name} ${ARGN})
|
2014-01-17 12:46:04 +00:00
|
|
|
|
|
|
|
set_target_properties(kwin4_effect_${name} PROPERTIES VERSION 1.0.0 SOVERSION 1 )
|
2013-10-14 07:04:03 +00:00
|
|
|
set_target_properties(kwin4_effect_${name} PROPERTIES OUTPUT_NAME ${KWIN_NAME}4_effect_${name})
|
2014-01-17 12:46:04 +00:00
|
|
|
install(TARGETS kwin4_effect_${name} ${INSTALL_TARGETS_DEFAULT_ARGS} )
|
2011-07-17 15:27:14 +00:00
|
|
|
|
2013-02-25 10:44:26 +00:00
|
|
|
endmacro()
|
2009-02-05 15:35:38 +00:00
|
|
|
|
|
|
|
# Install the KWin/Effect service type
|
|
|
|
install( FILES kwineffect.desktop DESTINATION ${SERVICETYPES_INSTALL_DIR} )
|
2007-05-22 16:58:10 +00:00
|
|
|
|
2009-02-05 15:35:38 +00:00
|
|
|
# Create initial variables
|
|
|
|
set( kwin4_effect_include_directories )
|
2007-04-29 17:35:43 +00:00
|
|
|
|
2014-03-17 13:56:11 +00:00
|
|
|
set( kwin4_effect_builtins_sources
|
|
|
|
logging.cpp
|
|
|
|
effect_builtins.cpp
|
|
|
|
blur/blur.cpp
|
|
|
|
blur/blurshader.cpp
|
2016-11-24 07:07:51 +00:00
|
|
|
colorpicker/colorpicker.cpp
|
2014-03-17 13:56:11 +00:00
|
|
|
cube/cube.cpp
|
|
|
|
cube/cube_proxy.cpp
|
2018-09-24 06:36:11 +00:00
|
|
|
cubeslide/cubeslide.cpp
|
2014-03-17 13:56:11 +00:00
|
|
|
coverswitch/coverswitch.cpp
|
|
|
|
desktopgrid/desktopgrid.cpp
|
|
|
|
diminactive/diminactive.cpp
|
|
|
|
flipswitch/flipswitch.cpp
|
|
|
|
glide/glide.cpp
|
|
|
|
invert/invert.cpp
|
|
|
|
lookingglass/lookingglass.cpp
|
|
|
|
magiclamp/magiclamp.cpp
|
|
|
|
magnifier/magnifier.cpp
|
|
|
|
mouseclick/mouseclick.cpp
|
|
|
|
mousemark/mousemark.cpp
|
|
|
|
presentwindows/presentwindows.cpp
|
|
|
|
presentwindows/presentwindows_proxy.cpp
|
|
|
|
resize/resize.cpp
|
|
|
|
showfps/showfps.cpp
|
[effects/showpaint] Use a shortcut to toggle the effect
Summary:
The Show Paint effect is useful when debugging repaint regions issued by
effects. The only headache with it is necessity to enable/disable it.
Consider the following workflow:
* Do some change to an effect;
* Compile KWin (or the effect);
* Go to System Settings and enable the Show Paint effect;
* Test effect, check repaint regions, etc;
* Disable the Show Paint effect;
* Go to the step 1.
This workflow is really exhausting. Also, when testing repaints in a
nested compositor, things become quite messy.
Because purpose of this effect is to debug repaints (and because this
effect is not meant for daily usage), I think that's fine to change
how it's activated.
This patch improves the workflow by changing the way how this effect
gets activated. Instead of enabling/disabling it, one can just use a shortcut
to activate or deactivate the effect.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: broulik, davidedmundson, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D15703
2018-09-23 07:49:17 +00:00
|
|
|
showpaint/showpaint.cpp
|
2017-12-30 17:17:13 +00:00
|
|
|
slide/slide.cpp
|
2014-03-17 13:56:11 +00:00
|
|
|
thumbnailaside/thumbnailaside.cpp
|
2016-08-16 18:16:41 +00:00
|
|
|
touchpoints/touchpoints.cpp
|
2014-03-17 13:56:11 +00:00
|
|
|
trackmouse/trackmouse.cpp
|
|
|
|
windowgeometry/windowgeometry.cpp
|
|
|
|
wobblywindows/wobblywindows.cpp
|
|
|
|
zoom/zoom.cpp
|
|
|
|
)
|
|
|
|
|
2016-01-26 14:38:42 +00:00
|
|
|
qt5_add_resources( kwin4_effect_builtins_sources shaders.qrc )
|
|
|
|
|
2014-03-17 13:56:11 +00:00
|
|
|
kconfig_add_kcfg_files(kwin4_effect_builtins_sources
|
|
|
|
blur/blurconfig.kcfgc
|
|
|
|
cube/cubeconfig.kcfgc
|
2018-09-24 06:36:11 +00:00
|
|
|
cubeslide/cubeslideconfig.kcfgc
|
2014-03-17 13:56:11 +00:00
|
|
|
coverswitch/coverswitchconfig.kcfgc
|
|
|
|
desktopgrid/desktopgridconfig.kcfgc
|
|
|
|
diminactive/diminactiveconfig.kcfgc
|
2016-11-16 07:13:38 +00:00
|
|
|
fallapart/fallapartconfig.kcfgc
|
2014-03-17 13:56:11 +00:00
|
|
|
flipswitch/flipswitchconfig.kcfgc
|
|
|
|
glide/glideconfig.kcfgc
|
|
|
|
lookingglass/lookingglassconfig.kcfgc
|
|
|
|
magiclamp/magiclampconfig.kcfgc
|
|
|
|
magnifier/magnifierconfig.kcfgc
|
|
|
|
mouseclick/mouseclickconfig.kcfgc
|
|
|
|
mousemark/mousemarkconfig.kcfgc
|
|
|
|
presentwindows/presentwindowsconfig.kcfgc
|
|
|
|
resize/resizeconfig.kcfgc
|
|
|
|
showfps/showfpsconfig.kcfgc
|
2017-12-30 17:17:13 +00:00
|
|
|
slide/slideconfig.kcfgc
|
2016-11-16 08:02:44 +00:00
|
|
|
slidingpopups/slidingpopupsconfig.kcfgc
|
2014-03-17 13:56:11 +00:00
|
|
|
thumbnailaside/thumbnailasideconfig.kcfgc
|
|
|
|
trackmouse/trackmouseconfig.kcfgc
|
|
|
|
windowgeometry/windowgeometryconfig.kcfgc
|
|
|
|
wobblywindows/wobblywindowsconfig.kcfgc
|
|
|
|
zoom/zoomconfig.kcfgc
|
|
|
|
)
|
|
|
|
|
2012-02-02 13:39:39 +00:00
|
|
|
# scripted effects
|
2013-06-03 13:05:22 +00:00
|
|
|
add_subdirectory( dialogparent )
|
2018-10-25 13:48:47 +00:00
|
|
|
add_subdirectory( dimscreen )
|
2015-03-30 09:38:54 +00:00
|
|
|
add_subdirectory( eyeonscreen )
|
2012-02-02 13:39:39 +00:00
|
|
|
add_subdirectory( fade )
|
2014-03-03 10:20:03 +00:00
|
|
|
add_subdirectory( fadedesktop )
|
[effects] Split the Fade effect
Summary:
Currently, we have three effects that can be used to animate the
appearing of toplevel windows(fade, glide, scale) and one can enable
all three of them, which seems to be wrong. It doesn't make sense to have
glide and scale effect enabled, for example.
We couldn't put all three effects into an exclusive group before because
the fade effect animates not only toplevel windows but also popups. So,
if all three effects are in an exclusive group and you enable glide effect,
for example, then tooltips and other popups won't be faded in/out.
This patch splits the fade effect into two: the first effect (called Fade)
animates toplevel windows and the other one (called Fading Popups) animates
popup windows.
Test Plan:
Have been using the Fading Popups effect in combination with the Scale
effect for a couple of days. Haven't noticed any significant differences between
the new combination (Fading Popups + Scale) and the old combination
(Fade + Scale).
Reviewers: #kwin, #plasma, #vdg, graesslin
Reviewed By: #kwin, #plasma, graesslin
Subscribers: graesslin, abetts, ngraham, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D16836
2018-11-03 15:42:31 +00:00
|
|
|
add_subdirectory( fadingpopups )
|
2017-04-05 09:16:23 +00:00
|
|
|
add_subdirectory( frozenapp )
|
2013-01-14 07:38:18 +00:00
|
|
|
add_subdirectory( login )
|
2017-03-15 16:47:13 +00:00
|
|
|
add_subdirectory( logout )
|
2014-03-03 10:20:03 +00:00
|
|
|
add_subdirectory( maximize )
|
2016-02-16 15:44:41 +00:00
|
|
|
add_subdirectory( morphingpopups )
|
2018-10-27 21:27:25 +00:00
|
|
|
add_subdirectory( scale )
|
[effects] Re-implement the Minimize Animation effect in JavaScript
Summary:
There were several reasons to rewrite the Minimize Animation effect in
JavaScript: to simplify code and to get rid of full repaints. One could
say that nothing prevents us from calculating the dirty region in
postPaintScreen or postPaintWindow and it is correct, but with the
scripting effects API the dirty region will be calculated for us, so we
can focus more on "what we want" instead of "how".
Visually, the "old" effect and the rewritten one look quite the same.
Except one tiny bit: if a window doesn't have an icon in the task manager,
it won't be animated. The reason for that is the purpose of this effect is
to show where the window will be after it's minimized, if the window
doesn't have icon in the task manager, one can't click at the center of
the screen to unminimize the window.
There is one significant change, the name of the effect was changed to
"Squash". If we put this effect and the Magic lamp effect under "Window
Minimize Animation" category (or if we add some "heading" label), then
the old name and the name of the category would "conflict". The new name
was suggested by Nate Graham and it very closely describes what the
effect does. "Scale" doesn't fit this effect because while a window is
being animated, its aspect ratio is not preserved.
Reviewers: #kwin, #plasma, davidedmundson
Reviewed By: #kwin, #plasma, davidedmundson
Subscribers: davidedmundson, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D16372
2018-09-23 17:07:48 +00:00
|
|
|
add_subdirectory( squash )
|
2014-03-03 10:20:03 +00:00
|
|
|
add_subdirectory( translucency )
|
2015-03-28 23:15:57 +00:00
|
|
|
add_subdirectory( windowaperture )
|
2012-02-02 16:58:31 +00:00
|
|
|
|
2009-02-05 15:35:38 +00:00
|
|
|
###############################################################################
|
|
|
|
# Built-in effects go here
|
|
|
|
|
|
|
|
# Common effects
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( desktopgrid )
|
|
|
|
add_subdirectory( diminactive )
|
2014-03-03 10:20:03 +00:00
|
|
|
include( fallapart/CMakeLists.txt )
|
|
|
|
include( highlightwindow/CMakeLists.txt )
|
2013-05-27 08:45:22 +00:00
|
|
|
include( kscreen/CMakeLists.txt )
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( magiclamp )
|
|
|
|
add_subdirectory( presentwindows )
|
|
|
|
add_subdirectory( resize )
|
2013-01-31 12:31:49 +00:00
|
|
|
include( screenedge/CMakeLists.txt )
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( showfps )
|
[effects/showpaint] Use a shortcut to toggle the effect
Summary:
The Show Paint effect is useful when debugging repaint regions issued by
effects. The only headache with it is necessity to enable/disable it.
Consider the following workflow:
* Do some change to an effect;
* Compile KWin (or the effect);
* Go to System Settings and enable the Show Paint effect;
* Test effect, check repaint regions, etc;
* Disable the Show Paint effect;
* Go to the step 1.
This workflow is really exhausting. Also, when testing repaints in a
nested compositor, things become quite messy.
Because purpose of this effect is to debug repaints (and because this
effect is not meant for daily usage), I think that's fine to change
how it's activated.
This patch improves the workflow by changing the way how this effect
gets activated. Instead of enabling/disabling it, one can just use a shortcut
to activate or deactivate the effect.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: broulik, davidedmundson, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D15703
2018-09-23 07:49:17 +00:00
|
|
|
add_subdirectory( showpaint )
|
2017-12-30 17:17:13 +00:00
|
|
|
add_subdirectory( slide )
|
2014-03-03 10:20:03 +00:00
|
|
|
include( slideback/CMakeLists.txt )
|
2009-07-23 19:06:50 +00:00
|
|
|
include( slidingpopups/CMakeLists.txt )
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( thumbnailaside )
|
|
|
|
add_subdirectory( windowgeometry )
|
|
|
|
add_subdirectory( zoom )
|
2007-10-21 13:44:40 +00:00
|
|
|
|
2009-02-05 15:35:38 +00:00
|
|
|
# OpenGL-specific effects
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( blur )
|
2013-12-01 19:28:57 +00:00
|
|
|
include( backgroundcontrast/CMakeLists.txt )
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( coverswitch )
|
|
|
|
add_subdirectory( cube )
|
2018-09-24 06:36:11 +00:00
|
|
|
add_subdirectory( cubeslide )
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( flipswitch )
|
|
|
|
add_subdirectory( glide )
|
|
|
|
add_subdirectory( invert )
|
|
|
|
add_subdirectory( lookingglass )
|
|
|
|
add_subdirectory( magnifier )
|
|
|
|
add_subdirectory( mouseclick )
|
|
|
|
add_subdirectory( mousemark )
|
2011-08-13 13:21:51 +00:00
|
|
|
include( screenshot/CMakeLists.txt )
|
2014-03-03 10:20:03 +00:00
|
|
|
include( sheet/CMakeLists.txt )
|
|
|
|
include( snaphelper/CMakeLists.txt )
|
|
|
|
include( startupfeedback/CMakeLists.txt )
|
2014-03-17 13:56:11 +00:00
|
|
|
add_subdirectory( trackmouse )
|
|
|
|
add_subdirectory( wobblywindows )
|
2007-04-29 17:35:43 +00:00
|
|
|
|
2009-02-05 15:35:38 +00:00
|
|
|
###############################################################################
|
2007-04-29 17:35:43 +00:00
|
|
|
|
2009-02-05 15:35:38 +00:00
|
|
|
# Add the builtins plugin
|
2013-11-15 12:37:47 +00:00
|
|
|
kwin4_add_effect( builtins ${kwin4_effect_builtins_sources} )
|