Sophie

Sophie

distrib > Mandriva > 2011.0 > i586 > by-pkgid > a16d689bc65aac5d987d5129109e6de5 > files > 423

irrlicht-doc-1.7.2-1.i586.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Irrlicht Engine: irr::gui::IGUIElementFactory Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<table class="irrlicht" >
  <tr valign="middle"> 
    <td><font size="2"><a class="qindex" href="index.html"><font color="#FFFFFF">Home</font></a> 
      | <a class="qindex" href="namespaces.html"><font color="#FFFFFF">Namespaces</font></a> 
      | <a class="qindex" href="hierarchy.html"><font color="#FFFFFF">Hierarchy</font></a> 
      | <a class="qindex" href="classes.html"><font color="#FFFFFF">Alphabetical 
      List</font></a> | <a class="qindex" href="annotated.html"><font color="#FFFFFF"> 
      Class list</font></a> | <a class="qindex" href="files.html"><font color="#FFFFFF">Files</font></a> 
      | <a class="qindex" href="namespacemembers.html"><font color="#FFFFFF"> 
      Namespace&nbsp;Members</font></a> | <a class="qindex" href="functions.html"><font color="#FFFFFF">Class 
      members</font></a> | <a class="qindex" href="globals.html"><font color="#FFFFFF">File 
      members</font></a> | <a class="qindex" href="pages.html"><font color="#FFFFFF">Tutorials</font></a></font> </td>
  </tr>
</table>
<!-- Generated by Doxygen 1.6.2 -->
  <div class="navpath"><a class="el" href="namespaceirr.html">irr</a>::<a class="el" href="namespaceirr_1_1gui.html">gui</a>::<a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html">IGUIElementFactory</a>
  </div>
<div class="contents">
<h1>irr::gui::IGUIElementFactory Class Reference</h1><!-- doxytag: class="irr::gui::IGUIElementFactory" --><!-- doxytag: inherits="irr::IReferenceCounted" -->
<p>Interface making it possible to dynamically create GUI elements.  
<a href="#_details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_i_g_u_i_element_factory_8h_source.html">IGUIElementFactory.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for irr::gui::IGUIElementFactory:</div>
<div class="dynsection">
 <div class="center">
  <img src="classirr_1_1gui_1_1_i_g_u_i_element_factory.png" usemap="#irr::gui::IGUIElementFactory_map" alt=""/>
  <map id="irr::gui::IGUIElementFactory_map" name="irr::gui::IGUIElementFactory_map">
<area href="classirr_1_1_i_reference_counted.html" alt="irr::IReferenceCounted" shape="rect" coords="0,0,165,24"/>
</map>
 </div>
</div>

<p><a href="classirr_1_1gui_1_1_i_g_u_i_element_factory-members.html">List of all members.</a></p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td colspan="2"><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#aec55be9ef891ba1b19c5d9c5a85130a4">addGUIElement</a> (const <a class="el" href="namespaceirr.html#a9395eaea339bcb546b319e9c96bf7410">c8</a> *typeName, <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a> *parent=0)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">adds a GUI element to the GUI Environment based on its type name  <a href="#aec55be9ef891ba1b19c5d9c5a85130a4"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#aaaa0dda5493286ff745310b441347019">addGUIElement</a> (<a class="el" href="namespaceirr_1_1gui.html#ae4d66df0ecf4117cdbcf9f22404bd254">EGUI_ELEMENT_TYPE</a> type, <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a> *parent=0)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">adds an element to the gui environment based on its type id  <a href="#aaaa0dda5493286ff745310b441347019"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="namespaceirr.html#ac66849b7a6ed16e30ebede579f9b47c6">s32</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#aae56378de5264978e70d11a36fff02e9">getCreatableGUIElementTypeCount</a> () const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get amount of GUI element types this factory is able to create.  <a href="#aae56378de5264978e70d11a36fff02e9"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="namespaceirr_1_1gui.html#ae4d66df0ecf4117cdbcf9f22404bd254">EGUI_ELEMENT_TYPE</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#a9318ddb2d0d971551db4c050c3f99a2f">getCreateableGUIElementType</a> (<a class="el" href="namespaceirr.html#ac66849b7a6ed16e30ebede579f9b47c6">s32</a> idx) const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get type of a createable element type.  <a href="#a9318ddb2d0d971551db4c050c3f99a2f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual const <a class="el" href="namespaceirr.html#a9395eaea339bcb546b319e9c96bf7410">c8</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#a1e692e1f746ee69815bf25981ee0facf">getCreateableGUIElementTypeName</a> (<a class="el" href="namespaceirr_1_1gui.html#ae4d66df0ecf4117cdbcf9f22404bd254">EGUI_ELEMENT_TYPE</a> type) const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">returns type name of a createable GUI element  <a href="#a1e692e1f746ee69815bf25981ee0facf"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual const <a class="el" href="namespaceirr.html#a9395eaea339bcb546b319e9c96bf7410">c8</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#aa8007c17ea40b74666c1d04c9d4de85f">getCreateableGUIElementTypeName</a> (<a class="el" href="namespaceirr.html#ac66849b7a6ed16e30ebede579f9b47c6">s32</a> idx) const =0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get type name of a createable GUI element type by index.  <a href="#aa8007c17ea40b74666c1d04c9d4de85f"></a><br/></td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<p>Interface making it possible to dynamically create GUI elements. </p>
<p>To be able to add custom elements to Irrlicht and to make it possible for the scene manager to save and load them, simply implement this interface and register it in your gui environment via <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_environment.html#a653ac2cc8640899c23f4d55d9a5f0fdd" title="Adds an element factory to the gui environment.">IGUIEnvironment::registerGUIElementFactory</a>. Note: When implementing your own element factory, don't call <a class="el" href="classirr_1_1_i_reference_counted.html#a2b7a035532e5f409ca9482dab79185f4" title="Grabs the object. Increments the reference counter by one.">IGUIEnvironment::grab()</a> to increase the reference counter of the environment. This is not necessary because the it will <a class="el" href="classirr_1_1_i_reference_counted.html#a2b7a035532e5f409ca9482dab79185f4" title="Grabs the object. Increments the reference counter by one.">grab()</a> the factory anyway, and otherwise cyclic references will be created. </p>

<p>Definition at line <a class="el" href="_i_g_u_i_element_factory_8h_source.html#l00026">26</a> of file <a class="el" href="_i_g_u_i_element_factory_8h_source.html">IGUIElementFactory.h</a>.</p>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="aec55be9ef891ba1b19c5d9c5a85130a4"></a><!-- doxytag: member="irr::gui::IGUIElementFactory::addGUIElement" ref="aec55be9ef891ba1b19c5d9c5a85130a4" args="(const c8 *typeName, IGUIElement *parent=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a>* irr::gui::IGUIElementFactory::addGUIElement </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="namespaceirr.html#a9395eaea339bcb546b319e9c96bf7410">c8</a> *&nbsp;</td>
          <td class="paramname"> <em>typeName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a> *&nbsp;</td>
          <td class="paramname"> <em>parent</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>adds a GUI element to the GUI Environment based on its type name </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>typeName,:</em>&nbsp;</td><td>Type name of the element to add. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>parent,:</em>&nbsp;</td><td>Parent scene node of the new element, can be null to add it to the root. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>Pointer to the new element or null if not successful. </dd></dl>

</div>
</div>
<a class="anchor" id="aaaa0dda5493286ff745310b441347019"></a><!-- doxytag: member="irr::gui::IGUIElementFactory::addGUIElement" ref="aaaa0dda5493286ff745310b441347019" args="(EGUI_ELEMENT_TYPE type, IGUIElement *parent=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a>* irr::gui::IGUIElementFactory::addGUIElement </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceirr_1_1gui.html#ae4d66df0ecf4117cdbcf9f22404bd254">EGUI_ELEMENT_TYPE</a>&nbsp;</td>
          <td class="paramname"> <em>type</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element.html">IGUIElement</a> *&nbsp;</td>
          <td class="paramname"> <em>parent</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>adds an element to the gui environment based on its type id </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>type,:</em>&nbsp;</td><td>Type of the element to add. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>parent,:</em>&nbsp;</td><td>Parent scene node of the new element, can be null to add to the root. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>Pointer to the new element or null if not successful. </dd></dl>

</div>
</div>
<a class="anchor" id="aae56378de5264978e70d11a36fff02e9"></a><!-- doxytag: member="irr::gui::IGUIElementFactory::getCreatableGUIElementTypeCount" ref="aae56378de5264978e70d11a36fff02e9" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="namespaceirr.html#ac66849b7a6ed16e30ebede579f9b47c6">s32</a> irr::gui::IGUIElementFactory::getCreatableGUIElementTypeCount </td>
          <td>(</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get amount of GUI element types this factory is able to create. </p>

</div>
</div>
<a class="anchor" id="a9318ddb2d0d971551db4c050c3f99a2f"></a><!-- doxytag: member="irr::gui::IGUIElementFactory::getCreateableGUIElementType" ref="a9318ddb2d0d971551db4c050c3f99a2f" args="(s32 idx) const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="namespaceirr_1_1gui.html#ae4d66df0ecf4117cdbcf9f22404bd254">EGUI_ELEMENT_TYPE</a> irr::gui::IGUIElementFactory::getCreateableGUIElementType </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#ac66849b7a6ed16e30ebede579f9b47c6">s32</a>&nbsp;</td>
          <td class="paramname"> <em>idx</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get type of a createable element type. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>idx,:</em>&nbsp;</td><td>Index of the element type in this factory. Must be a value between 0 and <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#aae56378de5264978e70d11a36fff02e9" title="Get amount of GUI element types this factory is able to create.">getCreatableGUIElementTypeCount()</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a1e692e1f746ee69815bf25981ee0facf"></a><!-- doxytag: member="irr::gui::IGUIElementFactory::getCreateableGUIElementTypeName" ref="a1e692e1f746ee69815bf25981ee0facf" args="(EGUI_ELEMENT_TYPE type) const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const <a class="el" href="namespaceirr.html#a9395eaea339bcb546b319e9c96bf7410">c8</a>* irr::gui::IGUIElementFactory::getCreateableGUIElementTypeName </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceirr_1_1gui.html#ae4d66df0ecf4117cdbcf9f22404bd254">EGUI_ELEMENT_TYPE</a>&nbsp;</td>
          <td class="paramname"> <em>type</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>returns type name of a createable GUI element </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>type,:</em>&nbsp;</td><td>Type of GUI element. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>Name of the type if this factory can create the type, otherwise 0. </dd></dl>

</div>
</div>
<a class="anchor" id="aa8007c17ea40b74666c1d04c9d4de85f"></a><!-- doxytag: member="irr::gui::IGUIElementFactory::getCreateableGUIElementTypeName" ref="aa8007c17ea40b74666c1d04c9d4de85f" args="(s32 idx) const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const <a class="el" href="namespaceirr.html#a9395eaea339bcb546b319e9c96bf7410">c8</a>* irr::gui::IGUIElementFactory::getCreateableGUIElementTypeName </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#ac66849b7a6ed16e30ebede579f9b47c6">s32</a>&nbsp;</td>
          <td class="paramname"> <em>idx</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get type name of a createable GUI element type by index. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>idx,:</em>&nbsp;</td><td>Index of the type in this factory. Must be a value between 0 and <a class="el" href="classirr_1_1gui_1_1_i_g_u_i_element_factory.html#aae56378de5264978e70d11a36fff02e9" title="Get amount of GUI element types this factory is able to create.">getCreatableGUIElementTypeCount()</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_i_g_u_i_element_factory_8h_source.html">IGUIElementFactory.h</a></li>
</ul>
</div>
<hr size="1">
<address style="align: right;">
<small> </small>
</address>
<table width="100%" border="0" cellspacing="0" cellpadding="2">
  <tr> 
    <td width="0"> <div align="left"><small><a href="http://irrlicht.sourceforge.net" target="_blank"><img src="irrlicht.png" alt="The Irrlicht Engine" align="middle" border=0 width=88 height=31></a></small></div></td>
    <td> <div align="left"><small><em><font size="2">The <a href="http://irrlicht.sourceforge.net" target="_blank">Irrlicht 
        Engine</a> Documentation &copy; 2003-2010 by Nikolaus Gebhardt. Generated 
        on Sun Oct 24 12:42:04 2010 by <a href="http://www.doxygen.org" target="_blank">Doxygen</a> 
        (1.6.2)</font></em></small></div></td>
  </tr>
</table>
<address style="align: right;">
</address>
</body>
</html>