Blob Blame History Raw
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GtkSourceStyle: GtkSourceView 3 Reference Manual</title>
<meta name="generator" content="DocBook XSL Stylesheets Vsnapshot">
<link rel="home" href="index.html" title="GtkSourceView 3 Reference Manual">
<link rel="up" href="ch03.html" title="Styling">
<link rel="prev" href="ch03.html" title="Styling">
<link rel="next" href="GtkSourceStyleScheme.html" title="GtkSourceStyleScheme">
<meta name="generator" content="GTK-Doc V1.28.1 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description">  <span class="dim">|</span> 
                  <a href="#GtkSourceStyle.description" class="shortcut">Description</a></span><span id="nav_hierarchy">  <span class="dim">|</span> 
                  <a href="#GtkSourceStyle.object-hierarchy" class="shortcut">Object Hierarchy</a></span><span id="nav_properties">  <span class="dim">|</span> 
                  <a href="#GtkSourceStyle.properties" class="shortcut">Properties</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="ch03.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="ch03.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="GtkSourceStyleScheme.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="GtkSourceStyle"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="GtkSourceStyle.top_of_page"></a>GtkSourceStyle</span></h2>
<p>GtkSourceStyle — Represents a style</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="GtkSourceStyle.functions"></a><h2>Functions</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="functions_return">
<col class="functions_name">
</colgroup>
<tbody>
<tr>
<td class="function_type">
<a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="returnvalue">GtkSourceStyle</span></a> *
</td>
<td class="function_name">
<a class="link" href="GtkSourceStyle.html#gtk-source-style-copy" title="gtk_source_style_copy ()">gtk_source_style_copy</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="GtkSourceStyle.html#gtk-source-style-apply" title="gtk_source_style_apply ()">gtk_source_style_apply</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.properties"></a><h2>Properties</h2>
<div class="informaltable"><table class="informaltable" border="0">
<colgroup>
<col width="150px" class="properties_type">
<col width="300px" class="properties_name">
<col width="200px" class="properties_flags">
</colgroup>
<tbody>
<tr>
<td class="property_type">
<span class="type">gchar</span> *</td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--background" title="The “background” property">background</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--background-set" title="The “background-set” property">background-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--bold" title="The “bold” property">bold</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--bold-set" title="The “bold-set” property">bold-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type">
<span class="type">gchar</span> *</td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--foreground" title="The “foreground” property">foreground</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--foreground-set" title="The “foreground-set” property">foreground-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--italic" title="The “italic” property">italic</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--italic-set" title="The “italic-set” property">italic-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type">
<span class="type">gchar</span> *</td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--line-background" title="The “line-background” property">line-background</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--line-background-set" title="The “line-background-set” property">line-background-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">PangoUnderline</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--pango-underline" title="The “pango-underline” property">pango-underline</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type">
<span class="type">gchar</span> *</td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--scale" title="The “scale” property">scale</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--scale-set" title="The “scale-set” property">scale-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--strikethrough" title="The “strikethrough” property">strikethrough</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--strikethrough-set" title="The “strikethrough-set” property">strikethrough-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--underline" title="The “underline” property">underline</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type">
<span class="type">gchar</span> *</td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--underline-color" title="The “underline-color” property">underline-color</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--underline-color-set" title="The “underline-color-set” property">underline-color-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
<tr>
<td class="property_type"><span class="type">gboolean</span></td>
<td class="property_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle--underline-set" title="The “underline-set” property">underline-set</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="name">
<col class="description">
</colgroup>
<tbody><tr>
<td class="datatype_keyword"> </td>
<td class="function_name"><a class="link" href="GtkSourceStyle.html#GtkSourceStyle-struct" title="GtkSourceStyle">GtkSourceStyle</a></td>
</tr></tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="screen">    GObject
    <span class="lineart">╰──</span> GtkSourceStyle
</pre>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.includes"></a><h2>Includes</h2>
<pre class="synopsis">#include &lt;gtksourceview/gtksource.h&gt;
</pre>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.description"></a><h2>Description</h2>
<p>The <a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="type">GtkSourceStyle</span></a> structure is used to describe text attributes
which are set when given style is used.</p>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="gtk-source-style-copy"></a><h3>gtk_source_style_copy ()</h3>
<pre class="programlisting"><a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="returnvalue">GtkSourceStyle</span></a> *
gtk_source_style_copy (<em class="parameter"><code>const <a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="type">GtkSourceStyle</span></a> *style</code></em>);</pre>
<p>Creates a copy of <em class="parameter"><code>style</code></em>
, that is a new <a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="type">GtkSourceStyle</span></a> instance which
has the same attributes set.</p>
<div class="refsect3">
<a name="gtk-source-style-copy.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>style</p></td>
<td class="parameter_description"><p>a <a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="type">GtkSourceStyle</span></a> structure to copy.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="gtk-source-style-copy.returns"></a><h4>Returns</h4>
<p>copy of <em class="parameter"><code>style</code></em>
, call <code class="function">g_object_unref()</code>
when you are done with it. </p>
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="api-index-2-0.html#api-index-2.0">2.0</a></p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-source-style-apply"></a><h3>gtk_source_style_apply ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
gtk_source_style_apply (<em class="parameter"><code>const <a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="type">GtkSourceStyle</span></a> *style</code></em>,
                        <em class="parameter"><code><span class="type">GtkTextTag</span> *tag</code></em>);</pre>
<p>This function modifies the <span class="type">GtkTextTag</span> properties that are related to the
<a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="type">GtkSourceStyle</span></a> properties. Other <span class="type">GtkTextTag</span> properties are left untouched.</p>
<p>If <em class="parameter"><code>style</code></em>
 is non-<code class="literal">NULL</code>, applies <em class="parameter"><code>style</code></em>
 to <em class="parameter"><code>tag</code></em>
.</p>
<p>If <em class="parameter"><code>style</code></em>
 is <code class="literal">NULL</code>, the related *-set properties of <span class="type">GtkTextTag</span> are set to
<code class="literal">FALSE</code>.</p>
<div class="refsect3">
<a name="gtk-source-style-apply.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>style</p></td>
<td class="parameter_description"><p>a <a class="link" href="GtkSourceStyle.html" title="GtkSourceStyle"><span class="type">GtkSourceStyle</span></a> to apply, or <code class="literal">NULL</code>. </p></td>
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL may be passed as the value in, out, in-out; or as a return value."><span class="acronym">nullable</span></acronym>]</span></td>
</tr>
<tr>
<td class="parameter_name"><p>tag</p></td>
<td class="parameter_description"><p>a <span class="type">GtkTextTag</span> to apply styles to.</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<p class="since">Since: <a class="link" href="api-index-3-22.html#api-index-3.22">3.22</a></p>
</div>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="GtkSourceStyle-struct"></a><h3>GtkSourceStyle</h3>
<pre class="programlisting">typedef struct _GtkSourceStyle GtkSourceStyle;</pre>
</div>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.property-details"></a><h2>Property Details</h2>
<div class="refsect2">
<a name="GtkSourceStyle--background"></a><h3>The <code class="literal">“background”</code> property</h3>
<pre class="programlisting">  “background”               <span class="type">gchar</span> *</pre>
<p>Background color.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: NULL</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--background-set"></a><h3>The <code class="literal">“background-set”</code> property</h3>
<pre class="programlisting">  “background-set”           <span class="type">gboolean</span></pre>
<p>Whether background color is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--bold"></a><h3>The <code class="literal">“bold”</code> property</h3>
<pre class="programlisting">  “bold”                     <span class="type">gboolean</span></pre>
<p>Bold.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--bold-set"></a><h3>The <code class="literal">“bold-set”</code> property</h3>
<pre class="programlisting">  “bold-set”                 <span class="type">gboolean</span></pre>
<p>Whether bold attribute is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--foreground"></a><h3>The <code class="literal">“foreground”</code> property</h3>
<pre class="programlisting">  “foreground”               <span class="type">gchar</span> *</pre>
<p>Foreground color.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: NULL</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--foreground-set"></a><h3>The <code class="literal">“foreground-set”</code> property</h3>
<pre class="programlisting">  “foreground-set”           <span class="type">gboolean</span></pre>
<p>Whether foreground color is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--italic"></a><h3>The <code class="literal">“italic”</code> property</h3>
<pre class="programlisting">  “italic”                   <span class="type">gboolean</span></pre>
<p>Italic.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--italic-set"></a><h3>The <code class="literal">“italic-set”</code> property</h3>
<pre class="programlisting">  “italic-set”               <span class="type">gboolean</span></pre>
<p>Whether italic attribute is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--line-background"></a><h3>The <code class="literal">“line-background”</code> property</h3>
<pre class="programlisting">  “line-background”          <span class="type">gchar</span> *</pre>
<p>Line background color.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: NULL</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--line-background-set"></a><h3>The <code class="literal">“line-background-set”</code> property</h3>
<pre class="programlisting">  “line-background-set”      <span class="type">gboolean</span></pre>
<p>Whether line background color is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--pango-underline"></a><h3>The <code class="literal">“pango-underline”</code> property</h3>
<pre class="programlisting">  “pango-underline”          <span class="type">PangoUnderline</span></pre>
<p>Pango Underline.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: PANGO_UNDERLINE_NONE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--scale"></a><h3>The <code class="literal">“scale”</code> property</h3>
<pre class="programlisting">  “scale”                    <span class="type">gchar</span> *</pre>
<p>Text scale factor.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: NULL</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--scale-set"></a><h3>The <code class="literal">“scale-set”</code> property</h3>
<pre class="programlisting">  “scale-set”                <span class="type">gboolean</span></pre>
<p>Whether scale attribute is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--strikethrough"></a><h3>The <code class="literal">“strikethrough”</code> property</h3>
<pre class="programlisting">  “strikethrough”            <span class="type">gboolean</span></pre>
<p>Strikethrough.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--strikethrough-set"></a><h3>The <code class="literal">“strikethrough-set”</code> property</h3>
<pre class="programlisting">  “strikethrough-set”        <span class="type">gboolean</span></pre>
<p>Whether strikethrough attribute is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--underline"></a><h3>The <code class="literal">“underline”</code> property</h3>
<pre class="programlisting">  “underline”                <span class="type">gboolean</span></pre>
<p>Underline.</p>
<div class="warning">
<p><code class="literal">GtkSourceStyle:underline</code> has been deprecated since version 3.18 and should not be used in newly-written code.</p>
<p>Use pango-underline.</p>
</div>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--underline-color"></a><h3>The <code class="literal">“underline-color”</code> property</h3>
<pre class="programlisting">  “underline-color”          <span class="type">gchar</span> *</pre>
<p>Underline color.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: NULL</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--underline-color-set"></a><h3>The <code class="literal">“underline-color-set”</code> property</h3>
<pre class="programlisting">  “underline-color-set”      <span class="type">gboolean</span></pre>
<p>Whether underline color attribute is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
<hr>
<div class="refsect2">
<a name="GtkSourceStyle--underline-set"></a><h3>The <code class="literal">“underline-set”</code> property</h3>
<pre class="programlisting">  “underline-set”            <span class="type">gboolean</span></pre>
<p>Whether underline attribute is set.</p>
<p>Flags: Read / Write / Construct Only</p>
<p>Default value: FALSE</p>
</div>
</div>
<div class="refsect1">
<a name="GtkSourceStyle.see-also"></a><h2>See Also</h2>
<p><a class="link" href="GtkSourceStyleScheme.html" title="GtkSourceStyleScheme"><span class="type">GtkSourceStyleScheme</span></a>, <a class="link" href="GtkSourceStyleSchemeManager.html" title="GtkSourceStyleSchemeManager"><span class="type">GtkSourceStyleSchemeManager</span></a></p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28.1</div>
</body>
</html>