Welcome!
Important information
-- Spectre and Meltdown vulnerabilities
-- Change in MX sources

News
-- MX Linux on social media: here
-- Mepis support still here

Current releases
-- MX-17.1 Final release info here
-- antiX-17 release info here

New users
-- Please read this first, and don't forget to add system and hardware information to posts!
-- Here are the Forum Rules

start Task Manager minimized

Here you can exchange scripts that you created or have permission to share with other users.
Message
Author
User avatar
Jerry3904
Forum Veteran
Forum Veteran
Posts: 22687
Joined: Wed Jul 19, 2006 6:13 am

start Task Manager minimized

#1 Post by Jerry3904 » Sun Feb 12, 2017 11:53 am

I am looking at having the Task Manager be minimized in the Notification Area on login, because it is so handy both with mouse-over (which gives processes, cpu, memory and swap) and of course launched. I tried a number of different approaches, without success, so finally posted on the Xfce Forum.

ToZ confirmed that the usual procedures don't work, so he suggested using a script:

Code: Select all

#!/bin/bash

xfce4-taskmanager &
sleep 1
xdotool windowminimize $(wmctrl -l | grep "Task Manager" | awk '{print $1}')
I created a script with that, made it executable, then pointed to it with a new entry in Session and Startup. It didn't work, so I stepped through the commands and discovered that wmctrl is not installed. Once installed, all was good; so I post it here in case anyone else is interested in using it.
Production: 4.15.0-1-amd64, MX-17.1, AMD FX-4130 Quad-Core, GeForce GT 630/PCIe/SSE2, 8 GB, Kingston SSD 120 GB and WesternDigital 1TB
Testing: AAO 722: 4.15.0-1-386. MX-17.1, AMD C-60 APU, 4 GB

User avatar
richb
Administrator
Posts: 17233
Joined: Wed Jul 12, 2006 2:17 pm

Re: start Task Manager minimized

#2 Post by richb » Sun Feb 12, 2017 11:58 am

That would be a nice addition.
Forum Rules
Guide - How to Ask for Help

Rich
SSD Production: MX 17.1
AMD A8 7600 FM2+ CPU R7 Graphics, 16 GIG Mem. Three Samsung EVO SSD's 250 GB, 350 GB HD

User avatar
Jerry3904
Forum Veteran
Forum Veteran
Posts: 22687
Joined: Wed Jul 19, 2006 6:13 am

Re: start Task Manager minimized

#3 Post by Jerry3904 » Sun Feb 12, 2017 12:04 pm

Yeah, I'm thinking of proposing it after some testing for the next MX release. The idea of needing only a single click to get to be able to kill something or monitor activity fits well with the MX approach IMO.
Production: 4.15.0-1-amd64, MX-17.1, AMD FX-4130 Quad-Core, GeForce GT 630/PCIe/SSE2, 8 GB, Kingston SSD 120 GB and WesternDigital 1TB
Testing: AAO 722: 4.15.0-1-386. MX-17.1, AMD C-60 APU, 4 GB

User avatar
asqwerth
Forum Veteran
Forum Veteran
Posts: 3459
Joined: Sun May 27, 2007 5:37 am

Re: start Task Manager minimized

#4 Post by asqwerth » Sun Feb 12, 2017 12:28 pm

Does this add much in terms of RAM and CPU used? Esp for weaker hardware? Because if so, it might be better not to make it autostart by default.
Desktop: Intel i5-4460, 16GB RAM, Intel integrated graphics
Clevo N130WU-based Ultrabook: Intel i7-8550U (Kaby Lake R), 16GB RAM, Intel integrated graphics (UEFI)
ASUS X42D laptop: AMD Phenom II, 6GB RAM, Mobility Radeon HD 5400

User avatar
Jerry3904
Forum Veteran
Forum Veteran
Posts: 22687
Joined: Wed Jul 19, 2006 6:13 am

Re: start Task Manager minimized

#5 Post by Jerry3904 » Sun Feb 12, 2017 12:29 pm

No clue--but I haven't proposed it yet...

EDIT: here is what is happening on my system with it displayed
You do not have the required permissions to view the files attached to this post.
Production: 4.15.0-1-amd64, MX-17.1, AMD FX-4130 Quad-Core, GeForce GT 630/PCIe/SSE2, 8 GB, Kingston SSD 120 GB and WesternDigital 1TB
Testing: AAO 722: 4.15.0-1-386. MX-17.1, AMD C-60 APU, 4 GB

User avatar
Paul..
Forum Guide
Forum Guide
Posts: 2277
Joined: Sun Mar 18, 2007 6:34 pm

Re: start Task Manager minimized

#6 Post by Paul.. » Sun Feb 12, 2017 2:54 pm

Nice idea...productize!!

Daily: MSI 890FXA-GD70 | AMD Phenom II X6 1055T | GeForce GTX 750 Ti | 8G
Test: Thinkpad T431s | Intel i5-3437U | Intel 3rd gen Graphics | 4G

skidoo
Forum Regular
Forum Regular
Posts: 891
Joined: Tue Sep 22, 2015 6:56 pm

Re: start Task Manager minimized

#7 Post by skidoo » Sun Feb 12, 2017 4:06 pm

a taskmanager is preferable to xkill aka "force kill" utility b/c in certain environments (maybe not xfce) user may kill the entire session by accidentally clicking the desktop (root window).

> Does this add much in terms of RAM and CPU used?

With attention to that, might tweak the default taskmanager config so that it updates its output less frequently. (Stock default is 1000ms refresh? Change to 3000?) Someone should check -- I think I did so, but foggy memory -- use htop or similar while taskmanager is running; IIRC, it incurs "just as much" cpu load while trayed as it does while its window is displayed.

User avatar
Jerry3904
Forum Veteran
Forum Veteran
Posts: 22687
Joined: Wed Jul 19, 2006 6:13 am

jerry3904

#8 Post by Jerry3904 » Sun Feb 12, 2017 4:09 pm

Good way to go

EDIT: dropped it 750 ms to 2s, cpu% lowered more than half. Can explore this some more...
You do not have the required permissions to view the files attached to this post.
Production: 4.15.0-1-amd64, MX-17.1, AMD FX-4130 Quad-Core, GeForce GT 630/PCIe/SSE2, 8 GB, Kingston SSD 120 GB and WesternDigital 1TB
Testing: AAO 722: 4.15.0-1-386. MX-17.1, AMD C-60 APU, 4 GB

User avatar
Richard
Posts: 2149
Joined: Fri Dec 12, 2008 10:31 am

Re: start Task Manager minimized

#9 Post by Richard » Sun Feb 12, 2017 6:40 pm

On 32 bit netbook,
@ 750 ms, cpu% approx. 9-13% (the default)
@2500 ms, cpu% approx. 4-6%

Still too high to leave running by default on this one.
Last edited by Richard on Sun Feb 12, 2017 8:30 pm, edited 2 times in total.
MX171: Lenovo T430: Intel Ivy Bridge i5-3320M, 8GB RAM, 4.18.0-2-amd64, 119GB SSD
MX171: EeePC 1005HA: Dual Core Atom N270, 1GB RAM, 4.9.0-8-686, 150GB HDD
Thunar/Doublecmd, LibO613, Dropbox, Firefox, CherryTree, Vbox. LinuxCounter #208633

User avatar
richb
Administrator
Posts: 17233
Joined: Wed Jul 12, 2006 2:17 pm

Re: start Task Manager minimized

#10 Post by richb » Sun Feb 12, 2017 6:55 pm

With the default setting on my machine runs between 0% and 1%.
Forum Rules
Guide - How to Ask for Help

Rich
SSD Production: MX 17.1
AMD A8 7600 FM2+ CPU R7 Graphics, 16 GIG Mem. Three Samsung EVO SSD's 250 GB, 350 GB HD

Post Reply

Return to “Scripts”