<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/wiki/HU/guiSetFont?action=history&amp;feed=atom</id>
	<title>HU/guiSetFont - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/wiki/HU/guiSetFont?action=history&amp;feed=atom"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=HU/guiSetFont&amp;action=history"/>
	<updated>2026-04-14T10:14:56Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=HU/guiSetFont&amp;diff=61326&amp;oldid=prev</id>
		<title>Surge: Created page with &quot;{{Client function}} __NOTOC__ This function sets the font of a GUI element to be used when drawing text.  ==Syntax==  &lt;syntaxhighlight lang=&quot;lua&quot;&gt; bool guiSetF...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=HU/guiSetFont&amp;diff=61326&amp;oldid=prev"/>
		<updated>2018-12-09T19:09:39Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{Client function}} __NOTOC__ This function sets the font of a &lt;a href=&quot;/wiki/GUI_widgets&quot; title=&quot;GUI widgets&quot;&gt;GUI element&lt;/a&gt; to be used when drawing text.  ==Syntax==  &amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; bool guiSetF...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Client function}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function sets the font of a [[GUI_widgets|GUI element]] to be used when drawing text.&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool guiSetFont ( element guiElement, mixed font )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{OOP||[[GUI widgets|GuiElement]]:setFont|font|guiGetFont}}&lt;br /&gt;
&lt;br /&gt;
===Required Arguments===&lt;br /&gt;
*'''guiElement:''' The GUI element you wish to change the font of&lt;br /&gt;
*'''font:''' Either a custom [[GUI font]] element or the name of a built-in GUI font. See [[Standard GUI Font Names]]&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns ''true'' if the font has been successfully set on the gui element, ''false'' otherwise.&lt;br /&gt;
&lt;br /&gt;
==Example== &lt;br /&gt;
&amp;lt;!-- Explain what the example is in a single sentence --&amp;gt;&lt;br /&gt;
This example sets and gets the font of a pre-made gui element and outputs it to chat box.&lt;br /&gt;
&amp;lt;!-- Add the code below, an emphasis should be on making it clear, not optimized. You could provide two versions if you wish, one clear and well commented, the other optimized --&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- We create a dummy gui label to get text of&lt;br /&gt;
local dummyGUIElement = guiCreateLabel ( 0.45, 0.48, 0.10, 0.04, &amp;quot;Hello world&amp;quot;, true )&lt;br /&gt;
guiSetFont ( dummyGUIElement, &amp;quot;sa-gothic&amp;quot; )&lt;br /&gt;
-- Output the font of the label to chat box&lt;br /&gt;
outputChatBox ( &amp;quot;Font used in the GUI label: &amp;quot; .. guiGetFont ( dummyGuiElement ) )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{GUI_functions}}&lt;br /&gt;
{{GUI_events}}&lt;br /&gt;
&lt;br /&gt;
[[en:guiSetFont]]&lt;br /&gt;
[[pl:guiSetFont]]&lt;/div&gt;</summary>
		<author><name>Surge</name></author>
	</entry>
</feed>