$font » History » Version 9
Per Amundsen, 02/22/2023 04:45 PM
| 1 | 1 | Per Amundsen | _Added in 1.9.6_ |
|---|---|---|---|
| 2 | |||
| 3 | 5 | Per Amundsen | *$font(N|name, t)* |
| 4 | 1 | Per Amundsen | |
| 5 | 6 | Per Amundsen | Returns the Nth installed font. |
| 6 | 1 | Per Amundsen | |
| 7 | *Parameters* |
||
| 8 | |||
| 9 | 9 | Per Amundsen | table(ktable). |
| 10 | |*Parameter*|*Description*| |
||
| 11 | | N<notextile>|</notextile>name | Get the name of the Nth font, if N is 0, returns number of fonts. If a font name is entered, returns [[$true]] if the font is installed, otherwise [[$false]]. | |
||
| 12 | | t | List only truetype fonts. *(AdiIRC only)* | |
||
| 13 | 3 | Per Amundsen | |
| 14 | *Example* |
||
| 15 | |||
| 16 | <pre> |
||
| 17 | ; Get number of installed fonts. |
||
| 18 | //echo -ag $font(0) |
||
| 19 | |||
| 20 | ; Check if 'Verdana' is installed. |
||
| 21 | if ($font(Verdana)) { |
||
| 22 | echo -ag Verdana is installed |
||
| 23 | } |
||
| 24 | else { |
||
| 25 | echo -ag Verdana is not installed |
||
| 26 | } |
||
| 27 | </pre> |