<?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[Buttons in Farbe]]></title><description><![CDATA[<p>Jaja ich weiß, wurde alles schon mal durchgekaut in irgendeiner art und weise.<br />
Aber in der Suche hier hab ich nichts passendes zum Thema gefunden.</p>
<p>Ich will Buttons und Checkboxen (in Buttonform) in Farbe, also z.B.RGB(255,0,0) haben. Ich hab auch schon den Dialog und Textfelder etc farbig hinbekommen. Nur bei den Buttons haperts. Gehen die überhaupt Farbig, oder muss ich das nen Bitmap drüberlegen...</p>
<pre><code class="language-cpp">HBRUSH CMAX6958BnodecodeDlg::OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor)
{
	HBRUSH hbr = CDialog::OnCtlColor(pDC, pWnd, nCtlColor);

	HBRUSH hBGBrush = CreateSolidBrush(RGB(255, 0, 0));

	if(pWnd-&gt;GetDlgCtrlID() == IDC_DISPLAY1)
	{
		pDC-&gt;SetBkColor(RGB(0,255,0));
	}

	return hbr;
//	return hBGBrush;
}
</code></pre>
<p>Das ist das, was ich so hab. &quot;IDC_DISPLAY1&quot; ist eine Checkbox, allerdings in &quot;ankreuzform&quot; und da gehts, aber halt wenn das als button ist net.<br />
Kann mir da einer helfen?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/164970/buttons-in-farbe</link><generator>RSS for Node</generator><lastBuildDate>Fri, 31 Jul 2026 00:52:08 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/164970.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 14 Nov 2006 11:03:17 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Buttons in Farbe on Tue, 14 Nov 2006 11:03:17 GMT]]></title><description><![CDATA[<p>Jaja ich weiß, wurde alles schon mal durchgekaut in irgendeiner art und weise.<br />
Aber in der Suche hier hab ich nichts passendes zum Thema gefunden.</p>
<p>Ich will Buttons und Checkboxen (in Buttonform) in Farbe, also z.B.RGB(255,0,0) haben. Ich hab auch schon den Dialog und Textfelder etc farbig hinbekommen. Nur bei den Buttons haperts. Gehen die überhaupt Farbig, oder muss ich das nen Bitmap drüberlegen...</p>
<pre><code class="language-cpp">HBRUSH CMAX6958BnodecodeDlg::OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor)
{
	HBRUSH hbr = CDialog::OnCtlColor(pDC, pWnd, nCtlColor);

	HBRUSH hBGBrush = CreateSolidBrush(RGB(255, 0, 0));

	if(pWnd-&gt;GetDlgCtrlID() == IDC_DISPLAY1)
	{
		pDC-&gt;SetBkColor(RGB(0,255,0));
	}

	return hbr;
//	return hBGBrush;
}
</code></pre>
<p>Das ist das, was ich so hab. &quot;IDC_DISPLAY1&quot; ist eine Checkbox, allerdings in &quot;ankreuzform&quot; und da gehts, aber halt wenn das als button ist net.<br />
Kann mir da einer helfen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1174359</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1174359</guid><dc:creator><![CDATA[Uruk-h4j]]></dc:creator><pubDate>Tue, 14 Nov 2006 11:03:17 GMT</pubDate></item></channel></rss>