All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Haggerty <mhagger@alum.mit.edu>
To: Marc Branchaud <marcnarc@xiplink.com>, Paul Mackerras <paulus@samba.org>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 00/13] gitk: tweak rendering of remote-tracking references
Date: Thu, 22 Dec 2016 09:15:09 +0100	[thread overview]
Message-ID: <24a89c72-af53-0c87-d148-708e014ebe75@alum.mit.edu> (raw)
In-Reply-To: <bfbd5992-da30-b1f0-59e5-a2f36d2e3062@xiplink.com>

On 12/21/2016 08:07 PM, Marc Branchaud wrote:
> On 2016-12-20 07:05 PM, Michael Haggerty wrote:
>> On 12/20/2016 04:01 PM, Marc Branchaud wrote:
>>> [...]
>>> Please don't change the remotebgcolor default.
>>>
>>> Also, perhaps the default remoterefbgcolor should be
>>>     set remoterefbgcolor $headbgcolor
>>> ?
>>>
>>> I say this because when I applied the series, without the last patch, I
>>> was miffed that the remote/ref colour had changed.
>>
>> This is a one-time inconvenience that gitk developers will experience. I
>> doubt that users jump backwards and forwards in gitk versions very often.
> 
> In what way do you mean it's restricted to gitk developers?

Maybe I misunderstood your objection.

While developing this, I realized that the very first time your run gitk
(i.e., when you don't already have a configuration file), it writes the
then-current default colors into your configuration file. If you later
switch gitk versions to a version with different default colors, the
colors from the first-run version are preserved (unless the names of the
variables used to hold the colors are changed).

So if you would run the tip version of my branch first, then the parent
of that version, you would continue to see the colors as modified by the
final commit. If you then switch to the master version, the remote
branch names go back to green (because it goes back to using
`headbgcolor` again), but the remote prefix stays light brown. I thought
you were unhappy about some form of this unexpected persistence problem.
But this problem will mostly be experienced by gitk developers who jump
back and forth between versions.

A normal user probably mostly moves forward through version numbers, and
only occasionally. Such a user, jumping from master to the tip of my
branch (assuming they haven't customized anything), would see

* local branches stay lime
* remote branch prefixes stay pale orange (they don't change to light
brown because the pale orange color from master is stored in their
configuration file)
* remote branch names change from lime to brown (because the
`remoterefbgcolor` configuration setting didn't exist before)

> Patch 12 introduces remoterefbgcolor, with a specific default value.
> Prior to that, the "ref part" of remote refs was rendered with
> headbgcolor.  Users who changed their headbgcolor are used to seeing the
> "ref part" of remote refs in the same color as their local heads.
> Applying patch 12 changes the "ref part" color of remote refs, for such
> users.
> 
> All I'm saying is that make the remoterefbgcolor default be $headbgcolor
> avoids this.

For somebody who thinks that most people will want local and
remote-tracking branch names to be rendered in the same color, your
suggestion would be an improvement.

But for somebody like me who thinks it is a good idea to render
remote-tracking branch names in a different color than local branch
names, this is a feature, not a bug. Even a user who explicitly
configured `headbgcolor` to, say, purple, wasn't necessarily expressing
a wish to have remote-tracking branch names rendered in purple. Until
now they had no choice to set these colors separately!

So even for somebody who configured this setting before, I think that
having the remote-tracking branch names change color when the user
upgrades to this version is a good thing, because it lets the user know
that these two things can now be colored independently. If they don't
like the new default brown color, such a user knows where to change it
(even to make it agree with `headbgcolor` if they want that).

But I understand that this is a matter of personal preference. I have
but one "vote" :-)

Michael


  reply	other threads:[~2016-12-22  8:15 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-19 16:44 [PATCH 00/13] gitk: tweak rendering of remote-tracking references Michael Haggerty
2016-12-19 16:45 ` [PATCH 01/13] gitk: when processing tag labels, don't use `marks` as scratch space Michael Haggerty
2016-12-19 16:45 ` [PATCH 02/13] gitk: keep track of tag types in a separate `types` array Michael Haggerty
2016-12-19 16:45 ` [PATCH 03/13] gitk: use a type "tags" to indicate abbreviated tags Michael Haggerty
2016-12-19 16:45 ` [PATCH 04/13] gitk: use a type "mainhead" to indicate the main HEAD branch Michael Haggerty
2016-12-19 16:45 ` [PATCH 05/13] gitk: fill in `wvals` as the tags are first processed Michael Haggerty
2016-12-19 16:45 ` [PATCH 06/13] gitk: simplify regexp Michael Haggerty
2016-12-19 16:45 ` [PATCH 07/13] gitk: extract a method `remotereftext` Michael Haggerty
2016-12-19 16:45 ` [PATCH 08/13] gitk: only change the color of the "remote" part of remote refs Michael Haggerty
2016-12-19 16:45 ` [PATCH 09/13] gitk: shorten labels displayed for modern remote-tracking refs Michael Haggerty
2016-12-19 16:45 ` [PATCH 10/13] gitk: use type "remote" for remote-tracking references Michael Haggerty
2016-12-19 16:45 ` [PATCH 11/13] gitk: introduce a constant otherrefbgcolor Michael Haggerty
2016-12-19 16:45 ` [PATCH 12/13] gitk: add a configuration setting `remoterefbgcolor` Michael Haggerty
2016-12-19 16:45 ` [PATCH 13/13] gitk: change the default colors for remote-tracking references Michael Haggerty
2016-12-19 22:53 ` [PATCH 00/13] gitk: tweak rendering of " Philip Oakley
2016-12-20  8:03   ` Michael Haggerty
2016-12-20 15:01 ` Marc Branchaud
2016-12-20 22:17   ` Paul Mackerras
2016-12-20 22:53     ` Marc Branchaud
2016-12-21  0:05   ` Michael Haggerty
2016-12-21 19:07     ` Marc Branchaud
2016-12-22  8:15       ` Michael Haggerty [this message]
2017-01-09 22:03         ` Marc Branchaud
2017-02-06 17:13 ` Marc Branchaud

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=24a89c72-af53-0c87-d148-708e014ebe75@alum.mit.edu \
    --to=mhagger@alum.mit.edu \
    --cc=git@vger.kernel.org \
    --cc=marcnarc@xiplink.com \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.