* Stealing a default face from a non-ELPA package @ 2022-03-05 4:59 Brian Leung 2022-03-05 7:43 ` Tim Cross 0 siblings, 1 reply; 5+ messages in thread From: Brian Leung @ 2022-03-05 4:59 UTC (permalink / raw) To: emacs-devel; +Cc: João Távora I sent this question to the mailing list this morning but I can't see it on the list archives, so I'm trying to send it again: In https://github.com/joaotavora/eglot/discussions/858#discussioncomment-2288255, a user noticed that lsp-mode used as a face default a much nicer setting than what currently exists in eglot. Given that lsp-mode is not part of ELPA, can we steal its setting and use it in eglot? ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Stealing a default face from a non-ELPA package 2022-03-05 4:59 Stealing a default face from a non-ELPA package Brian Leung @ 2022-03-05 7:43 ` Tim Cross 2022-03-05 8:24 ` João Távora 0 siblings, 1 reply; 5+ messages in thread From: Tim Cross @ 2022-03-05 7:43 UTC (permalink / raw) To: Brian Leung; +Cc: João Távora, emacs-devel Brian Leung <leungbk@posteo.net> writes: > I sent this question to the mailing list this morning but I can't see it on the > list archives, so I'm trying to send it again: > > In > https://github.com/joaotavora/eglot/discussions/858#discussioncomment-2288255, > a user noticed that lsp-mode used as a face default a much nicer setting > than what currently exists in eglot. Given that lsp-mode is not part of > ELPA, can we steal its setting and use it in eglot? "much nicer" is a very subjective metric. What you think is much nicer I might think is much uglier. Tweaking face properties is really best left to either individuals or theme authors. From what I can tell in that thread, all that is being proposed is to change the foreground colour of an eglot face to use the same value as a lsp-mode face. If that is the case, I don't see any copyright violation here. All that is being done is changing the value of a face. As the code used to define faces is part of core Emacs, your not talking about code change, only default value change. I do think it is a pointless change. While the proposed new foreground colour might look better to one individual using specific hardware on a specific platform with a specific theme, it could look much worse to another user on a different platform, with different hardware and a different theme who will then log an issue requesting that the face be changed to something they think is a better default setting. Purpose of default face settings should be to set a face which is usable for the widest selection of users, regardless of hardware, platform or type of environment (GUI/Terminal/Console). Fiddling with face aesthetics is best left to theme authors. ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Stealing a default face from a non-ELPA package 2022-03-05 7:43 ` Tim Cross @ 2022-03-05 8:24 ` João Távora 2022-03-05 9:46 ` Tim Cross 0 siblings, 1 reply; 5+ messages in thread From: João Távora @ 2022-03-05 8:24 UTC (permalink / raw) To: Tim Cross; +Cc: Brian Leung, emacs-devel [-- Attachment #1: Type: text/plain, Size: 2525 bytes --] Hello Tim, The goal here, I think, was not to decide if the change had merit or not. As far as I understand there are demonstrable functional problems with the faces default settings as chosen by Brian himself. I presume Brian is just trying to fix those problems, a legitimate goal that cannot be left to "theme authors". There is such a thing as the "default theme" and we are all its authors. Brian is just asking if it is "legal" to take inspiration for decorative face settings from a different project outside GNU ELPA. I believe it is quite legal, but I'm not a specialist so suggested he ask here. João On Sat, Mar 5, 2022, 08:14 Tim Cross <theophilusx@gmail.com> wrote: > > Brian Leung <leungbk@posteo.net> writes: > > > I sent this question to the mailing list this morning but I can't see it > on the > > list archives, so I'm trying to send it again: > > > > In > > > https://github.com/joaotavora/eglot/discussions/858#discussioncomment-2288255 > , > > a user noticed that lsp-mode used as a face default a much nicer setting > > than what currently exists in eglot. Given that lsp-mode is not part of > > ELPA, can we steal its setting and use it in eglot? > > "much nicer" is a very subjective metric. What you think is much nicer I > might think is much uglier. Tweaking face properties is really best left > to either individuals or theme authors. > > From what I can tell in that thread, all that is being proposed is to > change the foreground colour of an eglot face to use the same value as a > lsp-mode face. If that is the case, I don't see any copyright violation > here. All that is being done is changing the value of a face. As the > code used to define faces is part of core Emacs, your not talking about > code change, only default value change. > > I do think it is a pointless change. While the proposed new foreground > colour might look better to one individual using specific hardware on a > specific platform with a specific theme, it could look much worse to > another user on a different platform, with different hardware and a > different theme who will then log an issue requesting that the face be > changed to something they think is a better default setting. > > Purpose of default face settings should be to set a face which is usable > for the widest selection of users, regardless of hardware, platform or > type of environment (GUI/Terminal/Console). Fiddling with face > aesthetics is best left to theme authors. > [-- Attachment #2: Type: text/html, Size: 3317 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Stealing a default face from a non-ELPA package 2022-03-05 8:24 ` João Távora @ 2022-03-05 9:46 ` Tim Cross 2022-03-05 10:29 ` João Távora 0 siblings, 1 reply; 5+ messages in thread From: Tim Cross @ 2022-03-05 9:46 UTC (permalink / raw) To: João Távora; +Cc: Brian Leung, emacs-devel João Távora <joaotavora@gmail.com> writes: > Hello Tim, > > The goal here, I think, was not to decide if the change had merit or not. As far as I understand there are demonstrable functional > problems with the faces default settings as chosen by Brian himself. > > I presume Brian is just trying to fix those problems, a legitimate goal that cannot be left to "theme authors". There is such a thing > as the "default theme" and we are all its authors. > > Brian is just asking if it is "legal" to take inspiration for decorative face settings from a different project outside GNU ELPA. I believe > it is quite legal, but I'm not a specialist so suggested he ask here. > I understand. For the default value of a face, I think the key is to look at the documentation of defface and use the facilities it has to set a default based on the local environment. For example, use a face spec which sets a different foreground colour based on whether the user is using a light or dark theme, is running in a GUI frame or a terminal or console etc. Just using :foreground "grey" is unlikely to give adequate default face specification for all environments. Defining good default face specifications is harder than most people realise. One way to simplify things and get a reasonable default is to define the face to inherit from one of the standard built-in faces. For example font-lock-warning-face. These faces have been implemented to have reasonable defaults for most environments and provided they are wrapped in a defcustom, the user can customise to suit their personal preferences if desired (including turning of the inheritance). I don't believe there is any copyright issue here as you are not using any lsp-mode code. You are defining a face, using standard Emacs facilities and setting its attributes. lsp-mode has no copyright over face attribute values. Personally, I wish more packages would define their faces in terms of inheritance from standard/built-in faces. This would mean a user could tweak the built-in faces to suit their preferences and the additional packages would inherit those tweaks without needing to be done individually. ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Stealing a default face from a non-ELPA package 2022-03-05 9:46 ` Tim Cross @ 2022-03-05 10:29 ` João Távora 0 siblings, 0 replies; 5+ messages in thread From: João Távora @ 2022-03-05 10:29 UTC (permalink / raw) To: Tim Cross; +Cc: Brian Leung, emacs-devel [-- Attachment #1: Type: text/plain, Size: 2715 bytes --] Tim, if things improve with "gray" for the people involved in that particular discussion about that particular face, then I see that as No Bad Thing. I also agree with you that default face design is hard. If you are knowledgeable in this matter and have suggestions for better more robust faces in Eglot we would be delighted to accept them. Joao On Sat, Mar 5, 2022, 10:21 Tim Cross <theophilusx@gmail.com> wrote: > > João Távora <joaotavora@gmail.com> writes: > > > Hello Tim, > > > > The goal here, I think, was not to decide if the change had merit or > not. As far as I understand there are demonstrable functional > > problems with the faces default settings as chosen by Brian himself. > > > > I presume Brian is just trying to fix those problems, a legitimate goal > that cannot be left to "theme authors". There is such a thing > > as the "default theme" and we are all its authors. > > > > Brian is just asking if it is "legal" to take inspiration for decorative > face settings from a different project outside GNU ELPA. I believe > > it is quite legal, but I'm not a specialist so suggested he ask here. > > > > I understand. For the default value of a face, I think the key is to > look at the documentation of defface and use the facilities it has to > set a default based on the local environment. For example, use a face > spec which sets a different foreground colour based on whether the user > is using a light or dark theme, is running in a GUI frame or a terminal > or console etc. Just using :foreground "grey" is unlikely to give > adequate default face specification for all environments. > > Defining good default face specifications is harder than most people > realise. One way to simplify things and get a reasonable default is to > define the face to inherit from one of the standard built-in faces. For > example font-lock-warning-face. These faces have been implemented to > have reasonable defaults for most environments and provided they are > wrapped in a defcustom, the user can customise to suit their personal > preferences if desired (including turning of the inheritance). > > I don't believe there is any copyright issue here as you are not using > any lsp-mode code. You are defining a face, using standard Emacs > facilities and setting its attributes. lsp-mode has no copyright over > face attribute values. > > Personally, I wish more packages would define their faces in terms of > inheritance from standard/built-in faces. This would mean a user could > tweak the built-in faces to suit their preferences and the additional > packages would inherit those tweaks without needing to be done > individually. > [-- Attachment #2: Type: text/html, Size: 3309 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-03-05 10:29 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2022-03-05 4:59 Stealing a default face from a non-ELPA package Brian Leung 2022-03-05 7:43 ` Tim Cross 2022-03-05 8:24 ` João Távora 2022-03-05 9:46 ` Tim Cross 2022-03-05 10:29 ` João Távora
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/emacs.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).