<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[RichEdit ohne MFC]]></title><description><![CDATA[<p>Hallo,</p>
<p>kann mir jemand ein paar gute Tutorials oder Code Beispiele geben, wie ich<br />
in eine RichEditBox</p>
<p>1. Text einfärben kann (z.b. erstes Wort pro Zeile rot)<br />
2. Wie ich ein Icon aus einer Ressource Datei in der RichEditBox anzeigen kann<br />
(z.B. bei Chat anwendungen die Smilies in dem ChatFenster)</p>
<p>Ich wäre euch sehr dankbahr, wenn ihr mir helfen könntet,<br />
da ich schon ca 1 Woche nach solchen einträgen suche !</p>
<p>Leider hab ich das jeweils nur für MFC gefunden aber da ich ohne<br />
arbeite kann ich damit nichts anfangen...</p>
<p>Ich erstelle meine RichEditBox folgender massen:</p>
<pre><code class="language-cpp">RichEditLib = LoadLibrary(&quot;riched32.dll&quot;); 

if( RichEditLib == NULL ) 
{ 
    MessageBox(NULL,&quot;Fehler beim laden von: riched32.dll!&quot;,&quot;Error&quot;,MB_ICONEXCLAMATION); 
    PostQuitMessage(0); 
} 

Edit_ChatText = CreateWindowEx(WS_EX_CLIENTEDGE,RICHEDIT_CLASS,&quot;&quot;, WS_CHILD | WS_VISIBLE | ES_MULTILINE | ES_AUTOVSCROLL | WS_VSCROLL, 0, 0, 645, 529, hWnd, (HMENU)Edit_ChatTextID, hInst, NULL); 
SendMessage(Edit_ChatText, WM_SETFONT, (WPARAM)GetStockObject(DEFAULT_GUI_FONT), 0);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/topic/77025/richedit-ohne-mfc</link><generator>RSS for Node</generator><lastBuildDate>Sat, 11 Apr 2026 17:38:25 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/77025.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 16 Jun 2004 21:15:54 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to RichEdit ohne MFC on Wed, 16 Jun 2004 21:15:54 GMT]]></title><description><![CDATA[<p>Hallo,</p>
<p>kann mir jemand ein paar gute Tutorials oder Code Beispiele geben, wie ich<br />
in eine RichEditBox</p>
<p>1. Text einfärben kann (z.b. erstes Wort pro Zeile rot)<br />
2. Wie ich ein Icon aus einer Ressource Datei in der RichEditBox anzeigen kann<br />
(z.B. bei Chat anwendungen die Smilies in dem ChatFenster)</p>
<p>Ich wäre euch sehr dankbahr, wenn ihr mir helfen könntet,<br />
da ich schon ca 1 Woche nach solchen einträgen suche !</p>
<p>Leider hab ich das jeweils nur für MFC gefunden aber da ich ohne<br />
arbeite kann ich damit nichts anfangen...</p>
<p>Ich erstelle meine RichEditBox folgender massen:</p>
<pre><code class="language-cpp">RichEditLib = LoadLibrary(&quot;riched32.dll&quot;); 

if( RichEditLib == NULL ) 
{ 
    MessageBox(NULL,&quot;Fehler beim laden von: riched32.dll!&quot;,&quot;Error&quot;,MB_ICONEXCLAMATION); 
    PostQuitMessage(0); 
} 

Edit_ChatText = CreateWindowEx(WS_EX_CLIENTEDGE,RICHEDIT_CLASS,&quot;&quot;, WS_CHILD | WS_VISIBLE | ES_MULTILINE | ES_AUTOVSCROLL | WS_VSCROLL, 0, 0, 645, 529, hWnd, (HMENU)Edit_ChatTextID, hInst, NULL); 
SendMessage(Edit_ChatText, WM_SETFONT, (WPARAM)GetStockObject(DEFAULT_GUI_FONT), 0);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/541979</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/541979</guid><dc:creator><![CDATA[Karigos]]></dc:creator><pubDate>Wed, 16 Jun 2004 21:15:54 GMT</pubDate></item><item><title><![CDATA[Reply to RichEdit ohne MFC on Wed, 16 Jun 2004 21:42:25 GMT]]></title><description><![CDATA[<p>Schau dich mal <a href="http://msdn.microsoft.com/library/en-us/shellcc/platform/commctls/richedit/richeditcontrols/aboutricheditcontrols.asp" rel="nofollow">hier</a> um...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/541990</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/541990</guid><dc:creator><![CDATA[flenders]]></dc:creator><pubDate>Wed, 16 Jun 2004 21:42:25 GMT</pubDate></item><item><title><![CDATA[Reply to RichEdit ohne MFC on Thu, 17 Jun 2004 10:14:33 GMT]]></title><description><![CDATA[<p>Hi !</p>
<p>Das ist schon gut !</p>
<p>Nur leider kann ich damit nicht wirklich sehr viel anfangen, weil ich<br />
nicht alles dort genau verstehe...</p>
<p>Kanst du mir evtl nen kleines Beispiel machen ?</p>
<p>Wäre supper !</p>
<p>Danke!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/542190</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/542190</guid><dc:creator><![CDATA[Karigos]]></dc:creator><pubDate>Thu, 17 Jun 2004 10:14:33 GMT</pubDate></item><item><title><![CDATA[Reply to RichEdit ohne MFC on Thu, 17 Jun 2004 10:44:08 GMT]]></title><description><![CDATA[<p>Ich hab noch nie was damit gemacht - da müssen andere her oder du suchst nach Tutorials <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f642.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--slightly_smiling_face"
      title=":)"
      alt="🙂"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/542206</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/542206</guid><dc:creator><![CDATA[flenders]]></dc:creator><pubDate>Thu, 17 Jun 2004 10:44:08 GMT</pubDate></item><item><title><![CDATA[Reply to RichEdit ohne MFC on Thu, 17 Jun 2004 10:51:21 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">// Text an die Editbox anhängen:
		CHARFORMAT CharFormat;
		CharFormat.cbSize = sizeof (CHARFORMAT);
		SendMessage (edbx, EM_GETCHARFORMAT, SCF_SELECTION, (LPARAM)&amp;CharFormat);

		CharFormat.dwMask      = CFM_COLOR | CFM_SIZE | CFM_FACE; // | CFM_BOLD;
		CharFormat.crTextColor = RGB (bColRed, bColGreen, bColBlue);
		CharFormat.dwEffects   = CFE_BOLD;
		CharFormat.yHeight	   = CharFormatOld.yHeight;
		//lstrcpy (CharFormat.szFaceName, TEXT (&quot;Lucida Console&quot;));
		lstrcpy (CharFormat.szFaceName, TEXT (&quot;Arial&quot;));

		SendMessage (edbx, EM_SETCHARFORMAT, SCF_SELECTION, (LPARAM)&amp;CharFormat);
		SendMessage (edbx, EM_SETSEL, (WPARAM)-1, (LPARAM)0); 

		// an das Ende springen
		SendMessage (edbx, EM_SETSEL, (WPARAM)-2, (LPARAM)-2); 
		// Text anhängen
		SendMessage (edbx, EM_REPLACESEL, (WPARAM)0 , (int)&quot;Dein Text&quot;);
		int iLength = GetWindowTextLength (edbx);
		SendMessage (edbx, EM_SETSEL, (WPARAM)iLength, (LPARAM)-1); 

		SendMessage (edbx, EM_SETCHARFORMAT, SCF_SELECTION, (LPARAM)&amp;CharFormat);
		SendMessage (edbx, EM_SETSEL, (WPARAM)-1, (LPARAM)0);
</code></pre>
<p>Nicht gerade optimal, aber es geht <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f644.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--face_with_rolling_eyes"
      title=":rolling_eyes:"
      alt="🙄"
    /></p>
<p>Blackbird</p>
]]></description><link>https://www.c-plusplus.net/forum/post/542214</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/542214</guid><dc:creator><![CDATA[Blackbird]]></dc:creator><pubDate>Thu, 17 Jun 2004 10:51:21 GMT</pubDate></item><item><title><![CDATA[Reply to RichEdit ohne MFC on Thu, 17 Jun 2004 15:10:49 GMT]]></title><description><![CDATA[<p>Das klappt wunderbahr ! Danke sehr !</p>
<p>Jetz muss ich nur noch rausfinden, wie ich pro Satz nur z.B. die ersten 5 Zeichen einfärbe <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f642.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--slightly_smiling_face"
      title=":)"
      alt="🙂"
    /></p>
<p>Danke sehr !</p>
]]></description><link>https://www.c-plusplus.net/forum/post/542495</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/542495</guid><dc:creator><![CDATA[Karigos]]></dc:creator><pubDate>Thu, 17 Jun 2004 15:10:49 GMT</pubDate></item><item><title><![CDATA[Reply to RichEdit ohne MFC on Fri, 18 Jun 2004 06:34:53 GMT]]></title><description><![CDATA[<p>Ganz einfach:<br />
Zuerst die 5 Zeichen als erste Zeichenkette senden, dann den Rest des Satzes als 2. Zeichenkette senden. Jedesmal mit einer anderen Farbe.</p>
<p>Schreib' doch den Code-Schnipsel in eine eigene Funktion, der Du nur den String und die Farbe übergibst.</p>
<p>Blackbird</p>
]]></description><link>https://www.c-plusplus.net/forum/post/542896</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/542896</guid><dc:creator><![CDATA[Blackbird]]></dc:creator><pubDate>Fri, 18 Jun 2004 06:34:53 GMT</pubDate></item></channel></rss>