[BUG] EvTables header skewed when using colors
See original GitHub issueDescribe the bug
In certain cases, the evtables header can be skewed. This happens when the header has leading/trailing spaces. They get trimmed which causes the table to look skewed.
To Reproduce
Steps to reproduce the behavior:
- Use the following example script:
from evennia.utils import evtable
table = evtable.EvTable("|cHeading1|n", "|cHeading2 |n", "|cHeading 3|n")
table.add_row("This","Test","test")
print(table)
- Execute said script
- See the error occur (as shown below)
+----------+-----------+-----------+
| Heading1 | Heading2 | Heading 3 |
+~~~~~~~~~~+~~~~~~~~~~~+~~~~~~~~~~~+
| This | Test | test |
Expected behavior
The table should be straight without any indentations
Environment, Evennia version, OS etc
Evennia version: 1.0-dev (rev 54ebdb5ab) OS: nt Python: 3.9.7 Twisted: 21.7.0 Django: 3.2.7
Additional context
This only seems to occur when you are using colors and the space character, otherwise it looks fine.
Issue Analytics
- State:
- Created 2 years ago
- Comments:10 (8 by maintainers)
Top Results From Across the Web
IOS Bug: Different colors in the header bug. #4999 - GitHub
Current Behavior When I have two screens with a different background color header, when I click the back button, while the screen transition ......
Read more >Anyone having issues with table headers not retain...
Anyone having issues with table headers not retaining shading in Cloud? ... The rest of the tables appear as the default color.
Read more >Bug in Color header formatting (Matrix visual)
Color header formatting (in Field formatting) does not work when Show values in row groups rather than columns (in Values) is turned on....
Read more >Header color issue when jumping from one site to another with a
I'm using SharePoint Online Modern pages in SharePoint and am encountering an issue with the header color. I start on a page with...
Read more >Header Colors in Modules - Instructure Community
Is there any way the headers in Modules could have different color ... the individual level, but you can add icons using Unicode...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Rereading @Henddher’s analysis, he used the
evennia shell
it seems. So maybe it’s something webclient specific then, I’ve not tested it myself at this time.Fixed in develop. Closing for book keeping.