TextAnalysisTool / Releases

Repository for storing release artifacts (ex: binaries).
88 stars 26 forks source link

Request for choosing colors through a color palette in Filter Window #50

Closed dsp0105 closed 3 years ago

dsp0105 commented 6 years ago

Scenario:

Currently, if I am adding a filter, then I can choose only from restricted set of colors for foreground/background, which is very limiting, since I have large number of filters (say 20) and don't have sufficient unique colors

Can we have the option to select any color (through color palette)?

Thanks!

dsp0105 commented 6 years ago

This enhancement is really needed for my work.

If adding a color palette chooser is lot of work, I was wondering if the settings file (containing the preset colors for filter window) be exposed? Then I can add the colors I need manually to it.

Thanks for such a wonderful tool!

vincec-msft commented 6 years ago

You can manually edit the filter file to specify the foreColor and backColor of a filter in RRGGBB format.

I created a quick test of a red gradient background with the text going from white to black. Pretty ugly, but you get the idea.

image

Editing the filter in the UI will revert that one filter to a pre-defined color, but the other filters will remain unchanged.

Here's the tat (filter) file:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<TextAnalysisTool.NET version="2017-10-31" showOnlyFilteredLines="False">
  <filters>
    <filter enabled="y" excluding="n" description="" foreColor="ffffff" backColor="000000" type="matches_text" case_sensitive="n" regex="n" text="0" />
    <filter enabled="y" excluding="n" description="" foreColor="eeeeee" backColor="110000" type="matches_text" case_sensitive="n" regex="n" text="1" />
    <filter enabled="y" excluding="n" description="" foreColor="dddddd" backColor="220000" type="matches_text" case_sensitive="n" regex="n" text="2" />
    <filter enabled="y" excluding="n" description="" foreColor="cccccc" backColor="330000" type="matches_text" case_sensitive="n" regex="n" text="3" />
    <filter enabled="y" excluding="n" description="" foreColor="bbbbbb" backColor="440000" type="matches_text" case_sensitive="n" regex="n" text="4" />
    <filter enabled="y" excluding="n" description="" foreColor="aaaaaa" backColor="550000" type="matches_text" case_sensitive="n" regex="n" text="5" />
    <filter enabled="y" excluding="n" description="" foreColor="999999" backColor="660000" type="matches_text" case_sensitive="n" regex="n" text="6" />
    <filter enabled="y" excluding="n" description="" foreColor="888888" backColor="770000" type="matches_text" case_sensitive="n" regex="n" text="7" />
    <filter enabled="y" excluding="n" description="" foreColor="777777" backColor="880000" type="matches_text" case_sensitive="n" regex="n" text="8" />
    <filter enabled="y" excluding="n" description="" foreColor="666666" backColor="990000" type="matches_text" case_sensitive="n" regex="n" text="9" />
    <filter enabled="y" excluding="n" description="" foreColor="555555" backColor="aa0000" type="matches_text" case_sensitive="n" regex="n" text="a" />
    <filter enabled="y" excluding="n" description="" foreColor="444444" backColor="bb0000" type="matches_text" case_sensitive="n" regex="n" text="b" />
    <filter enabled="y" excluding="n" description="" foreColor="333333" backColor="cc0000" type="matches_text" case_sensitive="n" regex="n" text="c" />
    <filter enabled="y" excluding="n" description="" foreColor="222222" backColor="dd0000" type="matches_text" case_sensitive="n" regex="n" text="d" />
    <filter enabled="y" excluding="n" description="" foreColor="111111" backColor="ee0000" type="matches_text" case_sensitive="n" regex="n" text="e" />
    <filter enabled="y" excluding="n" description="" foreColor="000000" backColor="ff0000" type="matches_text" case_sensitive="n" regex="n" text="f" />
  </filters>
</TextAnalysisTool.NET>
DavidAnson commented 6 years ago

Nice, thanks Vince!

dsp0105 commented 6 years ago

Thanks Vince for quick reply.

I was already doing that as a workaround :) Also I was using the gradient colors too.

But it lacks the basic functionality (you mentioned it in your reply too)

  1. The TAT file with the colors is static i.e. I cant change the filter text dynamically from Textanalysis Tool, if I change the filter text, then the customized color settings are lost (except for "Standard colors" defined in the filter window UI)
vincec-msft commented 6 years ago

Sorry, I was replying to "I was wondering if the settings file (containing the preset colors for filter window) be exposed? Then I can add the colors I need manually to it." The settings file is exposed and you can manually change it. :)

I'm not sure when we'll get the pallet functionality in and wanted to give you a stop gap. I'll look at how hard it would be to just not stomp on custom colors.

DavidAnson commented 6 years ago

FYI, the reason there isn’t a palette chooser already is that I thought it would be hard for a person to quickly tell the difference between more than about 20 colors.

dsp0105 commented 6 years ago

Thanks Vince for getting back.

The reason I am asking for a palette chooser is not for choosing > 20 colors, but for choosing a color I want. It is very useful in grouping lines in a log based on a color scheme, for example:

  1. light blue for lines in a log from an IP address IP1
  2. darker blue (from the gradient which Vince showed) for lines in a log from an IP address IP1 but containing say "error"

I hope I was able to explain the use case.

dsp0105 commented 6 years ago

Thanks Vince, sorry, I missed seeing your reply.

"Non stomping of custom colors" would be really helpful, and would serve my purpose. I understand Color palette chooser would need lot of more work from your side.

dsp0105 commented 6 years ago

Vince, wondering if you got a chance to look at the issue... Thanks!

dsp0105 commented 6 years ago

Sorry, missed your message, sent the mail. Thanks!

vincec-msft commented 3 years ago

Oops, this was added to the 2018-11-20 release but the issue wasn't closed. @dsp0105, I hope you saw the [Custom] color choice or the release note in the readme.txt about this enhancement. Sorry for leaving this open.