Sha256: 8f478256500d312c68097da47447bc0255992c3fc73ff032427798109239b033

Contents?: true

Size: 1.27 KB

Versions: 4

Compression:

Stored size: 1.27 KB

Contents

# string-irc - Add color codes for mIRC compatible client.

[![Build Status](https://secure.travis-ci.org/banyan/string-irc.png)](http://travis-ci.org/banyan/string-irc)
[<img src="https://gemnasium.com/banyan/string-irc.png" />](https://gemnasium.com/banyan/string-irc)
Description
---

Port of http://search.cpan.org/~hirose/String-IRC-0.04/ from Perl to Ruby.

Compatibility
---

Tested under Ruby 1.9.2 and Ruby 1.8.7.

See current status at [Travis CI](http://travis-ci.org/banyan/string-irc).

Getting Started
---

    require 'string-irc'

    si1 = StringIrc.new('hello')
    si1.red.underline
    si2 = StringIrc.new('world').yellow('green').bold
    msg = "#{si1.to_s} #{si2.to_s}" # You must add #to_s, this is the diffrence from original.

Usage
---

    si.COLOR([BG_COLOR])

    Add color code and return StringIRC object. BG_COLOR is
    optional. Available COLOR and BC_COLOR are as follows.

    white
    black
    blue navy
    green
    red
    brown maroon
    purple
    orange olive
    yellow
    light_green lime
    teal a_green blue_cyan
    light_cyan cyan aqua
    light_blue royal
    pink light_purple fuchsia
    grey
    light_grey silver

    #bold, #underline, #inverse are available method.

    si.bold
    si.underline
    si.inverse

Copyright
---

MIT License

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
string-irc-0.2.3 README.md
string-irc-0.2.2 README.md
string-irc-0.2.1 README.md
string-irc-0.2.0 README.md