diff --git a/README.rst b/README.rst index 4e28aaf4..4df2875e 100644 --- a/README.rst +++ b/README.rst @@ -235,8 +235,7 @@ Homebrew .. code-block:: console - $ brew install python - $ pip install glances + $ brew install glances MacPorts ```````` diff --git a/glances/outputs/glances_curses.py b/glances/outputs/glances_curses.py index 006ffab4..3b0670bc 100644 --- a/glances/outputs/glances_curses.py +++ b/glances/outputs/glances_curses.py @@ -2,7 +2,7 @@ # # This file is part of Glances. # -# Copyright (C) 2017 Nicolargo +# Copyright (C) 2018 Nicolargo # # Glances is free software; you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published by @@ -527,9 +527,11 @@ class _GlancesCurses(object): # Adapt number of processes to the available space max_processes_displayed = ( self.screen.getmaxyx()[0] - 11 - - self.get_stats_display_height(__stat_display["alert"]) - - self.get_stats_display_height(__stat_display["docker"]) - ) + (0 if 'alert' not in __stat_display else + self.get_stats_display_height(__stat_display["alert"])) - + (0 if 'docker' not in __stat_display else + self.get_stats_display_height(__stat_display["docker"]))) + try: if self.args.enable_process_extended and not self.args.process_tree: max_processes_displayed -= 4