summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFlorent Le Coz <louiz@louiz.org>2012-01-24 15:17:54 +0100
committerFlorent Le Coz <louiz@louiz.org>2012-01-26 10:05:36 +0100
commit7d5fa2a3169a95c3562b89814046f7460450cbef (patch)
tree092a8a2827754b5643369f67da7318099ce9ffed /src
parente17b70e285406da6a3a564ff4b7c0da2fc208df2 (diff)
downloadpoezio-7d5fa2a3169a95c3562b89814046f7460450cbef.tar.gz
poezio-7d5fa2a3169a95c3562b89814046f7460450cbef.tar.bz2
poezio-7d5fa2a3169a95c3562b89814046f7460450cbef.tar.xz
poezio-7d5fa2a3169a95c3562b89814046f7460450cbef.zip
Fix the comments in the theming.py file
Diffstat (limited to 'src')
-rw-r--r--src/theming.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/theming.py b/src/theming.py
index 7e90a5a7..4e1f37ea 100644
--- a/src/theming.py
+++ b/src/theming.py
@@ -11,16 +11,17 @@ used when drawing the interface.
Colors are numbers from -1 to 7 (if only 8 colors are supported) or -1 to 255
if 256 colors are available.
-We check the number of available colors at startup, and we load a theme accordingly.
-A 8 color theme should NEVER use colors not in the -1 -> 7 range. We won't check that
-at run time. If the case occurs, the THEME should be fixed.
+If only 8 colors are available, all colors > 8 are converted using the
+table_256_to_16 dict.
+
XHTML-IM colors are converted to -1 -> 255 colors if available, or directly to
-1 -> 8 if we are in 8-color-mode.
A pair_color is a background-foreground pair. All possible pairs are not created
at startup, because that would create 256*256 pairs, and almost all of them
would never be used.
-So, a theme should define color tuples, like (200, -1), and when they are to
+
+A theme should define color tuples, like (200, -1), and when they are to
be used by poezio's interface, they will be created once, and kept in a list for
later usage.
A color tuple is of the form (foreground, background, optional)