Code Monkey home page Code Monkey logo

colodot's Introduction

Colo[dot]rs

Easy-to-use, powerful Rust implementation of Colorized library.

colodot!(DotTypes::Bold, DotColors::Red,   "Hello, red!\n",   true);
colodot!(DotTypes::Light,DotColors::Green, "Hello, green!\n", true);
colodot!(DotTypes::Blink,DotColors::Blue,  "Hello, blue!\n",  true);

red()  ; println!("{}", "Hello, red!"  );
green(); println!("{}", "Hello, green!");
blue() ; println!("{}", "Hello, blue!" );

colodot!  (colodot::dot::DotTrueColor{r: 255, g: 255, b: 255}, "Hello, world!\n");
colodottc!(colodot::dot::DotTrueColor{r: 12 , g: 50, b: 40  }, "Hello, world!"  );

colodot!  (from_hex(0xffffff), "Hello, world!\n");

colodottc!(colodot::dot::DotTrueColor{r: 200, g: 100, b: 12 }, "Hello, world!", true);
        
true_color   (1  , 1 , 1 , &["Hello", " , ", "world", "!"]);
bg_true_color(230, 15, 60, &["Hello", " , ", "world", "!"]);

basic_true_color   (colodot::dot::DotTrueColor{r: 5  , g: 5 , b: 5 }, "Hello, world!");
basic_bg_true_color(colodot::dot::DotTrueColor{r: 235, g: 20, b: 65}, "Hello, world!");

How to use?

Add this code-block to your Cargo.toml

[dependencies]
colodot = "0.1.5"

and Do not forget to add this to your main.rs or lib.rs

#[macro_use]
extern crate colodot;

use colodot::dot::*;

fn main() {
    colodot!(colodot::dot::DotTrueColor{r: 255, g: 255, b: 255}, "Huhuuu ^-^!\n");
}

TODO:

  • Formatter support.
  • PowerShell support. (Windows)
  • More tests.

Colo[dot]rs licensed under the terms of MIT License.

colodot's People

Contributors

ferhatgec avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.