⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wg__editbox_8h-source.html

📁 一个小巧的嵌入式图形系统wGUI, 可以用VC编译
💻 HTML
字号:
<!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>wg_editbox.h Source File</title><link href="doxygen.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.2.18 --><center><a class="qindex" href="index.html">Main Page</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="classes.html">Alphabetical List</a> &nbsp; <a class="qindex" href="annotated.html">Data Structures</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="functions.html">Data Fields</a> &nbsp; </center><hr><h1>wg_editbox.h</h1><div class="fragment"><pre>00001 <span class="comment">// wg_editbox.h</span>00002 <span class="comment">//</span>00003 <span class="comment">// CEditBox interface</span>00004 <span class="comment">//</span>00005 <span class="comment">//</span>00006 <span class="comment">// Copyright (c) 2002 Rob Wiskow</span>00007 <span class="comment">// rob-dev@boxedchaos.com</span>00008 <span class="comment">//</span>00009 <span class="comment">// This library is free software; you can redistribute it and/or</span>00010 <span class="comment">// modify it under the terms of the GNU Lesser General Public</span>00011 <span class="comment">// License as published by the Free Software Foundation; either</span>00012 <span class="comment">// version 2.1 of the License, or (at your option) any later version.</span>00013 <span class="comment">//</span>00014 <span class="comment">// This library is distributed in the hope that it will be useful,</span>00015 <span class="comment">// but WITHOUT ANY WARRANTY; without even the implied warranty of</span>00016 <span class="comment">// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</span>00017 <span class="comment">// Lesser General Public License for more details.</span>00018 <span class="comment">//</span>00019 <span class="comment">// You should have received a copy of the GNU Lesser General Public</span>00020 <span class="comment">// License along with this library; if not, write to the Free Software</span>00021 <span class="comment">// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA</span>00022 <span class="comment">//</span>00023 00024 00025 <span class="preprocessor">#ifndef _WG_EDITBOX_H_</span>00026 <span class="preprocessor"></span><span class="preprocessor">#define _WG_EDITBOX_H_</span>00027 <span class="preprocessor"></span>00028 <span class="preprocessor">#include "wg_window.h"</span>00029 <span class="preprocessor">#include "wg_painter.h"</span>00030 <span class="preprocessor">#include "wg_renderedstring.h"</span>00031 <span class="preprocessor">#include "wg_resources.h"</span>00032 <span class="preprocessor">#include &lt;memory&gt;</span>00033 00034 00035 <span class="keyword">namespace </span>wGui00036 {00037 00039 00041 <a name="l00042"></a><a class="code" href="classwGui_1_1CEditBox.html">00042</a> <span class="keyword">class </span><a class="code" href="classwGui_1_1CEditBox.html">CEditBox</a> : <span class="keyword">public</span> <a class="code" href="classwGui_1_1CWindow.html">CWindow</a>00043 {00044 <span class="keyword">public</span>:00050      <a class="code" href="classwGui_1_1CEditBox.html#a0">CEditBox</a>(<span class="keyword">const</span> <a class="code" href="classwGui_1_1CRect.html">CRect</a>&amp; WindowRect, <a class="code" href="classwGui_1_1CWindow.html">CWindow</a>* pParent, <a class="code" href="classwGui_1_1CFontEngine.html">CFontEngine</a>* pFontEngine = 0);00051 <a name="l00053"></a><a class="code" href="classwGui_1_1CEditBox.html#a1">00053</a>      <span class="keyword">virtual</span> <a class="code" href="classwGui_1_1CEditBox.html#a1">~CEditBox</a>(<span class="keywordtype">void</span>) { }00054 <a name="l00057"></a><a class="code" href="classwGui_1_1CEditBox.html#a2">00057</a>      <span class="keywordtype">void</span> <a class="code" href="classwGui_1_1CEditBox.html#a2">SetUsePasswordMask</a>(<span class="keywordtype">bool</span> bUseMask) { <a class="code" href="classwGui_1_1CEditBox.html#n9">m_bUseMask</a> = bUseMask; }00058 <a name="l00060"></a><a class="code" href="classwGui_1_1CEditBox.html#a3">00060</a>      <span class="keywordtype">bool</span> <a class="code" href="classwGui_1_1CEditBox.html#a3">UsingPasswordMask</a>(<span class="keywordtype">void</span>) { <span class="keywordflow">return</span> <a class="code" href="classwGui_1_1CEditBox.html#n9">m_bUseMask</a>; }00061 00064      <span class="keywordtype">void</span> <a class="code" href="classwGui_1_1CEditBox.html#a4">SetReadOnly</a>(<span class="keywordtype">bool</span> bReadOnly);00065 <a name="l00067"></a><a class="code" href="classwGui_1_1CEditBox.html#a5">00067</a>      <span class="keywordtype">bool</span> <a class="code" href="classwGui_1_1CEditBox.html#a5">IsReadOnly</a>(<span class="keywordtype">void</span>) { <span class="keywordflow">return</span> <a class="code" href="classwGui_1_1CEditBox.html#n7">m_bReadOnly</a>; }00068 00070      std::string <a class="code" href="classwGui_1_1CEditBox.html#a6">GetSelText</a>(<span class="keywordtype">void</span>) <span class="keyword">const</span>;00071 00072 00073      <span class="comment">// CWindow overrides</span>00075 <span class="comment">     virtual void Draw(void) const;</span>00076 00079      <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classwGui_1_1CEditBox.html#a8">SetWindowText</a>(<span class="keyword">const</span> std::string&amp; sText);00080 00086      <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="classwGui_1_1CEditBox.html#a9">OnMouseButtonDown</a>(CPoint Point, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> Button);00087 00088 00089      <span class="comment">// CMessageClient overrides</span>00092 <span class="comment">     virtual bool HandleMessage(CMessage* pMessage);</span>00093 00094 <span class="keyword">protected</span>:00095 00099      <span class="keywordtype">void</span> <a class="code" href="classwGui_1_1CEditBox.html#b0">SelDelete</a>(std::string* psString);00100 <a name="l00101"></a><a class="code" href="classwGui_1_1CEditBox.html#n0">00101</a>      <a class="code" href="classwGui_1_1CFontEngine.html">CFontEngine</a>* <a class="code" href="classwGui_1_1CEditBox.html#n0">m_pFontEngine</a>; <a name="l00102"></a><a class="code" href="classwGui_1_1CEditBox.html#n1">00102</a>      std::auto_ptr&lt;CRenderedString&gt; <a class="code" href="classwGui_1_1CEditBox.html#n1">m_pRenderedString</a>; <a name="l00103"></a><a class="code" href="classwGui_1_1CEditBox.html#n2">00103</a>      <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> <a class="code" href="classwGui_1_1CEditBox.html#n2">m_FontSize</a>;  <a name="l00104"></a><a class="code" href="classwGui_1_1CEditBox.html#n3">00104</a>      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="classwGui_1_1CEditBox.html#n3">m_SelStart</a>;  <a name="l00105"></a><a class="code" href="classwGui_1_1CEditBox.html#n4">00105</a>      <span class="keywordtype">int</span> <a class="code" href="classwGui_1_1CEditBox.html#n4">m_SelLength</a>;  <a name="l00106"></a><a class="code" href="classwGui_1_1CEditBox.html#n5">00106</a>      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="classwGui_1_1CEditBox.html#n5">m_DragStart</a>;  <a name="l00107"></a><a class="code" href="classwGui_1_1CEditBox.html#n6">00107</a>      <span class="keyword">mutable</span> <span class="keywordtype">int</span> <a class="code" href="classwGui_1_1CEditBox.html#n6">m_ScrollOffset</a>;  <a name="l00108"></a><a class="code" href="classwGui_1_1CEditBox.html#n7">00108</a>      <span class="keywordtype">bool</span> <a class="code" href="classwGui_1_1CEditBox.html#n7">m_bReadOnly</a>;  <a name="l00109"></a><a class="code" href="classwGui_1_1CEditBox.html#n8">00109</a>      <span class="keywordtype">bool</span> <a class="code" href="classwGui_1_1CEditBox.html#n8">m_bMouseDown</a>; <a name="l00110"></a><a class="code" href="classwGui_1_1CEditBox.html#n9">00110</a>      <span class="keywordtype">bool</span> <a class="code" href="classwGui_1_1CEditBox.html#n9">m_bUseMask</a>; <a name="l00111"></a><a class="code" href="classwGui_1_1CEditBox.html#n10">00111</a>      <span class="keywordtype">bool</span> <a class="code" href="classwGui_1_1CEditBox.html#n10">m_bLastMouseMoveInside</a>;  00112 00113 00114 <span class="keyword">private</span>:00115      <span class="keywordtype">void</span> operator=(<a class="code" href="classwGui_1_1CEditBox.html">CEditBox</a>) { }  00116 };00117 00118 }00119 00120 <span class="preprocessor">#endif // _WG_EDITBOX_H_</span></pre></div><hr><address style="align: right;"><small>Generated on Sat Oct 25 12:43:22 2003 for wGui by<a href="http://www.doxygen.org/index.html"><img src="doxygen.png" alt="doxygen" align="middle" border=0 width=110 height=53></a>1.2.18 </small></address></body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -