From WikiChip
Difference between revisions of "mirc/commands/aline"
< mirc‎ | commands

m
Line 1: Line 1:
The '''aline command''' is used to add a single line of text to a custom window or a list. This command is limited to custom @windows, If you need a more general command that is able to print to both custom windows, channel, and query consider using the /echo command instead, note also that if the list is sorted (-S or -s has been used), lines added with /echo won't be sorted.
+
The '''aline command''' is used to add a single line of text to a custom window. This command is limited to custom @windows, If you need a more general command that is able to print to both custom windows, channel, and query consider using the /echo command instead.
 +
'''Note:''' If the main window is sorted (text or listbox and /window -s has been used), lines added with /echo to that window won't be sorted, only lines added with /aline will.
  
 
== Synopsis ==
 
== Synopsis ==
Line 5: Line 6:
  
 
== Switches ==
 
== Switches ==
* '''-s''' - Clears the old selection in a list and selects the newly added item  
+
* '''-s''' - Clears the old selection in a listbox and selects the newly added item  
* '''-a''' - Selects the newly added item while keeping the old selection in a list
+
* '''-a''' - Selects the newly added item while keeping the old selection in a listbox
 
* '''-h''' - Highlights the window's node in the treebar is the window is minimized
 
* '''-h''' - Highlights the window's node in the treebar is the window is minimized
* '''-p''' - Forces the line to be wrapped if it's too long to fit in on one line (does not apply to lists)
+
* '''-p''' - Forces the line to be wrapped if it's too long to fit in on one line (does not apply to listboxes)
* '''-i''' - Indent the newly added line
+
* '''-i''' - Indent the newly added line (does not apply to listboxes)
 
* '''-n''' - Prevent the line from being added if already exists
 
* '''-n''' - Prevent the line from being added if already exists
 
* '''-l''' - Specify the action to take place on the side-listbox
 
* '''-l''' - Specify the action to take place on the side-listbox
Line 21: Line 22:
 
== Example ==
 
== Example ==
 
<syntaxhighlight lang="mIRC">Alias Example {
 
<syntaxhighlight lang="mIRC">Alias Example {
   ;open a desktop custom window (listbox and with an editbox)
+
   ;open a desktop custom window (main window is a listbox, no side-listbox and with an editbox)
 
   Window -lde @Foo
 
   Window -lde @Foo
  

Revision as of 13:33, 22 December 2013

The aline command is used to add a single line of text to a custom window. This command is limited to custom @windows, If you need a more general command that is able to print to both custom windows, channel, and query consider using the /echo command instead. Note: If the main window is sorted (text or listbox and /window -s has been used), lines added with /echo to that window won't be sorted, only lines added with /aline will.

Synopsis

/aline -sahpinl [c] <@name> <text>

Switches

  • -s - Clears the old selection in a listbox and selects the newly added item
  • -a - Selects the newly added item while keeping the old selection in a listbox
  • -h - Highlights the window's node in the treebar is the window is minimized
  • -p - Forces the line to be wrapped if it's too long to fit in on one line (does not apply to listboxes)
  • -i - Indent the newly added line (does not apply to listboxes)
  • -n - Prevent the line from being added if already exists
  • -l - Specify the action to take place on the side-listbox

Parameters

  • [c] - An optional color number for the line
  • <@name> - The name of the window
  • <text> - The text to be added

Example

Alias Example {
  ;open a desktop custom window (main window is a listbox, no side-listbox and with an editbox)
  Window -lde @Foo
 
  ;Add a line, line colored in yellow (8)
  Aline 8 @Foo Line A
 
  ;Add a line, color Dark Green (3), selected, clear old selection
  Aline -s 3 @Foo Line B
}

Compatibility

Added: mIRC v5.0

Added On: 02/04/97

Note: Individual switches were not taken into consideration.

See also