aesophor / py-todo

đź“‹ Lightweight reminder / todo-list in cli
https://www.reddit.com/r/unixporn/comments/9qy35q/oc_pytodo_a_lightweight_reminder_in_cli/
MIT License
107 stars 22 forks source link

Code clean-up: Separating out functions, improving docs, and tweaking colors #20

Closed Steampunkery closed 5 years ago

Steampunkery commented 5 years ago

In this PR I fix a few things that have been bugging me.

Colors

Docs

Functions

RewoundVHS commented 5 years ago

Could you post a screenshot of this “ugly grey background”? I haven’t seen this.

Steampunkery commented 5 years ago

Here's a screenshot gray

Steampunkery commented 5 years ago

With my PR, the same config and datafile output looks like this: gray

aesophor commented 5 years ago

The color issue is likely caused by the difference between "terminal's bg color" and "base00" defined in ~/.Xresources

@Steampunkery ty for your PR!! I'll look into it soon ^^

RewoundVHS commented 5 years ago

Hi! Great idea to use different colors for due today and past due. I took a look at your version and I personally don't find it aesthetically pleasing when colors are statically defined instead of given by the terminal colors. From a theming perspective I think it would be nicer to use the following as the colors.

index_color = '\x1b[34m{}\x1b[0m'
date_color = '\x1b[32m{}\x1b[0m'
due_color = '\x1b[31m{}\x1b[0m'
today_color = '\x1b[36m{}\x1b[0m' 

Here is a screenshot todo using these colors

2018-11-02-235830_1600x900_scrot

Steampunkery commented 5 years ago

Huh, I had no idea that terminal colors worked that way! I'll make the relevant changes after some testing. Since my original idea for today_color was to catch the eye without being red (reserved for DUE!), I decided to accept your changes except for today_color, which becomes \x1b[33m{}\x1b[0m, which is yellow. I was going to use bright yellow, but it doesn't look very good.

aesophor commented 5 years ago

I love the way you refactor it! Thanks a lot! :tada: Perhaps you could also look into the Contributors section in README.md? Like adding what you have done.

Cheers!