<?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 : How to get bitmap and not glyph</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Command Bars : How to get bitmap and not glyph]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Fri, 12 Jun 2026 22:20:51 +0000</pubDate>
  <lastBuildDate>Sun, 19 Jul 2009 14:49:21 +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=13537</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[How to get bitmap and not glyph :   This is not working for me...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=51096&amp;title=how-to-get-bitmap-and-not-glyph#51096</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=5336">tralfaz</a><br /><strong>Subject:</strong> 13537<br /><strong>Posted:</strong> 19 July 2009 at 2:49pm<br /><br />This is not working for me<br><br>&nbsp;&nbsp;&nbsp; CXTPImageManagerIcon* pIcon = XTPImageManager()-&gt;GetImage( CmdID, 16);<br>&nbsp;&nbsp;&nbsp; if (pIcon) {<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; CXTPImageManagerIconHandle IconHandle = pIcon-&gt;GetIcon();<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; CXTPImageManagerIconHandle IconCopy;<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; IconCopy.CopyHandle(IconHandle);<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if (IconCopy!= NULL) {<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; hBM = (HBITMAP)IconCopy.GetBitmap();<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp; }<br><br>pIcon is good and contains the correct information, but the HBITMAP is always null. The toolbar button with CmdID exists. Used this to create the toolbar<br><br>&nbsp;&nbsp;&nbsp; CXTPTabManagerItem* pItem = CreateToolbar(pCommandBars, pToolBar, Index, _TT("Main"), IDR_MAINFRAME3, true, true, false);<br><br>Can you tell me how to get the HBitmap from an ID?<br>]]>
   </description>
   <pubDate>Sun, 19 Jul 2009 14:49:21 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=51096&amp;title=how-to-get-bitmap-and-not-glyph#51096</guid>
  </item> 
  <item>
   <title><![CDATA[How to get bitmap and not glyph : Hi,  It was in release notes...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46231&amp;title=how-to-get-bitmap-and-not-glyph#46231</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 13537<br /><strong>Posted:</strong> 04 March 2009 at 3:38am<br /><br />Hi,<DIV>&nbsp;</DIV><DIV>It was in release notes for 11.2.1 version and marked as important change.</DIV>]]>
   </description>
   <pubDate>Wed, 04 Mar 2009 03:38:52 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46231&amp;title=how-to-get-bitmap-and-not-glyph#46231</guid>
  </item> 
  <item>
   <title><![CDATA[How to get bitmap and not glyph : Why change the previous behavior...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46200&amp;title=how-to-get-bitmap-and-not-glyph#46200</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3213">rdhd</a><br /><strong>Subject:</strong> 13537<br /><strong>Posted:</strong> 03 March 2009 at 12:51pm<br /><br />Why change the previous behavior by default? There have been other issues like this with V12 where previous behavior is changed and to change it back we have to set a flag (accelerators on shortcut menus comes to mind). I would have thought m_bUseResources would default to FALSE and if I want to turn it on I would specifically do so and hence know or understand the repercussions and additional coding that is then necessary. Release notes could indicate the new functionality, why it was added&nbsp;and how to turn it on and any known issues when it is turned on.<DIV>&nbsp;</DIV><DIV>We started out late with CJ (version 11) so we have only lived thru one version change (we are in the process of moving to 13 but are now wondering what will bite us next).&nbsp;These sort of semantic/behavior changes are catching us flat footed and we are beginning to wonder about the approach CJ is taking when producing a new version. Basically we are spending resources trying to fix what used to work. Setting a new flag is not much trouble. Finding out&nbsp;what caused the regression and how to get back to the start point is time consuming.</DIV>]]>
   </description>
   <pubDate>Tue, 03 Mar 2009 12:51:01 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46200&amp;title=how-to-get-bitmap-and-not-glyph#46200</guid>
  </item> 
  <item>
   <title><![CDATA[How to get bitmap and not glyph : Hello,  You can call XTPIma...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46163&amp;title=how-to-get-bitmap-and-not-glyph#46163</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 13537<br /><strong>Posted:</strong> 03 March 2009 at 12:52am<br /><br />Hello,<DIV>&nbsp;</DIV><DIV>You can call</DIV><DIV>XTPImageManager()-&gt;m_bUseResources = FALSE;</DIV><DIV>to return it all back.</DIV>]]>
   </description>
   <pubDate>Tue, 03 Mar 2009 00:52:00 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46163&amp;title=how-to-get-bitmap-and-not-glyph#46163</guid>
  </item> 
  <item>
   <title><![CDATA[How to get bitmap and not glyph : Thanks that seems to work. I went...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46130&amp;title=how-to-get-bitmap-and-not-glyph#46130</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3213">rdhd</a><br /><strong>Subject:</strong> 13537<br /><strong>Posted:</strong> 02 March 2009 at 11:02am<br /><br /><P>Thanks that seems to work. I went back to V11 when our code was working and it appears there has been a fairly significant change in the underlying CodeJock code in V12 that now is rippling its way thru our products. I can understand why CodeJock made the underlying archetectural change&nbsp;to how the images are stored and displayed.</P><DIV>But why the change in the seamantics of the GetImage method so that it returns the entire glyph instead of the bitmap of the command ID that is passed in?</DIV><DIV>&nbsp;</DIV><DIV>Should I start checking the version of CJ at runtime to deduce the semantics of various api calls? Or was this change in the semantics of GetImage something that was accidental?</DIV>]]>
   </description>
   <pubDate>Mon, 02 Mar 2009 11:02:59 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46130&amp;title=how-to-get-bitmap-and-not-glyph#46130</guid>
  </item> 
  <item>
   <title><![CDATA[How to get bitmap and not glyph : Hi,  Just make individual copy...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46066&amp;title=how-to-get-bitmap-and-not-glyph#46066</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 13537<br /><strong>Posted:</strong> 02 March 2009 at 12:37am<br /><br />Hi,<DIV>&nbsp;</DIV><DIV>Just make individual copy of this handle:</DIV><DIV>&nbsp;</DIV><DIV><P>CXTPImageManagerIconHandle IconHandle = pIcon-&gt;GetIcon();</P><DIV></DIV>CXTPImageManagerIconHandle IconCopy;</DIV><DIV>IconCopy.CopyHandle(IconHandle);</DIV>]]>
   </description>
   <pubDate>Mon, 02 Mar 2009 00:37:51 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46066&amp;title=how-to-get-bitmap-and-not-glyph#46066</guid>
  </item> 
  <item>
   <title><![CDATA[How to get bitmap and not glyph : I am doing the following:  pIcon...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46055&amp;title=how-to-get-bitmap-and-not-glyph#46055</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3213">rdhd</a><br /><strong>Subject:</strong> 13537<br /><strong>Posted:</strong> 01 March 2009 at 6:15pm<br /><br />I am doing the following:<DIV>&nbsp;</DIV><FONT size=2><P>pIcon = XTPImageManager()-&gt;GetImage( nID, 16);</P><DIV></DIV><FONT size=2><P>CXTPImageManagerIconHandle IconHandle = pIcon-&gt;GetIcon();</P><P>hbm = <FONT size=2>IconHandle.GetBitmap();</P><DIV></DIV><DIV>I expected to get a handle to a bitmap for the input command id (nID). Instead what I get is the entire glyph the bitmap is part of. I stepped into the code and found that m_pRInfo contians a member, "rc" that has&nbsp;the location of the command in the glyph but the code appears to just return a handle to a glyph. How do I get an individual bitmap of the size I have asked for?</DIV><DIV>&nbsp;</DIV><DIV><FONT size=2><P>HBITMAP CXTPImageManagerIconHandle::GetBitmap() </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>const</P></FONT></FONT><FONT size=2><P>{</P><DIV>ASSERT(IsAlpha());</DIV><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>if</FONT></FONT><FONT size=2> (m_hBitmap)</P><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>return</FONT></FONT><FONT size=2> m_hBitmap;</P><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>if</FONT></FONT><FONT size=2> (m_pRInfo &amp;&amp; m_pRInfo-&gt;pResource &amp;&amp; m_pRInfo-&gt;pResource-&gt;m_hbmpImage)</P><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>return</FONT></FONT><FONT size=2> <FONT color=#cc0000>m_pRInfo-&gt;pResource-&gt;m_hbmpImage</FONT>;</P><P>ASSERT(FALSE);</P><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>return</FONT></FONT><FONT size=2> NULL;</P><P>}</P></FONT></DIV></FONT></FONT></FONT>]]>
   </description>
   <pubDate>Sun, 01 Mar 2009 18:15:15 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13537&amp;PID=46055&amp;title=how-to-get-bitmap-and-not-glyph#46055</guid>
  </item> 
 </channel>
</rss>