<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : CXTPButton with rounded corners</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Toolkit Pro : CXTPButton with rounded corners]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Sun, 19 Apr 2026 22:51:13 +0000</pubDate>
  <lastBuildDate>Tue, 10 Sep 2013 02:04:34 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=13705</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[CXTPButton with rounded corners :  Hello,Do you maybe have an example...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13705&amp;PID=71589&amp;title=cxtpbutton-with-rounded-corners#71589</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=8157">Jouden</a><br /><strong>Subject:</strong> 13705<br /><strong>Posted:</strong> 10 September 2013 at 2:04am<br /><br />Hello,<div>&nbsp;</div><div>Do you maybe have an example file (zip) of round and elliptical shapes? </div><div>&nbsp;</div><div>Thanks very much,</div><div>Regards,</div><div>Jc</div>]]>
   </description>
   <pubDate>Tue, 10 Sep 2013 02:04:34 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13705&amp;PID=71589&amp;title=cxtpbutton-with-rounded-corners#71589</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPButton with rounded corners : You can always override OnPaint...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13705&amp;PID=48172&amp;title=cxtpbutton-with-rounded-corners#48172</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3213">rdhd</a><br /><strong>Subject:</strong> 13705<br /><strong>Posted:</strong> 20 April 2009 at 4:31pm<br /><br />You can always override OnPaint and draw a button to suit your needs. We do that and use custom background masks to get various shapes including elliptical. We have to built the mask and use PatBlt and BitBlt. Then we use BitPlt&nbsp;and MaskBlt in our code. And of course the correct rop code has to be used and you may want to handle various effects such as shifting the image on mouse down. It took me a bit of tweaking to get everything aligned properly and to get the mask created (we have some mono bitmaps that define the shapes). Probably pretty easy for a GDI jock. The key is the mask. Once we have the background image loaded we do this:<DIV>&nbsp;</DIV><FONT color=#008000 size=2><FONT color=#008000 size=2><P>// CreateBitmapMask will fill the background of the monochrome bitmap with WHITENESS (1s) and</P><P>// fill the foreground area (where color in the image dc exists) with black (0s). It assumes</P><P>// that the hDCImage global is valid and contains the foreground/face of the button.</P></FONT></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2><P>void</FONT></FONT><FONT size=2> OurButton::CreateBitmapMask( CBitmap* cBit, CPoint ptOffset )</P><P>{</P><P>CRect rect;</P><P>GetClientRect (rect);</P><P>CSize sizeButton = rect.Size();</P><P>CSize sizeImage = GetBitmapSize(m_hbmImage);</P><P>PatBlt(hDCMono, 0, 0, sizeButton.cx, sizeButton.cy, WHITENESS);</P><P>SetBkColor(hDCImage, m_bTrueColorBitmap ? s_TrueColorBackground : GetSysColor(COLOR_BTNFACE));</P><P>BitBlt(hDCMono, ptOffset.x, ptOffset.y, sizeImage.cx, sizeImage.cy, hDCImage, 0, 0, SRCCOPY);</P><P>}</P><DIV></DIV><P>Then when drawing the button we use MaskBlt with the mask the above code created.</FONT></P>]]>
   </description>
   <pubDate>Mon, 20 Apr 2009 16:31:01 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13705&amp;PID=48172&amp;title=cxtpbutton-with-rounded-corners#48172</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPButton with rounded corners : Hello,   How do I can create CXTPButton...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13705&amp;PID=46788&amp;title=cxtpbutton-with-rounded-corners#46788</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2041">Tapan</a><br /><strong>Subject:</strong> 13705<br /><strong>Posted:</strong> 17 March 2009 at 1:18am<br /><br />Hello,<br /><br /> How do I can create CXTPButton object having rounded corners like in Mac?<br />Can we write code to get the rounded corners or<br />Is there any way that I can use any image(.png, .bmp, .jpeg etc.) as background for a CXTPButton object so that I can get rounded corners like when we apply tiger skin.<br /><br />  <br /><br />Thanks,<br />Tapan]]>
   </description>
   <pubDate>Tue, 17 Mar 2009 01:18:02 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13705&amp;PID=46788&amp;title=cxtpbutton-with-rounded-corners#46788</guid>
  </item> 
 </channel>
</rss>