bugGNU nano - Bugs: bug #56445, [Wish] add support for more colors...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #56445: [Wish] add support for more colors (256 or more)

Submitted by:  Peter Liscovius <peterdd>
Submitted on:  Wed 05 Jun 2019 08:08:09 PM UTC
Votes:  100  
 
Severity:  1 - Wish Status:  Fixed
Assigned to:  bens Open/Closed:  Closed
* Mandatory Fields

Add a New Comment (Rich Markup)
   

Comment Type & Canned Response:
       

 

( Jump to the original submission )

Thu 16 Dec 2021 09:59:08 AM UTC, comment #13: 

Released in nano-6.0.  Thanks again for the patches.

Benno Schulenberg <bens>
Project Administrator
Tue 23 Nov 2021 11:15:23 AM UTC, comment #12: 

Thanks.  Both patches applied, the first one in commit 8d6b468c, and the second in 9a778f9a.  (The change in comment coloring I've applied in a separate patch.)

Benno Schulenberg <bens>
Project Administrator
Sun 21 Nov 2021 05:09:17 PM UTC, comment #11: 

Sounds good to me. Updated patch attached.

(file #52316)

Brad Town <townba>
Sun 21 Nov 2021 11:32:57 AM UTC, comment #10: 

I don't think #rgb can be called a "color name".  How about this:

> On such emulators, the color may also be specified as a three-digit hexadecimal
> number prefixed with "#", with the digits representing the amounts of red, green,
> and blue, respectively.  This tells @command{nano} to select from the available
> palette the color that approximates the given values.


Also, [0-9A-Fa-f] is better expressed as [[:xdigit:]] -- see commit f757c4a5 or bug #61487.

(Peter, please stay focussed on the current issue.  If you have other requests: new issue.)

Benno Schulenberg <bens>
Project Administrator
Sun 21 Nov 2021 03:18:49 AM UTC, comment #9: 

Fixed patch attached. It uses Benno Schulenberg's suggestion on nano-devel for handling comments, which I'd forgotten about.

(file #52312)

Brad Town <townba>
Sun 21 Nov 2021 03:06:05 AM UTC, comment #8: 

Hang on -- my patch breaks syntax highlighting in other ways. I'll have to provide another one soon. (Too bad there's no way to delete an attachment.)

Brad Town <townba>
Sun 21 Nov 2021 02:34:30 AM UTC, comment #7: 

Nice to see this is implemented in next version.

Will it also in a later iteration allow to set opacity/transparency values for the background colors?

Something like #rrggbbaa (8 hex characters) red,green,blue,alpha
and shorter #rgba (4 hex characters)

So

- #9000 is a no transparent dark red like #900 or #990000
- and #900f (short for #990000ff) is dark red but full transparant (sic!, as has no effect)
- and #9006 (short for #99000066) is dark red but a background(image) of the terminal shines through?

Peter Liscovius <peterdd>
Sun 21 Nov 2021 02:15:33 AM UTC, comment #6: 

Proposed patch attached.

For the syntax highlighting: Repositioning the "Strings", "Control codes", and "Comments" sections above the others works because the others (except "Trailing whitespace", which should probably always win) all require that they start at the beginning of the line.

(file #52311)

Brad Town <townba>
Sun 21 Nov 2021 01:42:56 AM UTC, comment #5: 

How does this sound? After the existing "On terminal emulators that can do at least 256 colors" paragraphs in both the Texinfo and man page (appropriately tweaked for each format):

> On such emulators, the color name may be given as a three-digit hexadecimal
> number prefixed with "#", with the digits representing red, green, and blue,
> respectively. This allows @command{nano} to select a color from the available
> palette approximating the values given.

Brad Town <townba>
Fri 19 Nov 2021 04:22:22 PM UTC, comment #4: 

There is no response on the mailing list, so it seems that no one objects.

Brad, if you can supply a separate patch that adds the documentation of the new color format, then I will merge the two patches together.  (Just add in the right places a paragraph that describes the format; don't change any of the existing text.)  You may combine it with a syntax change to colorize the new format, or you can supply that as a third patch, if you prefer.

Benno Schulenberg <bens>
Project Administrator
Tue 16 Nov 2021 11:20:28 AM UTC, comment #3: 

Attached is a version of the patch with a more informative commit message.  Further improvements are welcome.

(Earlier patches that provided support for 256 colors were posted at patch #6873 and patch #8553.  And there was a request on the mailing list: https://lists.gnu.org/archive/html/nano-devel/2010-10/msg00000.html.)

(file #52285)

Benno Schulenberg <bens>
Project Administrator
Mon 15 Nov 2021 05:52:55 PM UTC, comment #2: 

Attached patch: rcfile: support "#rgb" format for specifying colors in 256-color terminals

(file #52282)

Brad Town <townba>
Tue 09 Nov 2021 10:33:56 AM UTC, comment #1: 

Brad Town has submitted a patch that looks promising: patch #10131.  It needs some trimming, but... some part of it will make it into nano.

Benno Schulenberg <bens>
Project Administrator
Wed 05 Jun 2019 08:08:09 PM UTC, original submission:  

It seems a lot of console programs and terminal support true colors now:

https://gist.github.com/XVilka/8346728

I would love it if I could adjust the syntax highlighting to more than 16 colors.

Peter Liscovius <peterdd>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by peterdd (Voted in favor of this item)
  • -email is unavailable- added by townba (Updated the item)
  • -email is unavailable- added by bens (Updated the item)
  • -email is unavailable- added by peterdd (Submitted the item)
  •  

    There are 100 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

     

     

     

    Follow 13 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-12-16 bens Open/ClosedOpen => Closed
    2021-11-23 bens StatusIn Progress => Fixed
    2021-11-21 townba Attached File- => Added 0001-Update-documentation-and-syntax-highlighting-for-rgb.patch, #52316
    2021-11-21 townba Attached File- => Added 0001-Update-documentation-and-syntax-highlighting-for-rgb.patch, #52312
    2021-11-21 peterdd Carbon-Copy- => Added peterdd
    2021-11-21 townba Attached File- => Added 0001-Update-documentation-and-syntax-highlighting-for-rgb.patch, #52311
    2021-11-16 bens Attached File- => Added 0001-rcfile-support-rgb-format-for-specifying-colors-in-2.patch, #52285
    2021-11-16 bens Summary[Request] add support for more colors (256, or 16 million) => [Wish] add support for more colors (256 or more)
    2021-11-15 townba Attached File- => Added 0001-rcfile-support-rgb-format-for-specifying-colors-in-2.patch, #52282
    2021-11-09 bens StatusNone => In Progress
        Assigned toNone => bens
    2019-06-06 bens Severity3 - Normal => 1 - Wish
        Summarysupport more colors (256 or 16mio) => [Request] add support for more colors (256, or 16 million)

    Back to the top


    Powered by Savane 3.9