summaryrefslogtreecommitdiffstats
path: root/Action.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix "CPU usage bar" help alignment.Anton Soroko12 days1-1/+1
|
* Update includes based on IWYUBenny Baumann2023-12-261-1/+6
|
* Warn on failure to kill a processBenny Baumann2023-11-031-1/+5
|
* Move shared memory next to used memoryKevin Bracey2023-10-261-1/+1
| | | | | | | | | Shared memory is less available than buffers, so move it left next to used memory. This is in preparation for including shared memory in the basic "in use" for the bar text. It would not make sense to sum a discontiguous region.
* Correct order of memory meter in helpKevin Bracey2023-10-261-1/+1
|
* Add recalculate to Ctrl-L refreshDaniel Lange2023-09-231-1/+2
| | | | Closes #1304
* Fix compilation issue in Action.cBenny Baumann2023-09-091-2/+4
| | | | | | | Accidentally introduced by merging #1254 Caused by refactor in #1294 Fixes #1300
* Update process list on thread visibility togglingDaniel Lange2023-09-081-0/+2
| | | | Fixes #1254
* Rename ProcessList to ProcessTable throughoutNathan Scott2023-08-311-1/+1
| | | | | | | | | | | | Following up with some discusson from a few months back, where it was proposed that ProcessTable is a better name. This data structure is definitely not a list ... if it was one-dimensional it'd be a set, but in practice it has much more in common with a two-dimensional table. The Process table is a familiar operating system concept for many people too so it resonates a little in that way as well.
* Support dynamic screens with 'top-most' entities beyond processesSohaib Mohamed2023-08-301-13/+48
| | | | | | | | | | | | | | | | | | | | | | This implements our concept of 'dynamic screens' in htop, with a first use-case of pcp-htop displaying things like top-filesystem and top-cgroups under new screen tabs. However the idea is more general than use in pcp-htop and we've paved the way here for us to collectively build mroe general tabular screens in core htop, as well. From the pcp-htop side of things, dynamic screens are configured using text-based configuration files that define the mapping for PCP metrics to columns (and metric instances to rows). Metrics are defined either directly (via metric names) or indirectly via PCP derived metric specifications. Value scaling and the units displayed is automatic based on PCP metric units and data types. This commit represents a collaborative effort of several months, primarily between myself, Nathan and BenBE. Signed-off-by: Sohaib Mohamed <sohaib.amhmd@gmail.com> Signed-off-by: Nathan Scott <nathans@redhat.com>
* Introduce Row and Table classes for screens beyond top-processesNathan Scott2023-08-301-47/+57
| | | | | | | | | This commit refactors the Process and ProcessList structures such they each have a new parent - Row and Table, respectively. These new classes handle screen updates relating to anything that could be represented in tabular format, e.g. cgroups, filesystems, etc, without us having to reimplement the display logic repeatedly for each new entity.
* Document 'O' keyboard shortcutSahil Siddiq2023-05-241-2/+3
| | | | Co-authored-by: BenBE <BenBE@geshi.org>
* Make Action_pickFromVector code match header prototypeNathan Scott2023-05-171-4/+4
| | | | Noticed by BenBE in review of #1243
* Update F5 key label on tab switch (Tree <-> List)Daniel Lange2023-05-161-3/+3
| | | | Closes #1247
* Introduce Machine class for host-specific info (split from ProcessList)Nathan Scott2023-05-081-48/+63
| | | | | | | | | | | First stage in sanitizing the process list structure so that htop can support other types of lists too (cgroups, filesystems, ...), in the not-too-distant future. This introduces struct Machine for system-wide information while keeping process-list information in ProcessList (now much less). Next step is to propogate this separation into each platform, to match these core changes.
* Drop references to 'Process' in generic screen codeNathan Scott2023-05-081-3/+3
| | | | | | | | | | | | Prepare the way for making screen tabs more generalised, able to cater to entities other than processes. 'actionTogglePauseProcessUpdate' -> 'actionTogglePauseUpdate' 'pauseProcessUpdate' -> 'pauseUpdate' 'hideProcessSelection' -> 'hideSelection' 'hideProcessSelection' -> 'hideSelection' Signed-off-by: Sohaib Mohamed <sohaib.amhmd@gmail.com>
* Force re-sorting of the process list view after switching between ↵Benny Baumann2023-04-281-0/+3
| | | | | | list/treeview mode Fixes: #1225
* {Memory,Swap}Meter: add "compressed memory" metricsIvan Shapovalov2023-04-231-2/+4
| | | | | | | | For now, the semantics are mostly fit for Linux zswap subsystem. For instance, we add the third swap usage metric that indicates the amount of memory that is accounted to swap but in fact stored elsewhere. This exactly matches the definition of frontswap/zswap, and is probably of little use to all other platforms.
* Minor code formatting consistency fixesBenny Baumann2023-04-111-1/+1
|
* Add support for scheduling policiesChristian Göttsche2023-02-051-0/+52
| | | | | | | | | | | | | Add a process column for scheduling policy to show the current scheduling policy of the process. Add a the ability to change the scheduling policy of a process via the key 'Y'. Currently implemented on Linux and FreeBSD only but should be portable, since sched_getscheduler(2) is part of POSIX.1-2001. Closes: #1161
* Update the Panel header on sort order inversionsChristian Göttsche2023-01-101-1/+1
| | | | | On pressing 'I' to invert the current sort order redraw the panel header to update the order indicator.
* Refresh the settings->lastUpdate to force recalculation of cached display ↵Benny Baumann2022-11-221-0/+10
| | | | strings
* Allow to keep following when just changing display settingsBenny Baumann2022-11-221-2/+2
|
* Update the panel header when changing to another tabBenny Baumann2022-10-271-3/+3
| | | | Fixes #1120
* Reformat code baseBenny Baumann2022-10-241-1/+1
| | | | | | | | | | | | | | This includes: - Wrap function implementations - Pointer alignment for function signatures - Pointer alignment for variable declarations - Whitespace after keywords - Whitespace after comma - Whitespace around initializers - Whitespace around operators - Code indentation - Line break for single line statements - Misleading alignment
* Toggle the header meters with pound keyChristian Göttsche2022-10-221-0/+7
| | | | | | | | | Show/hide the header meters with the pound ('#') key. Useful in cases where the header is too large and occupies essential parts of the screen, especially in settings (see #1108). It is only stored as a runtime state, not a persistent setting; to remove the header permanently one can delete all active meters.
* Implement LinuxProcessList_checkPidNamespacevaldaarhun2022-08-291-0/+6
| | | | | | | | | | | | | | | | | | Add actionToggle and fix LinuxProcessList_checkPidNamespace Read cgroup file irrespective of flags Improve logic to check if running in container Add isContainerOrVMSlice() Also change "(Process *)lp" to "proc" Remove check for root slice Remove Process_isRunningInContainer Co-authored-by: BenBE <BenBE@geshi.org>
* actionExpandOrCollapse: NOOP in flat modeChristian Göttsche2022-08-041-0/+3
| | | | | This shortcut does not have any visible effect in flat mode, so disable it completely to avoid possible confusion.
* Merge branch 'fix-allBranchesCollapsed' of tanriol/htopDaniel Lange2022-05-301-0/+3
|\
| * actionExpandOrCollapseAllBranches: NOP in flat modeDenis Lisov2022-05-301-0/+3
| | | | | | | | | | This shortcut does not have any visible effect in flat mode, so disable it completely to avoid possible confusion.
* | Fix typo, thx Explorer09Benny Baumann2022-05-211-1/+1
| |
* | Mark item separator in default color on help screenWHR2022-05-201-24/+35
|/ | | | Closes: #1014
* fix typo (dist -> disk)Christian Hesse2022-05-201-1/+1
| | | | | This was changed in commit 37e01cbe33714c8fde72220555b92c7d8585d127, probably unintentional.
* Colorize process state characters in help screenBenny Baumann2022-05-201-2/+16
| | | | | Thanks to @Low-power for the idea Closes #1010
* Call mousemask(3X) to truly enable or disable mouse controlWHR2022-05-191-0/+1
|
* Increasing niceness is also disabled by --readonly modeDaniel Lange2022-05-131-1/+1
|
* Document screen tab switching (TAB, Shift-TAB keys)Daniel Lange2022-04-301-0/+2
|
* ProcessList: sort before panel rebuild if neededDenis Lisov2022-02-131-4/+2
|
* Help: Linux swap consistencyKevin Bracey2022-01-131-1/+1
| | | | | | | | On the help screen's depiction of the swap bar, the / separator between used and cache should be coloured for consistency with the other bars. I tried removing the coloured /s from the other bars to make them consistent, but found that less visually appealing.
* Introduce screen tabsHisham Muhammad2021-12-071-13/+57
| | | | This is a forward port (by nathans) of Hisham's original code.
* Pre-select the last sent signal in SignalsPanelChristian Göttsche2021-12-051-1/+4
| | | | | | | Instead of pre-selecting SIGTERM every time, select the signal last send in the same htop session. Closes: #862
* Update license headers to explicitly say GPLv2+Daniel Lange2021-09-221-2/+2
|
* Simplify adding pages in one placeBenny Baumann2021-08-221-6/+2
|
* Abstract resize handling by adding a new Htop reactionChristian Göttsche2021-08-221-4/+1
|
* Spell out virtualizedDaniel Lange2021-08-181-2/+2
|
* Apply suggestions from code reviewNathan Scott2021-08-171-1/+1
| | | Co-authored-by: BenBE <BenBE@geshi.org>
* Ensure DynamicColumn hash lookups never see NULL pointersNathan Scott2021-08-171-2/+3
| | | | | | This cannot happen in these code locations, but for the purposes of static checkers like Coverity scan (and for future proofing), add two more guards on NULL hash table entry pointers.
* Simplify Action_pickFromVector() width parameter usageChristian Göttsche2021-08-161-5/+4
| | | | Pass one less instead of subtracting one inside the function.
* PCP: support for 'dynamic columns' added at runtimeSohaib Mohamed2021-08-131-2/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implements support for arbitrary Performance Co-Pilot metrics with per-process instance domains to form new htop columns. The column-to-metric mappings are setup using configuration files which will be documented via man pages as part of a follow-up commit. We provide an initial set of column configurations so as to provide new capabilities to pcp-htop: including configs for containers, open fd counts, scheduler run queue time, tcp/udp bytes/calls sent/recv, delay acct, virtual machine guests, detailed virtual memory, swap. Note there is a change to the configuration file path resolution algorithm introduced for 'dynamic meters'. First, look in any custom PCP_HTOP_DIR location. Then iterate, in priority order, users home directory, then local sysadmins files in /etc/pcp/htop, then readonly configuration files below /usr/share/pcp/htop. This final location becomes the preferred place for our own shipped meter and column files. The Settings file (htoprc) writing code is updated to not using the numeric identifier for dynamic columns. The same strategy used for dynamic meters is used here where we write Dynamic(name) so the name can be setup once more at start. Regular (static) columns writing to htoprc - i.e. numerically indexed - is unchanged.
* Enable affinity support for non-LinuxChristian Göttsche2021-07-181-4/+7
| | | | | sched_getaffinity() and sched_setaffinity() are also available on BSDs. Remove the Linux restraint.

© 2014-2024 Faster IT GmbH | imprint | privacy policy