Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: In Term::ANSIColor grey color is present or not.

by Athanasius (Archbishop)
on Mar 30, 2022 at 06:19 UTC ( [id://11142522]=note: print w/replies, xml ) Need Help??


in reply to In Term::ANSIColor grey color is present or not.

I don’t use this module, but just looking through the documentation, it seems you have to specify a shade of grey in the range grey0 .. grey23. For example, print colored(['grey12'], "Text on grey color\n"); should work.

Hope that helps,

Athanasius <°(((><contra mundum Iustus alius egestas vitae, eros Piratica,

Replies are listed 'Best First'.
Re^2: In Term::ANSIColor grey color is present or not.
by Anonymous Monk on Mar 30, 2022 at 06:22 UTC

    grey0 also should work right but for me it is also getting error

    Invalid attribute name grey0

      Ok, I dusted off my old Cygwin terminal and got Term::ANSIColor working. grey0 looks the same as black, but prints fine with no error message. grey with no number gives the error message you reported first.

      I don’t know what to suggest. Maybe if you detail your setup (OS, Perl version, Term::ANSIColor version, terminal type) some of the other monks will be able to shed some light.

      Cheers,

      Athanasius <°(((><contra mundum Iustus alius egestas vitae, eros Piratica,

      I am unable to reproduce your findings (with version 4.03):

      $ perl -MTerm::ANSIColor -e 'print color("grey0"), "foo\n", color("res +et")' foo $

      🦛

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11142522]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2024-04-23 17:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found