Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-26 Thread Jan Danielsson
On 07/23/11 01:25, Richard Hipp wrote:
[---]
 I tried Ross's proposed color choosing algorithm but it didn't work out.  So
 instead I used the hash to select a Hue in an HSV color space, held the S
 and V fixed, and mapped the result into RGB.  The color chooser code is
 here, if you are interested:
 
  http://www.fossil-scm.org/fossil/artifact/506fc3a6b2808?ln=116,144
 
 Feedback is encouraged.  Remember this changes is experimental and might
 disappear at any moment!

   I really like this feature. I haven't followed the thread, but
whoever first came up with this feature is a genius.

   Each time I branch, I need to start looking up appropriate colors. It
doesn't take long, but if one sums together each time .. too much time
has been wasted in the end. These small time-savers are much appreciated.

-- 
Kind regards,
Jan Danielsson

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-26 Thread Remigiusz Modrzejewski

On Jul 23, 2011, at 01:25 , Richard Hipp wrote:

 An experimental change to implement this is on the server.  Add the brbg
 query parameter to the timeline method to have the background color set by
 branch name.  Add ubg to have the background color set by user name.
 Examples:
 
 http://www.fossil-scm.org/fossil/timeline?n=200y=cibrbg
 http://www.fossil-scm.org/fossil/timeline?n=200y=ciubg

Just what I asked for :)

Kind regards,
Remigiusz Modrzejewski



___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-23 Thread Altu Faltu
Why does the same branch (trunk) take different backgrounds?

- Original Message -
From: Richard Hipp
Sent: 07/23/11 04:55 AM
To: fossil-users@lists.fossil-scm.org
Subject: [fossil-users] Automatic branch color selection. Was: Question on 
short-lived branches in fossil


 On Fri, Jul 22, 2011 at 5:32 PM, Stephan Beal  sgb...@googlemail.com  wrote:

 On Fri, Jul 22, 2011 at 11:07 PM, Ross Berteig  r...@cheshireeng.com  wrote:

 For skins that are dark text on white background, then using the existing MD5 
hash on the tag name, picking a convenient three;
 ...

 it would make an entertaining experiment, whether or not it turns out to be 
useful in practice.
 An experimental change to implement this is on the server. Add the brbg 
query parameter to the timeline method to have the background color set by 
branch name. Add ubg to have the background color set by user name. Examples:

http://www.fossil-scm.org/fossil/timeline?n=200y=cibrbg 
http://www.fossil-scm.org/fossil/timeline?n=200y=ciubg 

 I tried Ross's proposed color choosing algorithm but it didn't work out. So 
instead I used the hash to select a Hue in an HSV color space, held the S and V 
fixed, and mapped the result into RGB. The color chooser code is here, if you 
are interested:

http://www.fossil-scm.org/fossil/artifact/506fc3a6b2808?ln=116,144 

 Feedback is encouraged. Remember this changes is experimental and might 
disappear at any moment!

 --
 D. Richard Hipp
 d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-23 Thread altufaltu
Never mind. I swapped ubg  brbg


 - Original Message -
 From: Altu Faltu
 Sent: 07/23/11 12:01 PM
 To: fossil-users@lists.fossil-scm.org
 Subject: Re: [fossil-users] Automatic branch color selection. Was: Question 
 on short-lived branches in fossil
 
 Why does the same branch (trunk) take different backgrounds?
 
 - Original Message -
 From: Richard Hipp
 Sent: 07/23/11 04:55 AM
 To: fossil-users@lists.fossil-scm.org
 Subject: [fossil-users] Automatic branch color selection. Was: Question on 
 short-lived branches in fossil
 
 
  On Fri, Jul 22, 2011 at 5:32 PM, Stephan Beal  sgb...@googlemail.com  
 wrote:
 
  On Fri, Jul 22, 2011 at 11:07 PM, Ross Berteig  r...@cheshireeng.com  
 wrote:
 
  For skins that are dark text on white background, then using the existing 
 MD5 hash on the tag name, picking a convenient three;
  ...
 
  it would make an entertaining experiment, whether or not it turns out to be 
 useful in practice.
  An experimental change to implement this is on the server. Add the brbg 
 query parameter to the timeline method to have the background color set by 
 branch name. Add ubg to have the background color set by user name. 
 Examples:
 
 http://www.fossil-scm.org/fossil/timeline?n=200y=cibrbg 
 http://www.fossil-scm.org/fossil/timeline?n=200y=ciubg 
 
  I tried Ross's proposed color choosing algorithm but it didn't work out. So 
 instead I used the hash to select a Hue in an HSV color space, held the S and 
 V fixed, and mapped the result into RGB. The color chooser code is here, if 
 you are interested:
 
 http://www.fossil-scm.org/fossil/artifact/506fc3a6b2808?ln=116,144 
 
  Feedback is encouraged. Remember this changes is experimental and might 
 disappear at any moment!
 
  --
  D. Richard Hipp
  d...@sqlite.org
 

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-23 Thread Alaric Snell-Pym
On 07/23/11 01:06, Ross Berteig wrote:

 I get the impression that your calculation picks hues that are
 too close together... it might be better to quantize it more to
 keep them further separated.

I think that'll just force currently-similar colours to be the SAME
colour, by reducing the space of available colours...

...allowing some variablity in S and V might be a better idea, to expand
the space.

 Since the text color is controlled by the CSS which
 fossil almost certainly does not parse, you probably would need a
 separate configuration option somewhere to choose between dark
 and light automatic color choices.

Perhaps the configuration could list max and min values for H, S and V,
and have Fossil pick a colour within that region. The default would
allow all of H and a small range of pastel-oriented S/V.

People with a bold corporate colour scheme could restrict H somewhat if
blue just really clashed with their headers! :-)

ABS

--
Alaric Snell-Pym
http://www.snell-pym.org.uk/alaric/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


[fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-22 Thread Richard Hipp
On Fri, Jul 22, 2011 at 5:32 PM, Stephan Beal sgb...@googlemail.com wrote:

 On Fri, Jul 22, 2011 at 11:07 PM, Ross Berteig r...@cheshireeng.comwrote:

  For skins that are dark text on white background, then using the
 existing MD5 hash on the tag name, picking a convenient three;

 ...

 it would make an entertaining experiment, whether or not it turns out to be
 useful in practice.



An experimental change to implement this is on the server.  Add the brbg
query parameter to the timeline method to have the background color set by
branch name.  Add ubg to have the background color set by user name.
Examples:

 http://www.fossil-scm.org/fossil/timeline?n=200y=cibrbg
 http://www.fossil-scm.org/fossil/timeline?n=200y=ciubg

I tried Ross's proposed color choosing algorithm but it didn't work out.  So
instead I used the hash to select a Hue in an HSV color space, held the S
and V fixed, and mapped the result into RGB.  The color chooser code is
here, if you are interested:

 http://www.fossil-scm.org/fossil/artifact/506fc3a6b2808?ln=116,144

Feedback is encouraged.  Remember this changes is experimental and might
disappear at any moment!

-- 
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-22 Thread Stephan Beal
On Sat, Jul 23, 2011 at 1:25 AM, Richard Hipp d...@sqlite.org wrote:

 An experimental change to implement this is on the server.  Add the brbg
 query parameter to the timeline method to have the background color set by
 branch name.  Add ubg to have the background color set by user name.
 Examples:

  http://www.fossil-scm.org/fossil/timeline?n=200y=cibrbg
  http://www.fossil-scm.org/fossil/timeline?n=200y=ciubg


That is a very lovely extension to the original idea (which, i think, was
just to do it when branching, as opposed to downstream).

:-D

 http://www.fossil-scm.org/fossil/artifact/506fc3a6b2808?ln=116,144


And the block highlighting is new to me! Cool!


 Feedback is encouraged.  Remember this changes is experimental and might
 disappear at any moment!


For a first try it's pretty damned nice :).


-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-22 Thread Richard Hipp
On Fri, Jul 22, 2011 at 7:25 PM, Richard Hipp d...@sqlite.org wrote:



 On Fri, Jul 22, 2011 at 5:32 PM, Stephan Beal sgb...@googlemail.comwrote:

 On Fri, Jul 22, 2011 at 11:07 PM, Ross Berteig r...@cheshireeng.comwrote:

  For skins that are dark text on white background, then using the
 existing MD5 hash on the tag name, picking a convenient three;

 ...

 it would make an entertaining experiment, whether or not it turns out to
 be useful in practice.



 An experimental change to implement this is on the server.  Add the brbg
 query parameter to the timeline method to have the background color set by
 branch name.  Add ubg to have the background color set by user name.


Another change:  The extra query parameters above still work.  But now if a
branch does not have a color set on it, a background color is chosen
automatically, using the same hash-the-branch-name algorithm.

So I think this gives you automatic branch coloring with the ability to
override if you like.


-- 
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-22 Thread Ross Berteig
At 04:25 PM 7/22/2011, Richard Hipp wrote:
 An experimental change to implement this is on the server...
 
 I tried Ross's proposed color choosing algorithm but it didn't
 work out.  So instead I used the hash to select a Hue in an HSV
 color space, held the S and V fixed, and mapped the result into
 RGB.  The color chooser code is here, if you are interested:

I hadn't taken time to see how muddy the result was, so I'm not
surprised if my quick and dirty approach didn't look pretty out
of the box. Your HSV method looks quite hopeful. I also like the
idea of marking users instead of branches, although my personal
use of Fossil only has a few distinct users.

Using a hash to pick H with S and V held constant should work a
lot better than computing RGB directly from hash bits. Even
better might be to include at least one other SV pair that is
distinctly different from the existing choice.

I get the impression that your calculation picks hues that are
too close together... it might be better to quantize it more to
keep them further separated.

 
 Feedback is encouraged.  Remember this changes is experimental
 and might disappear at any moment!

Overall, I really like the effect.

I think that to handle a skin with light text on dark
backgrounds, you might want a control or view that simply ignores
the capability. Otherwise, it is possible that doing exactly this
but with much darker values and increased saturation would work
out ok. Since the text color is controlled by the CSS which
fossil almost certainly does not parse, you probably would need a
separate configuration option somewhere to choose between dark
and light automatic color choices.


Ross Berteig   r...@cheshireeng.com
Cheshire Engineering Corp.   http://www.CheshireEng.com/
+1 626 303 1602
+1 626 351 1590 FAX

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Automatic branch color selection. Was: Question on short-lived branches in fossil

2011-07-22 Thread Wes Freeman
On Fri, Jul 22, 2011 at 7:25 PM, Richard Hipp d...@sqlite.org wrote:

 Feedback is encouraged.  Remember this changes is experimental and might
 disappear at any moment!

Looks very nice. The pastel colors do a great job on white with black
text. I'd say a worthwhile feature. Is there an easy way to make that
the default look of the timeline?

I was actually messing around with a color selection algorithm myself,
and came to approximately the same conclusion about the pastel colors,
but using RGB requires a bit more massaging than your HSV idea--nice
one.

Wes
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users