<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.kolmafia.us/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=3D</id>
	<title>Kolmafia - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.kolmafia.us/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=3D"/>
	<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Special:Contributions/3D"/>
	<updated>2026-04-25T00:22:25Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>https://wiki.kolmafia.us/index.php?title=Print&amp;diff=9245</id>
		<title>Print</title>
		<link rel="alternate" type="text/html" href="https://wiki.kolmafia.us/index.php?title=Print&amp;diff=9245"/>
		<updated>2024-11-20T14:55:15Z</updated>

		<summary type="html">&lt;p&gt;3D: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{&lt;br /&gt;
#vardefine:name|print}}{{&lt;br /&gt;
#vardefine:return_type|void}}{{&lt;br /&gt;
&lt;br /&gt;
FunctionPage|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
&lt;br /&gt;
function1={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|string|message}}|&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
function2={{Function|&lt;br /&gt;
name={{#var:name}}|&lt;br /&gt;
aggregate={{#var:aggregate}}|&lt;br /&gt;
return_type={{#var:return_type}}|&lt;br /&gt;
return_also={{#var:return_also}}|&lt;br /&gt;
parameter1={{Param|string|message}}|&lt;br /&gt;
parameter2={{Param|string|color}}|&lt;br /&gt;
p1desc={{Pspan|message}} is the text to print|&lt;br /&gt;
p2desc={{Pspan|color}} is an html color name or code|&lt;br /&gt;
}}|&lt;br /&gt;
function_description=Print the specified text {{pspan|message}} to the CLI. If the optional {{pspan|color}} parameter is specified and a valid html color code or entity, it will print in that color. See the [http://www.w3.org/TR/CSS21/syndata.html#color-units CSS 2.1 color specification] for a description of valid color syntax and keywords.|&lt;br /&gt;
&lt;br /&gt;
code1={{CodeSample|&lt;br /&gt;
title=Code Sample|&lt;br /&gt;
description=Prints stuff in color and black. Note that it prints black twice: first and last.|&lt;br /&gt;
code=&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
print(&amp;quot;This is black.&amp;quot;);&lt;br /&gt;
foreach color in $strings[blue, green, olive, darkorange, magenta, black]&lt;br /&gt;
   print(&amp;quot;This is &amp;quot;+color+&amp;quot;.&amp;quot;, color);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
}}|&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
see_also={{SeeAlso|dump|logprint|print_html|chat_notify}}|&lt;br /&gt;
cli_equiv=The CLI commands &amp;quot;fprint,&amp;quot; &amp;quot;echo&amp;quot; and &amp;quot;fecho&amp;quot; have similar functionality, minus the color option. However, &amp;quot;cecho&amp;quot; (also &amp;quot;colorecho&amp;quot;) does have this option for color.|&lt;br /&gt;
special=A list of common color commands that can be used: maroon, red, orange, yellow, olive, green, lime, teal, aqua, blue, navy, fuchsia, purple, black, gray, silver, white.&amp;lt;br&amp;gt; More advance colors can be used by entering their Hexadecimal code as the string. &amp;lt;br&amp;gt;Using an invalid color name or code can cause odd colors to be chosen; see the [[Talk:Print|Talk Page]] for details.&lt;br /&gt;
&amp;lt;br /&amp;gt;As of r8638, attempting to print a string beginning with a slash(/) will cause KoLmafia to print a blank line instead. To avoid this behavior, you must specify the second argument for the text color. Any color will do, and even a blank string (&amp;lt;code&amp;gt;&amp;quot;&amp;quot;&amp;lt;/code&amp;gt;) will work.&lt;br /&gt;
|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous Functions]]&lt;/div&gt;</summary>
		<author><name>3D</name></author>
	</entry>
</feed>