<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Techy Things &#187; win32</title>
	<atom:link href="https://tech.yipp.ca/category/win32/feed/" rel="self" type="application/rss+xml" />
	<link>https://tech.yipp.ca</link>
	<description>Just another Yipp.ca Blogs site</description>
	<lastBuildDate>Thu, 01 May 2025 18:06:28 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=4.2.38</generator>
	<item>
		<title>GDI USAGE ERROR: DC 0x2d0110d1 that contains selected object being deleted</title>
		<link>https://tech.yipp.ca/win32/gdi-usage-error-dc-0x2d0110d1-contains-selected-object-deleted/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=gdi-usage-error-dc-0x2d0110d1-contains-selected-object-deleted</link>
		<comments>https://tech.yipp.ca/win32/gdi-usage-error-dc-0x2d0110d1-contains-selected-object-deleted/#comments</comments>
		<pubDate>Mon, 09 Jan 2017 18:25:10 +0000</pubDate>
		<dc:creator><![CDATA[frank]]></dc:creator>
				<category><![CDATA[win32]]></category>

		<guid isPermaLink="false">http://tech.yipp.ca/?p=2714</guid>
		<description><![CDATA[<p>uint32_t WIN_FONT::GetTextWidth(const char* theText, uint32_t theLength) // Return the number of pixels width the text is base on the font info. { uint32_t width = 0; wchar_t* wcString = NULL; int32_t wcLength = CreateWideString(theText,&#46;&#46;&#46;</p>
<p>The post <a rel="nofollow" href="https://tech.yipp.ca/win32/gdi-usage-error-dc-0x2d0110d1-contains-selected-object-deleted/">GDI USAGE ERROR: DC 0x2d0110d1 that contains selected object being deleted</a> appeared first on <a rel="nofollow" href="https://tech.yipp.ca">Techy Things</a>.</p>
]]></description>
				<content:encoded><![CDATA[<pre>
uint32_t WIN_FONT::GetTextWidth(const char* theText, uint32_t theLength)
// Return the number of pixels width the text is base on the font info.
{
 uint32_t width = 0;

 wchar_t* wcString = NULL;
 int32_t wcLength = CreateWideString(theText, theLength, &amp;wcString);
 if (wcLength &gt; 0)
 {
  HDC hdc = GetDC(NULL);
  (HFONT)SelectObject(hdc, (HGDIOBJ)winFont);

  SIZE size;
  if(GetTextExtentPoint32W(hdc, wcString, wcLength, &amp;size))
  {
   width = size.cx;
  }
<strong><span style="color: #ff0000;">  ReleaseDC(NULL, hdc); // &lt;= Error detected here</span></strong>
  delete[] wcString;
 }

 return width;
}</pre>
<p>The post <a rel="nofollow" href="https://tech.yipp.ca/win32/gdi-usage-error-dc-0x2d0110d1-contains-selected-object-deleted/">GDI USAGE ERROR: DC 0x2d0110d1 that contains selected object being deleted</a> appeared first on <a rel="nofollow" href="https://tech.yipp.ca">Techy Things</a>.</p>
]]></content:encoded>
			<wfw:commentRss>https://tech.yipp.ca/win32/gdi-usage-error-dc-0x2d0110d1-contains-selected-object-deleted/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Convert clipping area to win32 rect</title>
		<link>https://tech.yipp.ca/win32/convert-clipping-area-win32-rect/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=convert-clipping-area-win32-rect</link>
		<comments>https://tech.yipp.ca/win32/convert-clipping-area-win32-rect/#comments</comments>
		<pubDate>Wed, 08 Oct 2014 20:53:33 +0000</pubDate>
		<dc:creator><![CDATA[frank]]></dc:creator>
				<category><![CDATA[win32]]></category>

		<guid isPermaLink="false">http://tech.yipp.ca/?p=1088</guid>
		<description><![CDATA[<p>RECT rect; rect.left = tmp.X; rect.right = tmp.X + tmp.W; rect.bottom = tmp.Y; rect.top = tmp.Y + tmp.H; ExtTextOutW(bitmapHDC, x, y, ETO_CLIPPED, &#38;rect, wcString, wcLength, NULL); &#160;</p>
<p>The post <a rel="nofollow" href="https://tech.yipp.ca/win32/convert-clipping-area-win32-rect/">Convert clipping area to win32 rect</a> appeared first on <a rel="nofollow" href="https://tech.yipp.ca">Techy Things</a>.</p>
]]></description>
				<content:encoded><![CDATA[<p>RECT rect;<br />
rect.left = tmp.X;<br />
rect.right = tmp.X + tmp.W;<br />
rect.bottom = tmp.Y;<br />
rect.top = tmp.Y + tmp.H;<br />
ExtTextOutW(bitmapHDC, x, y, ETO_CLIPPED, &amp;rect, wcString, wcLength, NULL);</p>
<p>&nbsp;</p>
<p>The post <a rel="nofollow" href="https://tech.yipp.ca/win32/convert-clipping-area-win32-rect/">Convert clipping area to win32 rect</a> appeared first on <a rel="nofollow" href="https://tech.yipp.ca">Techy Things</a>.</p>
]]></content:encoded>
			<wfw:commentRss>https://tech.yipp.ca/win32/convert-clipping-area-win32-rect/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
