Sophie

Sophie

distrib > Mandriva > 2010.1 > x86_64 > media > contrib-release > by-pkgid > 58828b263d8f56d90ac336dea07a4586 > files > 98

irrlicht-doc-1.6.1-1mdv2010.1.x86_64.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: IGUIButton.h Source File</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.5.6 -->
<h1>IGUIButton.h</h1><a href="_i_g_u_i_button_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">// Copyright (C) 2002-2009 Nikolaus Gebhardt</span>
<a name="l00002"></a>00002 <span class="comment">// This file is part of the "Irrlicht Engine".</span>
<a name="l00003"></a>00003 <span class="comment">// For conditions of distribution and use, see copyright notice in irrlicht.h</span>
<a name="l00004"></a>00004 
<a name="l00005"></a>00005 <span class="preprocessor">#ifndef __I_GUI_BUTTON_H_INCLUDED__</span>
<a name="l00006"></a>00006 <span class="preprocessor"></span><span class="preprocessor">#define __I_GUI_BUTTON_H_INCLUDED__</span>
<a name="l00007"></a>00007 <span class="preprocessor"></span>
<a name="l00008"></a>00008 <span class="preprocessor">#include "<a class="code" href="_i_g_u_i_element_8h.html">IGUIElement.h</a>"</span>
<a name="l00009"></a>00009 
<a name="l00010"></a>00010 <span class="keyword">namespace </span>irr
<a name="l00011"></a>00011 {
<a name="l00012"></a>00012 
<a name="l00013"></a>00013 <span class="keyword">namespace </span>video
<a name="l00014"></a>00014 {
<a name="l00015"></a>00015         <span class="keyword">class </span>ITexture;
<a name="l00016"></a>00016 } <span class="comment">// end namespace video</span>
<a name="l00017"></a>00017 
<a name="l00018"></a>00018 <span class="keyword">namespace </span>gui
<a name="l00019"></a>00019 {
<a name="l00020"></a>00020         <span class="keyword">class </span>IGUIFont;
<a name="l00021"></a>00021         <span class="keyword">class </span>IGUISpriteBank;
<a name="l00022"></a>00022 
<a name="l00023"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5">00023</a>         <span class="keyword">enum</span> <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5">EGUI_BUTTON_STATE</a>
<a name="l00024"></a>00024         {
<a name="l00026"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5e47afa6c570b82732b069b73a6060579">00026</a>                 <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5e47afa6c570b82732b069b73a6060579" title="The button is not pressed.">EGBS_BUTTON_UP</a>=0,
<a name="l00028"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5297a4a82fd57a1a5f68da0292ae607ca">00028</a>                 <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5297a4a82fd57a1a5f68da0292ae607ca" title="The button is currently pressed down.">EGBS_BUTTON_DOWN</a>,
<a name="l00030"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb52c8c78780719305dad51f330c083e355">00030</a>                 <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb52c8c78780719305dad51f330c083e355" title="The mouse cursor is over the button.">EGBS_BUTTON_MOUSE_OVER</a>,
<a name="l00032"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5154e2d7435276030b565196ac467b4ab">00032</a>                 <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5154e2d7435276030b565196ac467b4ab" title="The mouse cursor is not over the button.">EGBS_BUTTON_MOUSE_OFF</a>,
<a name="l00034"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb57af5f151c0f00be71fcd230745f0f3be">00034</a>                 <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb57af5f151c0f00be71fcd230745f0f3be" title="The button has the focus.">EGBS_BUTTON_FOCUSED</a>,
<a name="l00036"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb590c8ffcae65eadd3199105bdf6608c7e">00036</a>                 <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb590c8ffcae65eadd3199105bdf6608c7e" title="The button doesn&amp;#39;t have the focus.">EGBS_BUTTON_NOT_FOCUSED</a>,
<a name="l00038"></a><a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5ed20edf8c2114c8c1edf87aca536b685">00038</a>                 <a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5ed20edf8c2114c8c1edf87aca536b685" title="not used, counts the number of enumerated items">EGBS_COUNT</a>
<a name="l00039"></a>00039         };
<a name="l00040"></a>00040 
<a name="l00042"></a><a class="code" href="namespaceirr_1_1gui.html#4c9022b413a54ce6ce5f665b252080d7">00042</a>         <span class="keyword">const</span> <a class="code" href="namespaceirr.html#9395eaea339bcb546b319e9c96bf7410" title="8 bit character variable.">c8</a>* <span class="keyword">const</span> <a class="code" href="namespaceirr_1_1gui.html#4c9022b413a54ce6ce5f665b252080d7" title="Names for gui button state icons.">GUIButtonStateNames</a>[] =
<a name="l00043"></a>00043         {
<a name="l00044"></a>00044                 <span class="stringliteral">"buttonUp"</span>,
<a name="l00045"></a>00045                 <span class="stringliteral">"buttonDown"</span>,
<a name="l00046"></a>00046                 <span class="stringliteral">"buttonMouseOver"</span>,
<a name="l00047"></a>00047                 <span class="stringliteral">"buttonMouseOff"</span>,
<a name="l00048"></a>00048                 <span class="stringliteral">"buttonFocused"</span>,
<a name="l00049"></a>00049                 <span class="stringliteral">"buttonNotFocused"</span>,
<a name="l00050"></a>00050                 0,
<a name="l00051"></a>00051                 0,
<a name="l00052"></a>00052         };
<a name="l00053"></a>00053 
<a name="l00055"></a><a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html">00055</a>         <span class="keyword">class </span><a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html" title="GUI Button interface.">IGUIButton</a> : <span class="keyword">public</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_element.html" title="Base class of all GUI elements.">IGUIElement</a>
<a name="l00056"></a>00056         {
<a name="l00057"></a>00057         <span class="keyword">public</span>:
<a name="l00058"></a>00058 
<a name="l00060"></a><a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#9ce8f3172c2c82269c2cf6a650ccaaa8">00060</a>                 <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#9ce8f3172c2c82269c2cf6a650ccaaa8" title="constructor">IGUIButton</a>(<a class="code" href="classirr_1_1gui_1_1_i_g_u_i_environment.html" title="GUI Environment. Used as factory and manager of all other GUI elements.">IGUIEnvironment</a>* environment, <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_element.html" title="Base class of all GUI elements.">IGUIElement</a>* parent, <a class="code" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6" title="32 bit signed variable.">s32</a> <span class="keywordtype">id</span>, <a class="code" href="classirr_1_1core_1_1rect.html" title="Rectangle template.">core::rect&lt;s32&gt;</a> rectangle)
<a name="l00061"></a>00061                         : <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_element.html" title="Base class of all GUI elements.">IGUIElement</a>(<a class="code" href="namespaceirr_1_1gui.html#e4d66df0ecf4117cdbcf9f22404bd2546ecc34fc83c8e550cb20d0b456a24b95" title="A button (IGUIButton).">EGUIET_BUTTON</a>, environment, parent, id, rectangle) {}
<a name="l00062"></a>00062 
<a name="l00064"></a>00064 
<a name="l00066"></a>00066                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#b63c3536bd2eb92e9ebec8ea3a381ec1" title="Sets another skin independent font.">setOverrideFont</a>(<a class="code" href="classirr_1_1gui_1_1_i_g_u_i_font.html" title="Font interface.">IGUIFont</a>* font=0) = 0;
<a name="l00067"></a>00067 
<a name="l00069"></a>00069 
<a name="l00070"></a>00070                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#f233578beb34ba115b0197731e34a3f1" title="Sets an image which should be displayed on the button when it is in normal state...">setImage</a>(<a class="code" href="classirr_1_1video_1_1_i_texture.html" title="Interface of a Video Driver dependent Texture.">video::ITexture</a>* image=0) = 0;
<a name="l00071"></a>00071 
<a name="l00073"></a>00073 
<a name="l00075"></a>00075                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#f233578beb34ba115b0197731e34a3f1" title="Sets an image which should be displayed on the button when it is in normal state...">setImage</a>(<a class="code" href="classirr_1_1video_1_1_i_texture.html" title="Interface of a Video Driver dependent Texture.">video::ITexture</a>* image, <span class="keyword">const</span> <a class="code" href="classirr_1_1core_1_1rect.html" title="Rectangle template.">core::rect&lt;s32&gt;</a>&amp; pos) = 0;
<a name="l00076"></a>00076 
<a name="l00078"></a>00078 
<a name="l00081"></a>00081                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#10389917530aa2f4a3008330c0695aad" title="Sets a background image for the button when it is in pressed state.">setPressedImage</a>(<a class="code" href="classirr_1_1video_1_1_i_texture.html" title="Interface of a Video Driver dependent Texture.">video::ITexture</a>* image=0) = 0;
<a name="l00082"></a>00082 
<a name="l00084"></a>00084 
<a name="l00086"></a>00086                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#10389917530aa2f4a3008330c0695aad" title="Sets a background image for the button when it is in pressed state.">setPressedImage</a>(<a class="code" href="classirr_1_1video_1_1_i_texture.html" title="Interface of a Video Driver dependent Texture.">video::ITexture</a>* image, <span class="keyword">const</span> <a class="code" href="classirr_1_1core_1_1rect.html" title="Rectangle template.">core::rect&lt;s32&gt;</a>&amp; pos) = 0;
<a name="l00087"></a>00087 
<a name="l00089"></a>00089                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#0570cc64a1445866a0c8123c0209c83d" title="Sets the sprite bank used by the button.">setSpriteBank</a>(<a class="code" href="classirr_1_1gui_1_1_i_g_u_i_sprite_bank.html" title="Sprite bank interface.">IGUISpriteBank</a>* bank=0) = 0;
<a name="l00090"></a>00090 
<a name="l00092"></a>00092 
<a name="l00098"></a>00098                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#26c5f05e922b0fc1b5790a001fd04b78" title="Sets the animated sprite for a specific button state.">setSprite</a>(<a class="code" href="namespaceirr_1_1gui.html#2520445dec46e00684645ef8053aebb5">EGUI_BUTTON_STATE</a> state, <a class="code" href="namespaceirr.html#c66849b7a6ed16e30ebede579f9b47c6" title="32 bit signed variable.">s32</a> index,
<a name="l00099"></a>00099                                 <a class="code" href="classirr_1_1video_1_1_s_color.html" title="Class representing a 32 bit ARGB color.">video::SColor</a> color=<a class="code" href="classirr_1_1video_1_1_s_color.html" title="Class representing a 32 bit ARGB color.">video::SColor</a>(255,255,255,255), <span class="keywordtype">bool</span> loop=<span class="keyword">false</span>) = 0;
<a name="l00100"></a>00100 
<a name="l00102"></a>00102 
<a name="l00104"></a>00104                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#992775637ba91f5267c4c04d5889fc6d" title="Sets if the button should behave like a push button.">setIsPushButton</a>(<span class="keywordtype">bool</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#bb12a92ba70d1fe738655d04ef73734f" title="Returns whether the button is a push button.">isPushButton</a>=<span class="keyword">true</span>) = 0;
<a name="l00105"></a>00105 
<a name="l00107"></a>00107                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#2508fb292fab222bcebdeae0f9874348" title="Sets the pressed state of the button if this is a pushbutton.">setPressed</a>(<span class="keywordtype">bool</span> pressed=<span class="keyword">true</span>) = 0;
<a name="l00108"></a>00108 
<a name="l00110"></a>00110                 <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#2621bd10a5eb91fa14037feb9378c252" title="Returns if the button is currently pressed.">isPressed</a>() <span class="keyword">const</span> = 0;
<a name="l00111"></a>00111 
<a name="l00113"></a>00113                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#3d7727e7807e8b71dae6f81a44737e8a" title="Sets if the alpha channel should be used for drawing background images on the button...">setUseAlphaChannel</a>(<span class="keywordtype">bool</span> useAlphaChannel=<span class="keyword">true</span>) = 0;
<a name="l00114"></a>00114 
<a name="l00116"></a>00116                 <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#f4cb47805f2a296506b8a0b4cb65fddf" title="Returns if the alpha channel should be used for drawing background images on the...">isAlphaChannelUsed</a>() <span class="keyword">const</span> = 0;
<a name="l00117"></a>00117 
<a name="l00119"></a>00119                 <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#bb12a92ba70d1fe738655d04ef73734f" title="Returns whether the button is a push button.">isPushButton</a>() <span class="keyword">const</span> = 0;
<a name="l00120"></a>00120 
<a name="l00122"></a>00122                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#a6e68e5335f67472bde80b530b6d31fd" title="Sets if the button should use the skin to draw its border and button face (default...">setDrawBorder</a>(<span class="keywordtype">bool</span> border=<span class="keyword">true</span>) = 0;
<a name="l00123"></a>00123 
<a name="l00125"></a>00125                 <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#f2e1cee431cc5f90cede3820719625f1" title="Returns if the border and button face are being drawn using the skin.">isDrawingBorder</a>() <span class="keyword">const</span> = 0;
<a name="l00126"></a>00126 
<a name="l00128"></a>00128                 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#e0767cb927c7974e19eaa3e5ca52bf1f" title="Sets if the button should scale the button images to fit.">setScaleImage</a>(<span class="keywordtype">bool</span> scaleImage=<span class="keyword">true</span>) = 0;
<a name="l00129"></a>00129 
<a name="l00131"></a>00131                 <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="classirr_1_1gui_1_1_i_g_u_i_button.html#f2660457dae6def0b34d4748e96c653a" title="Checks whether the button scales the used images.">isScalingImage</a>() <span class="keyword">const</span> = 0;
<a name="l00132"></a>00132         };
<a name="l00133"></a>00133 
<a name="l00134"></a>00134 
<a name="l00135"></a>00135 } <span class="comment">// end namespace gui</span>
<a name="l00136"></a>00136 } <span class="comment">// end namespace irr</span>
<a name="l00137"></a>00137 
<a name="l00138"></a>00138 <span class="preprocessor">#endif</span>
<a name="l00139"></a>00139 <span class="preprocessor"></span>
</pre></div></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-2009 by Nikolaus Gebhardt. Generated 
        on Sun Jan 10 09:24:03 2010 by <a href="http://www.doxygen.org" target="_blank">Doxygen</a> 
        (1.5.6)</font></em></small></div></td>
  </tr>
</table>
<address style="align: right;">
</address>
</body>
</html>