Reply to topic

Plasma Activities - documenting newbie setup

rafaelp
Registered Member
Posts
2
Karma
0
Hi
I just spent a few hours trying to understand and tweaking a basic KDE setup with activities.
I could not find much basic up-to-date info on activities for beginners , so I thought I could share some of what I learned in case it is useful for others and to elicit tips and suggestions.

I try to document my sample setup and findings below.

# System:
* Kubuntu 18.04
* KDE Plasma: 5.12.7
* Frameworks: 5.44.0
* Qt: 5.9.5
* Kernel: 4.15.0
* Apps:in the latest version in the Kubuntu distribution as of this date

# Goals:
1. Have two activities , "Default" and "Prog" (for programming). Each with a set of applications (possibly overlapping) that are opened automatically when I boot, with the actual files or settings saved from a previous session.
2. Mapping apps to activities: in principle it should be automatic. Apps to run (and stay) in the activity from which they are launched

# Activities
## "Default" Activity :
* Browser (in principle Vivaldi)
* Thunderbird Mail
* SimpleNote (*)
* Kate
* LibreOffice Apps (mainly Calc)

## "Prog" Activity:
* Browser (in principle Vivaldi)
* Visual Studio Code
* Atom
* Konsole terminal with specific profile

# KDE Plasma level settings:
## Menu: System Settings / Workspace / Desktop Behavior / Activities (for each activity)
* Switching tab : "Remember the current virtual desktop for each activity (needs restart)"
* Privacty tab: Remember Open Documents: for all applications
## Menu: System Settings / Workspace / Startup and Shutdown
* On Login> "restore previous session"

# Initial observed behavior:
* Kate, Konsole, Thunderbird, Firefox, Atom, SimpleNote, LibreOffice Calc and in general all KDE apps work as expected: they start and stay in the Activity from which they are launched
* Vivaldi, Visual Studio Code are visible in all Activities regardless of how they start.

# Reason for behavior
* Apparently related to apps doing CSD (Client Side Decoration). This is a quasi religious GTK-KDE argument, apparently with no easy solution.
* More details in :
* https://stackoverflow.com/questions/286 ... decoration
* https://unix.stackexchange.com/question ... ecorations
* https://www.reddit.com/r/kde/comments/9 ... te_better/

# "Fixes" for Vivaldi and Visual Studio Code
* Tried installing and running gtk3-nocsd but could not get it to help for these two apps (any tips welcome)
* App-level fixes seem to be available
* vivaldi browser (version 2.3.1448.48): settings / appearance / "use native window" - helped. Now have a not-too-useful window bar on top, but vivaldi opens only in the current activity. Arguably less convenient (you have to be more careful with the mouse to select tabs) but good enough for me at the moment.
* Visual Studio Code (v 1.31.1) : file / preferences / settings/ Look for "Window: Title Bar Style" and select "Native" (default is "Custom" with CSD)
(description: Adjust the appearance of the window title bar. Changes require a full restart to apply.)

EDITED/ADDED: one of the goals stated above was to have applications within an activity to start at boot time. I see this only seems to work for KDE Apps (Dolphin, Kate, Konsole, Konversation) but not for other apps (Vivaldi, Libreoffice Calc, SimpleNote, VSC, etc.). Any suggestions on how to have non-KDE apps to behave like KDE apps welcome.

I hope this helps. I'd appreciate tips and suggestions on using Activities and KDE
Rafan

(*) Unsolicited plug: SimpleNote (https://simplenote.com) is a multiplatform (Linux, Win, Android, iPhone, Mac, web-app) note taking application from Automattic (sic), makers of WordPress. It automatically syncs among all the devices running SimpleNote and logging to your account. I use it for non confidential stuff (cooking recipes, tech tips, basic todo lists, etc...). It stores your notes in the Automattic cloud so I would not recommend using it for confidential or security sensitive information. I also regularly back the notes up to local storage. Each note saved as a text file and all packaged inside a zipped file. Only text (understands markdown). Pretty basic interface. No fancy Evernote here.
airdrik
Registered Member
Posts
1691
Karma
3
OS
Well, looks like your assessment matches my observations, down to how various non-KDE apps cooperate (or don't) with activities.

I would be interested to know if anyone has an explanation for why non-KDE apps (besides FireFox which largely behaves like a KDE app in this regard, despite being a GTK app; kudos to whoever made that work properly) aren't started on login. That seems like a trivial thing to make work; or is it supposed to work but doesn't due to some technical deficiency?

Another observation: With multiple Activities for different Development activities, If you open a second Atom window on a second Activity (e.g. by opening it from a folder in Dolphin), it switches back to the Activity with the first Atom window and opens the second Atom window there.


airdrik, proud to be a member of KDE forums since 2008-Dec.
rafaelp
Registered Member
Posts
2
Karma
0
Trying to document some activity settings, prompted by trying to delete an activity. Not a trivial task since settings are all over the place (literally).

Activity General Configuration
System Settings / Workspace / Desktop Behavior / Activities
* Screen has a "+ Create Activity" button as expected; so far so good.
* Shows different activities and for each an icon that opens a pop up that allows changing Name (very useful), Description, Icon (icons appear *very* small), and one tab ("Other") about privacy/tracking usage -- No explanation. I could venture a guess, but didn't quite understand what this privacy settings means.
* What seems to be missing is a way to delete activities here.

Deleting an Activity (newbie view)
* could not figure it out. searched and found several topics, among which : viewtopic.php?t=90229. The fact that something so simple requires several postings/queries is telling.
* The procedure seems to be:
1. click on "Show Activity Manager" (icon with three largish dots) (This doesn't seem to be available from settings menus, can't quite recall how I got icon to my task bar)
2. hover over target activity
3. a red button to "Stop Activity" appears on the bottom right of the square. Click
4. activity moves to "Stopped Activities" section in the same panel. If this is the first stopped activity the section wasn't visible before. I personally had no clue there was a possibility of stopping activities.
5. Now hover over the stopped activity. A "Delete" icon appears on the bottom right of the area. Click. Answer (helpful) pop up confirmation.
6. Adios activity

I'm really wondering whether activities are useful/worth the trouble for my daily workflow. Life is too short to spend it chasing this basic stuff :)
airdrik
Registered Member
Posts
1691
Karma
3
OS
I think the expectation is that most interactions with activities are done using the Activities Panel (default shortcut: meta+q). I will agree that deleting an activity that is currently running is more complicated than it probably should be. At the very least it could be simplified by always showing the delete button even if it is running rather than requiring you to stop it first.

Checking out what's in System Settings -> Desktop Behavior -> Activities, I see buttons to delete activities in there, beside the buttons to configure each activity (ubuntu 18.04, running plasma 5.12.7, frameworks 5.47.0, qt 5.9.5)


airdrik, proud to be a member of KDE forums since 2008-Dec.
shaffaafahmed
Registered Member
Posts
1
Karma
0
I found a solution to this from a stackoverflow post which I have pasted onto a gist. Here is the gist:
This is an issue caused by the use of client side decorations (CSD for short) in some GTK applications. You can disable CSD for all GTK applications using something like gtk3-nocsd.

But there is another way to fix this for individual applications! You can keep using CSD and still have shadows and resize borders if you are using breeze or any other breeze based window decoration! Here is how to do this:

System settings => Window Management => Window Rules and click "New". Then click "Detect Window Properties" and click the window you want to fix and click "Ok" in the confirmation dialog. After that switch to "Appearance & Fixes" tab and toggle "No titlebar and frame", select "Force" from the drop down list and choose "No". Then press "Ok" and "Apply" for the changes to become active. This forces the native KDE window decoration to be drawn around the application. You probably want to hide the visible part of the decoration, since CSD windows already have their own window buttons drawn inside the application:

System settings => Application Style => Window Decorations => Configure (your Breeze based decoration) => Window-Specific Overrides and click "Add". Then again click "Detect Window Properties" and click the window you want to fix. Press "Ok" in the confirmation dialog and toggle "Hide window title bar". Press "Ok" and then "Apply". Boom! Your GTK app should now have proper shadows & resize borders while still using CSD.


Btw u can specify no titlebar and no border for maximum effect !

 
Reply to topic

Bookmarks



Who is online

Registered users: Baidu [Spider], Bing [Bot], Google [Bot], Majestic-12 [Bot], Peter Evans, Snudl, Sogou [Bot], TristanDee, wind_rose_2, Yahoo [Bot]