ascii 图表(测试显示效果)

ascii 图表

测试 ascii 图形在blog中的显示效果的文章
window chrome 下显示 ascii效果最好, mac 差一些。

英文框型

         +---+         
         |V7 |         
         +---+         
           |           
           v           
       +-------+       
       |  V1   |       
       +-------+       
         |  ||         
     -----  |--------  
     |      ---     |  
     v        |     |  
  +-----+     |     |  
  | V2  |     |     |  
  +-----+     |     |  
    | |       |     |  
  --- ---     |     |  
  |     |     |     |  
  v     v     v     v  
+---+ +---+ +---+ +---+
|V5 | |V6 | |V4 | |V3 |
+---+ +---+ +---+ +---+

中文框型

                         +--------+
                         |  顶框  |
                         +--+-----+
               +------------+----------------+
               |                             |
          +----+----+                    +---+---+
          |  左框1  |                    | 右框1 |
          +---------+                    +-------+

C语言

#include "stdio.h"
int main(int argc,char* argv[])
{
    printf("hello world");
    return 0;
}

C语言之二

#include <iostream>

int main(int argc, char *argv[]) {

  /* An annoying "Hello World" example */
  for (auto i = 0; i < 0xFFFF; i++)
    cout << "Hello, World!" << endl;

  char c = '\n';
  unordered_map <string, vector<string> > m;
  m["key"] = "\\\\"; // this is an error

  return -2e3 + 12l;
}

ascii表格

+-----------------------------------------------------------------------------+
|                   |                   |                   |                 |
|    title 1        |     title 2       |     title 3       |     title 4     |
|                   |                   |                   |                 |
+-------------------+-------------------+-------------------+-----------------+
|                   |                   |    bla bla        |                 |
| bla bla           |                   |    bla bla bla    |                 |
| bla bla bla       |    bla bla        |    bla bla bla ...| bla bla         |
| bla bla bla ...   |    bla bla bla    |                   | bla bla bla     |
|                   |    bla bla bla ...|                   | bla bla bla ... |
|                   |                   |                   |                 |
|                   |                   |                   |                 |
+-----------------------------------------------------------------------------+

ascii椭圆形


         ***********                  ***********
     ****           ****          ****           ****
  ***                   ***    ***                   ***
 *                         *  *                         *
*         ellipse           **        ellipse            *
*         ellipse...        **        ellipse...         *
*         ellipse..         **        ellipse..          *
 *                         *  *                         *
  ***                   ***    ***                   ***
     ****           ****          ****           ****
         ***********                  ***********

ascii 箭头线


                            -----                                             -----                       
                      -----/     \----                                   ----/     \----                  
                -----/                \----                         ----/               \----             
          -----/                           \----               ----/                         \----        
    -----/                                      \----     ----/                                   \----   
---/                                                 \---/                                             \->

小箭头

                  ^
                  |
           <------+------> 
                  |
                  v

大箭头

                  . 
                 /_\
                  |
                  |
         <|-------+--------|>
                  |
                 _|_
                 \ /
                  ' 

自由画(鼠标画人头)

           ************ 
          **********************
       ******  *************** ****  
     **********           *** ******* 
   *****                    ***    ** 
     **                       **      
     *                          *  
     *      *          *        ** 
     *                           * 
     *                           * 
     **                         ** 
      *                  *     **  
      **         *    ***     **  
       **        ******     ***  
         *                ***   
          ***            **   
            **         ***  
              ****   **                                                                       
                  ****  

自由画(复制人头)

                                                          ************              
                                                        **********************     
                                                     ******  *************** ****  
                                                   **********           *** *******
                                                 *****                    ***    **
                                                   **                       **     
                                                   *                          *    
                                                   *      *          *        **   
            ************                           *                           *   
           **********************                  *                           *   
        ******  *************** ****               **                         **   
      **********           *** *******              *                  *     **    
    *****                    ***    **              **         *    ***     **     
      **                       **                    **        ******     ***      
      *                          *                     *                ***        
      *      *          *        **                     ***            **          
      *                           *                       **         ***           
      *                           *                         ****   **              
      **                         **                             ****               
       *                  *     **                                                 
       **         *    ***            ************                                 
        **        ******     *       ********************                          
          *                ***    ******  *************** ****                     
           ***            **    **********           *** *******                   
             **         ***   *****                    ***    **                   
               ****   **        **                       **                        
                   ****         *                          *                       
                                *      *          *        **                      
                                *                           *                      
                                *                           *                      
                                **                         **                      
                                 *                  *     **                       
                                 **         *    ***     **                        
                                  **        ******     ***                         
                                    *                ***                           
                                     ***            **                             
                                       **         ***                              
                                         ****   **                                 
                                             ****                                  

graphviz

digraph example3 {
Server1 -> Server2
Server2 -> Server3
Server3 -> Server1

Server1 [shape=box, label="Server1\nWeb Server", fillcolor="#ABACBA", style=filled]
Server2 [shape=triangle, label="Server2\nApp Server", fillcolor="#DDBCBC", style=filled]
Server3 [shape=circle, label="Server3\nDatabase Server", fillcolor="#FFAA22",style=filled]
}

标签: none



添加新评论