Project

General

Profile

Formatting text » History » Revision 29

Revision 28 (Per Amundsen, 05/17/2015 03:14 AM) → Revision 29/83 (Per Amundsen, 05/17/2015 03:15 AM)

{{>toc}} 

 h1. Formatting text 

 AdiIRC supports control codes for formatting text. 

 All control codes can be combined to format the same block. 

 h1. Colorchar 

 Colors blocks of text. 

 Ascii character [[$chr]](3) 

 Ctrl + K can be used in editbox to type this character. 

 The character can be followed by 1-2 digits that represent the color number. 

 By specifying a comma after the digits, you can add a 1-2 digit background color as well. 

 The default colors can be changed in Options -> Colors -> mIRC Colors. 

 A second color character can be used to stop the coloring and revert to default line color. 

 *Example* 
 <pre> 
 ; Prints the text 'Hello World' with color 4 which is red by default. 
 //echo -ag $chr(3) $+ 3 Hello world 
 </pre> 

 Result: %{color:#FF0000}Hello World% 

 <pre> 
 ; Prints the text 'Hello' with color 4 which is red by default and 'world' is the default line color. 
 //echo -ag $chr(3) $+ 3 Hello $+ $chr(3) $+ world 
 </pre> 

 Result: %{color:#FF0000}Hello% world 

 </pre> 
 ; Prints the text 'Hello World' with color 4 which is red by default and background color 12 which is blue by default. 
 //echo -ag $chr(3) $+ 3,12 Hello world 
 </pre> 

 Result: %{background:#0000CC;color:#FF0000}Hello world% 

 h1. Boldchar  

 Makes the block use a *bold* font. 

 Ascii character [[$chr]](2) 

 Ctrl + B can be used in editbox to type this character. 

 *Example* 
 <pre> 
 //echo -ag $chr(2) this text is bold $chr(2) this text is not 
 </pre> 

 Result: *this text is bold* this text is not 

 h1. Italicchar  

 Makes the block use a _italic_ font. 

 Ascii character [[$chr]](29) 

 Ctrl + I can be used in editbox to type this character. 

 *Example* 
 <pre> 
 //echo -ag $chr(2) this text is italic $chr(29) this text is not 
 </pre> 

 Result: _this text is italic_ this text is not 

 h1. Underlinechar  

 Makes the block use a +underline+ font. 

 Ascii character [[$chr]](31) 

 Ctrl + U can be used in editbox to type this character. 

 *Example* 
 <pre> 
 //echo -ag $chr(2) this text is underline $chr(31) this text is not 
 </pre> 

 Result: +this text is underline+ this text is not 

 h1. Stopchar  

 Stops all color and font formatting. 

 Ascii character [[$chr]](15) 

 Ctrl + O    can be used in editbox to type this character. 

 *Example* 

 <pre> 
 //echo -ag $chr(3) $+ 4 $+ $chr(2) this text is bold and colored $chr(15) this text is not 
 </pre> 

 Result: %(color:#FF0000} *this %(color:#FF0000}*this text is bold and colored* % colored*% this text is not 

 h1. Alternative colorchar  

 AdiIRC has an alterinative color character as of 1.9.7, this is AdiIRC only. 

 Unicode character [[$chr]](61442) 

 Works the same as colorchar, except it takes a hexcolor format RRGGBB same as html colors. 

 A second color character can be used to stop the coloring and revert to default line color. 

 *Example* 
 <pre> 
 ; Prints the text 'Hello World' with hex color FF0000 which is red. 
 //echo -ag $chr(61442) $+ FF0000 Hello world 
 </pre> 

 Result: %{color:#FF0000}Hello World% 

 <pre> 
 ; Prints the text 'Hello' with with hex color FF0000 which is red and 'world' is the default line color. 
 //echo -ag $chr(61442) $+ FF0000 Hello $+ $chr(61442) $+ world 
 </pre> 

 Result: %{color:#FF0000}Hello% world 

 <pre> 
 ; Prints the text 'Hello World' with hex color FF0000 which is red and hex background color 0000CC which is bluet. 
 //echo -ag $chr(61442) $+ FF0000,0000CC Hello world 
 </pre> 

 Result: %{background:#0000CC;color:#FF0000}Hello world%