<?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[SetWindowRgn; Abgerundetes Rechteck]]></title><description><![CDATA[<pre><code class="language-cpp">GetWindowRect(hwnd, &amp;window);
two = CreateRoundRectRgn(window.left, window.top, window.right, window.bottom, 100, 100);
SetWindowRgn(hwnd, two, TRUE);
</code></pre>
<p>So, oder so ähnlich kommt bei mir ein Kreis heraus..</p>
<p>Nur ich hätte gerne ein abgerundetes Rechteck..<br />
Hat dafür jemand einen Code dafür :/?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/191126/setwindowrgn-abgerundetes-rechteck</link><generator>RSS for Node</generator><lastBuildDate>Sat, 18 Apr 2026 15:15:15 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/191126.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 30 Aug 2007 13:36:42 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to SetWindowRgn; Abgerundetes Rechteck on Thu, 30 Aug 2007 13:36:42 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">GetWindowRect(hwnd, &amp;window);
two = CreateRoundRectRgn(window.left, window.top, window.right, window.bottom, 100, 100);
SetWindowRgn(hwnd, two, TRUE);
</code></pre>
<p>So, oder so ähnlich kommt bei mir ein Kreis heraus..</p>
<p>Nur ich hätte gerne ein abgerundetes Rechteck..<br />
Hat dafür jemand einen Code dafür :/?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1355366</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1355366</guid><dc:creator><![CDATA[rectt]]></dc:creator><pubDate>Thu, 30 Aug 2007 13:36:42 GMT</pubDate></item><item><title><![CDATA[Reply to SetWindowRgn; Abgerundetes Rechteck on Thu, 30 Aug 2007 17:25:59 GMT]]></title><description><![CDATA[<p>Die letzten beiden Parameter bestimmen, wie stark die Ecken abgerundet werden sollen. Verwende mal kleinere Werte wie 10, 10 <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /> .</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1355540</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1355540</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Thu, 30 Aug 2007 17:25:59 GMT</pubDate></item><item><title><![CDATA[Reply to SetWindowRgn; Abgerundetes Rechteck on Thu, 30 Aug 2007 17:42:31 GMT]]></title><description><![CDATA[<p>Es kann auch sein, dass die Werte von window.left, window.top falsch sind, da die Region relativ zur linken oberen Ecke des Fensters berechnet wird ( nicht des Clientbereichs ).</p>
<p>Folgender Code funktioniert bei mir:</p>
<pre><code class="language-cpp">RECT rcWindow;
GetWindowRect( hWnd, &amp;rcWindow );
OffsetRect( &amp;rcWindow, -rcWindow.left, -rcWindow.top );
HRGN rgnRound = CreateRoundRectRgn( rcWindow.left, rcWindow.top, rcWindow.right, rcWindow.bottom, 40, 40 );
SetWindowRgn( hWnd, rgnRound, TRUE );
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1355555</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1355555</guid><dc:creator><![CDATA[tvdog]]></dc:creator><pubDate>Thu, 30 Aug 2007 17:42:31 GMT</pubDate></item><item><title><![CDATA[Reply to SetWindowRgn; Abgerundetes Rechteck on Thu, 30 Aug 2007 17:49:57 GMT]]></title><description><![CDATA[<p>Ohh..<br />
Danke euch beiden,<br />
ähm, muss der letzte Parameter eigentlich TRUE oder FALSE sein?..</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1355565</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1355565</guid><dc:creator><![CDATA[rectt]]></dc:creator><pubDate>Thu, 30 Aug 2007 17:49:57 GMT</pubDate></item><item><title><![CDATA[Reply to SetWindowRgn; Abgerundetes Rechteck on Thu, 30 Aug 2007 17:54:03 GMT]]></title><description><![CDATA[<p>Schau doch einfach in die MSDN, Itachi.</p>
<p>bRedraw<br />
[in] Specifies whether the system redraws the window after setting the window region. If bRedraw is TRUE, the system does so; otherwise, it does not.</p>
<p>Typically, you set bRedraw to TRUE if the window is visible.</p>
<p>--------------------------<br />
tenchou ‾ω‾</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1355568</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1355568</guid><dc:creator><![CDATA[tenchou]]></dc:creator><pubDate>Thu, 30 Aug 2007 17:54:03 GMT</pubDate></item><item><title><![CDATA[Reply to SetWindowRgn; Abgerundetes Rechteck on Thu, 15 May 2008 07:01:00 GMT]]></title><description><![CDATA[<p>Was komisch ist:<br />
bei mir wird der Border ungleichmäßig &quot;abgerundet&quot;;</p>
<pre><code class="language-cpp">b_Transp = CreateWindow( &quot;BUTTON&quot;, &quot;&quot;, WS_OVERLAPPED | WS_CHILD| WS_VISIBLE | WS_DLGFRAME, 10, 10, 330, 60, myWnd, (HMENU)b_m_Transp, ((LPCREATESTRUCT)lParam)-&gt;hInstance, NULL );
			if( b_Transp )
			{
				GetWindowRect( b_Transp, &amp;rgnWnd );
				OffsetRect( &amp;rgnWnd, -rgnWnd.left, -rgnWnd.top ); 
				if( NULL != (myRgn = CreateRoundRectRgn( rgnWnd.left, rgnWnd.top, rgnWnd.right, rgnWnd.bottom, 20, 20 ) ) )
					SetWindowRgn( b_Transp, myRgn, TRUE );
				else
					printf( &quot;%d\n&quot;, GetLastError() );

			}
</code></pre>
<p>Ausserdem wird nur der Border ausgeblendet, das Fenster nicht, dachte so könnte ich das auch Ausblenden, ist aber nicht weiter schlimm...</p>
<p>Hat jemand ne erklärung für dieses Problemchen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1509332</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1509332</guid><dc:creator><![CDATA[lippoliv]]></dc:creator><pubDate>Thu, 15 May 2008 07:01:00 GMT</pubDate></item></channel></rss>