From def1c87caed1033383d2b7e37993f97fd6622dd2 Mon Sep 17 00:00:00 2001 From: Fabio Erculiani Date: Wed, 15 Jul 2009 20:13:38 +0200 Subject: [PATCH] [entropy.output] add docstrings (partial) --- libraries/entropy/output.py | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/libraries/entropy/output.py b/libraries/entropy/output.py index b8141fed4..49cae1106 100644 --- a/libraries/entropy/output.py +++ b/libraries/entropy/output.py @@ -722,6 +722,20 @@ def _my_raw_input(txt = ''): class TextInterface: + """ + TextInterface is a base class for handling the communication between + user and Entropy-based applications. + + This class works for text-based applications, it must be inherited + from subclasses and its methods reimplemented to make Entropy working + on situations where a terminal is not used as UI (Graphical applications, + web-based interfaces, remote interfaces, etc). + + Every part of Entropy is using the methods in this class to communicate + with the user, channel is bi-directional. + + """ + # @input text: text to write # @input back: write on on the same line? # @input importance: @@ -744,7 +758,12 @@ class TextInterface: # # feel free to reimplement this def updateProgress(self, text, header = "", footer = "", back = False, importance = 0, type = "info", count = [], percent = False): - if (etpUi['quiet']) or (etpUi['mute']): + + """ + + """ + + if etpUi['quiet'] or etpUi['mute']: return _flush_stdouterr()