Tryton - Issues

 

Issue8562

Title Restore colors on tree view
Priority feature Status resolved
Superseder Nosy List ced, pokoli, reviewbot, roundup-bot
Type feature request Components sao, tryton, trytond
Assigned To ced Keywords review
Reviews 261951002
View: 261951002

Created on 2019-08-08.17:36:56 by ced, last changed by roundup-bot.

Files
File name Uploaded Type Edit Remove
2019-08-08-173756_970x776_scrot.png ced, 2019-08-08.17:44:21 image/png
2019-08-08-173808_970x776_scrot.png ced, 2019-08-08.17:44:30 image/png
Screenshot_2019-08-08 Customer Invoices - Tryton.png ced, 2019-08-08.17:44:13 image/png
Screenshot_2019-08-08 Parties - Tryton.png ced, 2019-08-08.17:44:00 image/png
Messages
New changeset d0599b2a6af9 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/tryton-env/rev/d0599b2a6af9
New changeset c83dbb7f6d02 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/trytond/rev/c83dbb7f6d02
New changeset 848a555959f6 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/tryton/rev/848a555959f6
New changeset c61350d99593 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/sao/rev/c61350d99593
New changeset b5791fd500b1 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/stock/rev/b5791fd500b1
New changeset dd8c134f116e by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/sale_subscription/rev/dd8c134f116e
New changeset 433721e86ade by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/sale_opportunity/rev/433721e86ade
New changeset 9ba8a0333c3c by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/sale_complaint/rev/9ba8a0333c3c
New changeset 0462335d868f by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/sale/rev/0462335d868f
New changeset 00f8bcb08425 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/purchase_requisition/rev/00f8bcb08425
New changeset f58c82391c8e by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/purchase_request/rev/f58c82391c8e
New changeset feec0812b6ba by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/purchase/rev/feec0812b6ba
New changeset ef7d30c9fc43 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/production/rev/ef7d30c9fc43
New changeset dbc0148cf569 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/account_statement/rev/dbc0148cf569
New changeset b01532d3e904 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/account_invoice/rev/b01532d3e904
New changeset de5f599423a6 by Cédric Krier in branch 'default':
Add visual context on tree view
https://hg.tryton.org/modules/account/rev/de5f599423a6
review261951002 updated at https://codereview.tryton.org/261951002/#ps275961002
msg51577 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-08-30.10:12:19
I do not think it is right nor good UX.
The colors are useful when there are a lot of information and details but on a form this should not be the case.
More over, the color change the background of non editable cell. In form, every field is editable and it will be bad for readability to change the background of an editable input.
I do not think it is by mistake that Bootstrap does not have the same classes for form/input than the one used for the table.
msg51576 (view) Author: [hidden] (pokoli) (Tryton committer) (Tryton translator) Date: 2019-08-30.09:44:41
I'm wondering if it will be to hard to also add visuals on fields for form view. 

I find that most users request to have some visual indication on forms also depending on some PYSON expresion.

For now we are solving it by adding some icons but having a visual indication will solve the issue most of the time.
msg51147 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-08-09.14:07:00
> I'm wondering if we should allow to add new visuals by customizing the client theme. What do you think?

I do not think. The issue4861 was about too much customization.
My proposal is about rationalize and reduce to the minimal needed.
If someone want more meaning then he can use icons.
msg51146 (view) Author: [hidden] (pokoli) (Tryton committer) (Tryton translator) Date: 2019-08-09.13:48:09
> Also I think I will add a new value "muted" which change the foreground (for #fff by default). For example, it could be used to lighten canceled documents.

I'm wondering if we should allow to add new visuals by customizing the client theme. What do you think?
review261951002 updated at https://codereview.tryton.org/261951002/#ps249741012
msg51143 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-08-09.10:15:48
I'm wondering if the attribute should not be called "visual" instead of "color".
Also I think I will add a new value "muted" which change the foreground (for #fff by default). For example, it could be used to lighten canceled documents.
msg51133 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-08-08.18:52:45
Because info is the same color as the selected. And because I do not see it as meaningful, all data are info.
msg51132 (view) Author: [hidden] (pokoli) (Tryton committer) (Tryton translator) Date: 2019-08-08.18:49:16
Why not adding info also?
review261951002 updated at https://codereview.tryton.org/261951002/#ps257881002
msg51130 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-08-08.17:44:00
Here is review261951002. I added some colors on party payable/receivabe today, on invoice with amount to pay, on purchase and sale with exception.

Here are some screenshots.
msg51129 (view) Author: [hidden] (ced) (Tryton committer) (Tryton translator) Date: 2019-08-08.17:36:55
issue4861 removed colors because they were hard coded, did not work with theme etc.
But as states in msg22147, a better implementation would be welcomed.
So here is my proposal, we could limit color on tree to three values: success, warning and danger (taken from bootstrap [1]). This way they can be integrated into the theme. Unfortunately, GTK does not allow yet CSS for row [2] but we can manage them like we do for the icons: having a list of configured colors.

[1] https://getbootstrap.com/docs/3.4/css/#tables-contextual-classes
[2] https://gitlab.gnome.org/GNOME/gtk/issues/581
History
Date User Action Args
2019-09-20 11:48:38roundup-botsetmessages: + msg51979
2019-09-20 11:48:32roundup-botsetmessages: + msg51978
2019-09-20 11:48:30roundup-botsetmessages: + msg51977
2019-09-20 11:48:27roundup-botsetmessages: + msg51976
2019-09-20 11:48:25roundup-botsetmessages: + msg51975
2019-09-20 11:48:22roundup-botsetmessages: + msg51974
2019-09-20 11:48:15roundup-botsetmessages: + msg51973
2019-09-20 11:48:11roundup-botsetmessages: + msg51972
2019-09-20 11:48:05roundup-botsetmessages: + msg51971
2019-09-20 11:48:00roundup-botsetmessages: + msg51970

Showing 10 items. Show all history (warning: this could be VERY long)